Skip to content

Commit

Permalink
add TC slot info
Browse files Browse the repository at this point in the history
  • Loading branch information
jerader committed Jan 22, 2025
1 parent e85e9f4 commit 0a057b5
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions protocol-designer/src/top-selectors/labware-locations/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ import {
MOVABLE_TRASH_ADDRESSABLE_AREAS,
FLEX_MODULE_ADDRESSABLE_AREAS,
FLEX_STACKER_ADDRESSABLE_AREAS,
TC_MODULE_LOCATION_OT2,
TC_MODULE_LOCATION_OT3,
} from '@opentrons/shared-data'
import { COLUMN_4_SLOTS, getHasWasteChute } from '@opentrons/step-generation'
import {
Expand Down Expand Up @@ -160,7 +162,6 @@ export const getUnoccupiedLabwareLocationOptions: Selector<
: 'unknown module'
const moduleSlotInfo = modSlot ?? 'unknown slot'
const adapterSlotInfo = adapterSlot ?? 'unknown adapter'

return labwareOnAdapter == null && isAdapter
? [
...acc,
Expand All @@ -182,14 +183,21 @@ export const getUnoccupiedLabwareLocationOptions: Selector<
const moduleHasLabware = Object.entries(labware).some(
([lwId, lwOnDeck]) => lwOnDeck.slot === modId
)
const type = moduleEntities[modId].type
const slot = modOnDeck.slot
let tcLocations
if (type === THERMOCYCLER_MODULE_TYPE) {
tcLocations =
slot === '7' ? TC_MODULE_LOCATION_OT2 : TC_MODULE_LOCATION_OT3
}
return moduleHasLabware
? acc
: [
...acc,
{
name: `${getModuleDisplayName(
moduleEntities[modId].model
)} on ${modOnDeck.slot}`,
)} on ${tcLocations != null ? tcLocations : slot}`,
value: modId,
},
]
Expand Down

0 comments on commit 0a057b5

Please sign in to comment.