Skip to content

pymmcore_nano#

Module API

pymmcore_nano #

Classes:

Functions:

  • patch_pymmcore

    Add a meta path hook to redirect imports of pymmcore to pymmcore_nano.

Attributes:

DEVICE_BUFFER_OVERFLOW module-attribute #

DEVICE_BUFFER_OVERFLOW: int = 22

DEVICE_CAMERA_BUSY_ACQUIRING module-attribute #

DEVICE_CAMERA_BUSY_ACQUIRING: int = 30

DEVICE_CAN_NOT_SET_PROPERTY module-attribute #

DEVICE_CAN_NOT_SET_PROPERTY: int = 32

DEVICE_COMM_HUB_MISSING module-attribute #

DEVICE_COMM_HUB_MISSING: int = 36

DEVICE_CORE_CHANNEL_PRESETS_FAILED module-attribute #

DEVICE_CORE_CHANNEL_PRESETS_FAILED: int = 33

DEVICE_CORE_CONFIG_FAILED module-attribute #

DEVICE_CORE_CONFIG_FAILED: int = 29

DEVICE_CORE_EXPOSURE_FAILED module-attribute #

DEVICE_CORE_EXPOSURE_FAILED: int = 28

DEVICE_CORE_FOCUS_STAGE_UNDEF module-attribute #

DEVICE_CORE_FOCUS_STAGE_UNDEF: int = 27

DEVICE_DUPLICATE_LABEL module-attribute #

DEVICE_DUPLICATE_LABEL: int = 20

DEVICE_DUPLICATE_LIBRARY module-attribute #

DEVICE_DUPLICATE_LIBRARY: int = 37

DEVICE_DUPLICATE_PROPERTY module-attribute #

DEVICE_DUPLICATE_PROPERTY: int = 4

DEVICE_ERR module-attribute #

DEVICE_ERR: int = 1

DEVICE_IMAGE_PARAMS_FAILED module-attribute #

DEVICE_IMAGE_PARAMS_FAILED: int = 26

DEVICE_INCOMPATIBLE_IMAGE module-attribute #

DEVICE_INCOMPATIBLE_IMAGE: int = 31

DEVICE_INTERFACE_VERSION module-attribute #

DEVICE_INTERFACE_VERSION: int = 73

DEVICE_INTERNAL_INCONSISTENCY module-attribute #

DEVICE_INTERNAL_INCONSISTENCY: int = 8

DEVICE_INVALID_INPUT_PARAM module-attribute #

DEVICE_INVALID_INPUT_PARAM: int = 21

DEVICE_INVALID_PROPERTY module-attribute #

DEVICE_INVALID_PROPERTY: int = 2

DEVICE_INVALID_PROPERTY_LIMITS module-attribute #

DEVICE_INVALID_PROPERTY_LIMITS: int = 24

DEVICE_INVALID_PROPERTY_LIMTS module-attribute #

DEVICE_INVALID_PROPERTY_LIMTS: int = 24

DEVICE_INVALID_PROPERTY_TYPE module-attribute #

DEVICE_INVALID_PROPERTY_TYPE: int = 5

DEVICE_INVALID_PROPERTY_VALUE module-attribute #

DEVICE_INVALID_PROPERTY_VALUE: int = 3

DEVICE_LOCALLY_DEFINED_ERROR module-attribute #

DEVICE_LOCALLY_DEFINED_ERROR: int = 34

DEVICE_NATIVE_MODULE_FAILED module-attribute #

DEVICE_NATIVE_MODULE_FAILED: int = 6

DEVICE_NONEXISTENT_CHANNEL module-attribute #

DEVICE_NONEXISTENT_CHANNEL: int = 23

DEVICE_NOT_CONNECTED module-attribute #

DEVICE_NOT_CONNECTED: int = 35

DEVICE_NOT_SUPPORTED module-attribute #

DEVICE_NOT_SUPPORTED: int = 9

DEVICE_NOT_YET_IMPLEMENTED module-attribute #

DEVICE_NOT_YET_IMPLEMENTED: int = 41

DEVICE_NO_CALLBACK_REGISTERED module-attribute #

DEVICE_NO_CALLBACK_REGISTERED: int = 13

DEVICE_NO_PROPERTY_DATA module-attribute #

DEVICE_NO_PROPERTY_DATA: int = 19

DEVICE_OK module-attribute #

DEVICE_OK: int = 0

DEVICE_OUT_OF_MEMORY module-attribute #

DEVICE_OUT_OF_MEMORY: int = 40

DEVICE_PROPERTY_NOT_SEQUENCEABLE module-attribute #

DEVICE_PROPERTY_NOT_SEQUENCEABLE: int = 38

DEVICE_SELF_REFERENCE module-attribute #

DEVICE_SELF_REFERENCE: int = 18

DEVICE_SEQUENCE_TOO_LARGE module-attribute #

DEVICE_SEQUENCE_TOO_LARGE: int = 39

DEVICE_SERIAL_BUFFER_OVERRUN module-attribute #

DEVICE_SERIAL_BUFFER_OVERRUN: int = 15

DEVICE_SERIAL_COMMAND_FAILED module-attribute #

DEVICE_SERIAL_COMMAND_FAILED: int = 14

DEVICE_SERIAL_INVALID_RESPONSE module-attribute #

DEVICE_SERIAL_INVALID_RESPONSE: int = 16

DEVICE_SERIAL_TIMEOUT module-attribute #

DEVICE_SERIAL_TIMEOUT: int = 17

DEVICE_SNAP_IMAGE_FAILED module-attribute #

DEVICE_SNAP_IMAGE_FAILED: int = 25

DEVICE_UNKNOWN_LABEL module-attribute #

DEVICE_UNKNOWN_LABEL: int = 10

DEVICE_UNKNOWN_POSITION module-attribute #

DEVICE_UNKNOWN_POSITION: int = 12

DEVICE_UNSUPPORTED_COMMAND module-attribute #

DEVICE_UNSUPPORTED_COMMAND: int = 11

DEVICE_UNSUPPORTED_DATA_FORMAT module-attribute #

DEVICE_UNSUPPORTED_DATA_FORMAT: int = 7

MMCore_version module-attribute #

MMCore_version: str = '11.5.0'

MMCore_version_info module-attribute #

MMCore_version_info: tuple = (11, 5, 0)

MM_CODE_ERR module-attribute #

MM_CODE_ERR: int = 1

MM_CODE_OK module-attribute #

MM_CODE_OK: int = 0

MODULE_INTERFACE_VERSION module-attribute #

MODULE_INTERFACE_VERSION: int = 10

PYMMCORE_NANO_VERSION module-attribute #

PYMMCORE_NANO_VERSION: str = '0'

g_CFGCommand_ConfigGroup module-attribute #

g_CFGCommand_ConfigGroup: str = 'ConfigGroup'

g_CFGCommand_ConfigPixelSize module-attribute #

g_CFGCommand_ConfigPixelSize: str = 'ConfigPixelSize'

g_CFGCommand_Configuration module-attribute #

g_CFGCommand_Configuration: str = 'Config'

g_CFGCommand_Delay module-attribute #

g_CFGCommand_Delay: str = 'Delay'

g_CFGCommand_Device module-attribute #

g_CFGCommand_Device: str = 'Device'

g_CFGCommand_Equipment module-attribute #

g_CFGCommand_Equipment: str = 'Equipment'

g_CFGCommand_FocusDirection module-attribute #

g_CFGCommand_FocusDirection: str = 'FocusDirection'

g_CFGCommand_ImageSynchro module-attribute #

g_CFGCommand_ImageSynchro: str = 'ImageSynchro'

g_CFGCommand_Label module-attribute #

g_CFGCommand_Label: str = 'Label'

g_CFGCommand_ParentID module-attribute #

g_CFGCommand_ParentID: str = 'Parent'

g_CFGCommand_PixelSizeAffine module-attribute #

g_CFGCommand_PixelSizeAffine: str = 'PixelSizeAffine'

g_CFGCommand_PixelSize_um module-attribute #

g_CFGCommand_PixelSize_um: str = 'PixelSize_um'

g_CFGCommand_Property module-attribute #

g_CFGCommand_Property: str = 'Property'

g_CFGGroup_PixelSizeUm module-attribute #

g_CFGGroup_PixelSizeUm: str = 'PixelSize_um'

g_CFGGroup_System module-attribute #

g_CFGGroup_System: str = 'System'

g_CFGGroup_System_Shutdown module-attribute #

g_CFGGroup_System_Shutdown: str = 'Shutdown'

g_CFGGroup_System_Startup module-attribute #

g_CFGGroup_System_Startup: str = 'Startup'

g_FieldDelimiters module-attribute #

g_FieldDelimiters: str = ','

g_Keyword_ActualExposure module-attribute #

g_Keyword_ActualExposure: str = 'ActualExposure'

g_Keyword_ActualInterval_ms module-attribute #

g_Keyword_ActualInterval_ms: str = 'ActualInterval-ms'

g_Keyword_AnswerTimeout module-attribute #

g_Keyword_AnswerTimeout: str = 'AnswerTimeout'

g_Keyword_BaudRate module-attribute #

g_Keyword_BaudRate: str = 'BaudRate'

g_Keyword_Binning module-attribute #

g_Keyword_Binning: str = 'Binning'

g_Keyword_CCDTemperature module-attribute #

g_Keyword_CCDTemperature: str = 'CCDTemperature'

g_Keyword_CCDTemperatureSetPoint module-attribute #

g_Keyword_CCDTemperatureSetPoint: str = (
    "CCDTemperatureSetPoint"
)

g_Keyword_CameraChannelIndex module-attribute #

g_Keyword_CameraChannelIndex: str = 'CameraChannelIndex'

g_Keyword_CameraChannelName module-attribute #

g_Keyword_CameraChannelName: str = 'CameraChannelName'

g_Keyword_CameraID module-attribute #

g_Keyword_CameraID: str = 'CameraID'

g_Keyword_CameraName module-attribute #

g_Keyword_CameraName: str = 'CameraName'

g_Keyword_Channel module-attribute #

g_Keyword_Channel: str = 'Channel'

g_Keyword_Closed_Position module-attribute #

g_Keyword_Closed_Position: str = 'ClosedPosition'

g_Keyword_ColorMode module-attribute #

g_Keyword_ColorMode: str = 'ColorMode'

g_Keyword_CoreAutoFocus module-attribute #

g_Keyword_CoreAutoFocus: str = 'AutoFocus'

g_Keyword_CoreAutoShutter module-attribute #

g_Keyword_CoreAutoShutter: str = 'AutoShutter'

g_Keyword_CoreCamera module-attribute #

g_Keyword_CoreCamera: str = 'Camera'

g_Keyword_CoreChannelGroup module-attribute #

g_Keyword_CoreChannelGroup: str = 'ChannelGroup'

g_Keyword_CoreDevice module-attribute #

g_Keyword_CoreDevice: str = 'Core'

g_Keyword_CoreFocus module-attribute #

g_Keyword_CoreFocus: str = 'Focus'

g_Keyword_CoreGalvo module-attribute #

g_Keyword_CoreGalvo: str = 'Galvo'

g_Keyword_CoreImageProcessor module-attribute #

g_Keyword_CoreImageProcessor: str = 'ImageProcessor'

g_Keyword_CoreInitialize module-attribute #

g_Keyword_CoreInitialize: str = 'Initialize'

g_Keyword_CoreSLM module-attribute #

g_Keyword_CoreSLM: str = 'SLM'

g_Keyword_CoreShutter module-attribute #

g_Keyword_CoreShutter: str = 'Shutter'

g_Keyword_CoreTimeoutMs module-attribute #

g_Keyword_CoreTimeoutMs: str = 'TimeoutMs'

g_Keyword_CoreXYStage module-attribute #

g_Keyword_CoreXYStage: str = 'XYStage'

g_Keyword_DataBits module-attribute #

g_Keyword_DataBits: str = 'DataBits'

g_Keyword_Delay module-attribute #

g_Keyword_Delay: str = 'Delay_ms'

g_Keyword_DelayBetweenCharsMs module-attribute #

g_Keyword_DelayBetweenCharsMs: str = 'DelayBetweenCharsMs'

g_Keyword_Description module-attribute #

g_Keyword_Description: str = 'Description'

g_Keyword_EMGain module-attribute #

g_Keyword_EMGain: str = 'EMGain'

g_Keyword_Elapsed_Time_ms module-attribute #

g_Keyword_Elapsed_Time_ms: str = 'ElapsedTime-ms'

g_Keyword_Exposure module-attribute #

g_Keyword_Exposure: str = 'Exposure'

g_Keyword_Gain module-attribute #

g_Keyword_Gain: str = 'Gain'

g_Keyword_Handshaking module-attribute #

g_Keyword_Handshaking: str = 'Handshaking'

g_Keyword_HubID module-attribute #

g_Keyword_HubID: str = 'HubID'

g_Keyword_Interval_ms module-attribute #

g_Keyword_Interval_ms: str = 'Interval-ms'

g_Keyword_Label module-attribute #

g_Keyword_Label: str = 'Label'

g_Keyword_Meatdata_Exposure module-attribute #

g_Keyword_Meatdata_Exposure: str = 'Exposure-ms'

g_Keyword_Metadata_CameraLabel module-attribute #

g_Keyword_Metadata_CameraLabel: str = 'Camera'

g_Keyword_Metadata_ImageNumber module-attribute #

g_Keyword_Metadata_ImageNumber: str = 'ImageNumber'

g_Keyword_Metadata_ROI_X module-attribute #

g_Keyword_Metadata_ROI_X: str = 'ROI-X-start'

g_Keyword_Metadata_ROI_Y module-attribute #

g_Keyword_Metadata_ROI_Y: str = 'ROI-Y-start'

g_Keyword_Metadata_Score module-attribute #

g_Keyword_Metadata_Score: str = 'Score'

g_Keyword_Metadata_TimeInCore module-attribute #

g_Keyword_Metadata_TimeInCore: str = 'TimeReceivedByCore'

g_Keyword_Name module-attribute #

g_Keyword_Name: str = 'Name'

g_Keyword_Offset module-attribute #

g_Keyword_Offset: str = 'Offset'

g_Keyword_Parity module-attribute #

g_Keyword_Parity: str = 'Parity'

g_Keyword_PixelType module-attribute #

g_Keyword_PixelType: str = 'PixelType'

g_Keyword_Port module-attribute #

g_Keyword_Port: str = 'Port'

g_Keyword_Position module-attribute #

g_Keyword_Position: str = 'Position'

g_Keyword_ReadoutMode module-attribute #

g_Keyword_ReadoutMode: str = 'ReadoutMode'

g_Keyword_ReadoutTime module-attribute #

g_Keyword_ReadoutTime: str = 'ReadoutTime'

g_Keyword_Speed module-attribute #

g_Keyword_Speed: str = 'Speed'

g_Keyword_State module-attribute #

g_Keyword_State: str = 'State'

g_Keyword_StopBits module-attribute #

g_Keyword_StopBits: str = 'StopBits'

g_Keyword_Transpose_Correction module-attribute #

g_Keyword_Transpose_Correction: str = 'TransposeCorrection'

g_Keyword_Transpose_MirrorX module-attribute #

g_Keyword_Transpose_MirrorX: str = 'TransposeMirrorX'

g_Keyword_Transpose_MirrorY module-attribute #

g_Keyword_Transpose_MirrorY: str = 'TransposeMirrorY'

g_Keyword_Transpose_SwapXY module-attribute #

g_Keyword_Transpose_SwapXY: str = 'TransposeXY'

g_Keyword_Type module-attribute #

g_Keyword_Type: str = 'Type'

g_Keyword_Version module-attribute #

g_Keyword_Version: str = 'Version'

ActionType #

Bases: IntEnum

Attributes:

AfterLoadSequence class-attribute instance-attribute #

AfterLoadSequence = 4

AfterSet class-attribute instance-attribute #

AfterSet = 2

BeforeGet class-attribute instance-attribute #

BeforeGet = 1

IsSequenceable class-attribute instance-attribute #

IsSequenceable = 3

NoAction class-attribute instance-attribute #

NoAction = 0

StartSequence class-attribute instance-attribute #

StartSequence = 5

StopSequence class-attribute instance-attribute #

StopSequence = 6

CMMCore #

CMMCore()

The main MMCore object.

Manages multiple device adapters. Provides a device-independent interface for hardware control. Additionally, provides some facilities (such as configuration groups) for application programming.

Methods:

addGalvoPolygonVertex #

addGalvoPolygonVertex(
    galvoLabel: str, polygonIndex: int, x: float, y: float
) -> None

Add a vertex to a galvo polygon.

clearCircularBuffer #

clearCircularBuffer() -> None

clearROI #

clearROI() -> None

debugLogEnabled #

debugLogEnabled() -> bool

defineConfigGroup #

defineConfigGroup(groupName: str) -> None

defineStateLabel #

defineStateLabel(
    stateDeviceLabel: str, state: int, stateLabel: str
) -> None

deleteConfigGroup #

deleteConfigGroup(groupName: str) -> None

deleteGalvoPolygons #

deleteGalvoPolygons(galvoLabel: str) -> None

deletePixelSizeConfig #

deletePixelSizeConfig(configName: str) -> None

detectDevice #

detectDevice(deviceLabel: str) -> DeviceDetectionStatus

deviceBusy #

deviceBusy(label: str) -> bool

deviceTypeBusy #

deviceTypeBusy(devType: DeviceType) -> bool

displaySLMImage #

displaySLMImage(slmLabel: str) -> None

enableContinuousFocus #

enableContinuousFocus(enable: bool) -> None

enableDebugLog #

enableDebugLog(enable: bool) -> None

enableFeature staticmethod #

enableFeature(name: str, enable: bool) -> None

enableStderrLog #

enableStderrLog(enable: bool) -> None

fullFocus #

fullFocus() -> None

getAPIVersionInfo #

getAPIVersionInfo() -> str

getAllowedPropertyValues #

getAllowedPropertyValues(
    label: str, propName: str
) -> list[str]

getAutoFocusDevice #

getAutoFocusDevice() -> str

getAutoFocusOffset #

getAutoFocusOffset() -> float

getAutoShutter #

getAutoShutter() -> bool

getAvailableConfigGroups #

getAvailableConfigGroups() -> list[str]

getAvailableConfigs #

getAvailableConfigs(configGroup: str) -> list[str]

getAvailableDeviceDescriptions #

getAvailableDeviceDescriptions(library: str) -> list[str]

getAvailableDeviceTypes #

getAvailableDeviceTypes(library: str) -> list[int]

getAvailableDevices #

getAvailableDevices(library: str) -> list[str]

getAvailablePixelSizeConfigs #

getAvailablePixelSizeConfigs() -> list[str]

getBufferFreeCapacity #

getBufferFreeCapacity() -> int

getBufferTotalCapacity #

getBufferTotalCapacity() -> int

getBytesPerPixel #

getBytesPerPixel() -> int

getCameraChannelName #

getCameraChannelName(channelNr: int) -> str

getCameraDevice #

getCameraDevice() -> str

getChannelGroup #

getChannelGroup() -> str

getCircularBufferMemoryFootprint #

getCircularBufferMemoryFootprint() -> int

getConfigData #

getConfigData(
    configGroup: str, configName: str
) -> Configuration

getConfigGroupState #

getConfigGroupState(group: str) -> Configuration

getConfigGroupStateFromCache #

getConfigGroupStateFromCache(group: str) -> Configuration

getConfigState #

getConfigState(group: str, config: str) -> Configuration

getCoreErrorText #

getCoreErrorText(code: int) -> str

getCurrentConfig #

getCurrentConfig(groupName: str) -> str

getCurrentConfigFromCache #

getCurrentConfigFromCache(groupName: str) -> str

getCurrentFocusScore #

getCurrentFocusScore() -> float

getDeviceAdapterNames #

getDeviceAdapterNames() -> list[str]

getDeviceAdapterSearchPaths #

getDeviceAdapterSearchPaths() -> list[str]

getDeviceDelayMs #

getDeviceDelayMs(label: str) -> float

getDeviceDescription #

getDeviceDescription(label: str) -> str

getDeviceInitializationState #

getDeviceInitializationState(
    label: str,
) -> DeviceInitializationState

getDeviceLibrary #

getDeviceLibrary(label: str) -> str

getDeviceName #

getDeviceName(label: str) -> str

getDevicePropertyNames #

getDevicePropertyNames(label: str) -> list[str]

getDeviceType #

getDeviceType(label: str) -> DeviceType

getExposureSequenceMaxLength #

getExposureSequenceMaxLength(cameraLabel: str) -> int

getFocusDevice #

getFocusDevice() -> str

getFocusDirection #

getFocusDirection(stageLabel: str) -> int

getGalvoChannel #

getGalvoChannel(galvoLabel: str) -> str

getGalvoDevice #

getGalvoDevice() -> str

getGalvoPosition #

getGalvoPosition(arg: str) -> tuple[float, float]

getGalvoXMinimum #

getGalvoXMinimum(galvoLabel: str) -> float

getGalvoXRange #

getGalvoXRange(galvoLabel: str) -> float

getGalvoYMinimum #

getGalvoYMinimum(galvoLabel: str) -> float

getGalvoYRange #

getGalvoYRange(galvoLabel: str) -> float

getImageBitDepth #

getImageBitDepth() -> int

getImageBufferSize #

getImageBufferSize() -> int

getImageHeight #

getImageHeight() -> int

getImageProcessorDevice #

getImageProcessorDevice() -> str

getImageWidth #

getImageWidth() -> int

getInstalledDeviceDescription #

getInstalledDeviceDescription(
    hubLabel: str, peripheralLabel: str
) -> str

getInstalledDevices #

getInstalledDevices(hubLabel: str) -> list[str]

getLastFocusScore #

getLastFocusScore() -> float

getLastImage #

getLastImage() -> ArrayLike

getLoadedDevices #

getLoadedDevices() -> list[str]

getLoadedDevicesOfType #

getLoadedDevicesOfType(devType: DeviceType) -> list[str]

getLoadedPeripheralDevices #

getLoadedPeripheralDevices(hubLabel: str) -> list[str]

getMagnificationFactor #

getMagnificationFactor() -> float

getMultiROI #

getMultiROI() -> tuple[
    list[int], list[int], list[int], list[int]
]

getNumberOfCameraChannels #

getNumberOfCameraChannels() -> int

getNumberOfComponents #

getNumberOfComponents() -> int

getNumberOfStates #

getNumberOfStates(stateDeviceLabel: str) -> int

getParentLabel #

getParentLabel(peripheralLabel: str) -> str

getPixelSizeAffineByID #

getPixelSizeAffineByID(resolutionID: str) -> list[float]

getPixelSizeConfigData #

getPixelSizeConfigData(configName: str) -> Configuration

getPixelSizeUmByID #

getPixelSizeUmByID(resolutionID: str) -> float

getPrimaryLogFile #

getPrimaryLogFile() -> str

getProperty #

getProperty(label: str, propName: str) -> str

getPropertyFromCache #

getPropertyFromCache(
    deviceLabel: str, propName: str
) -> str

getPropertyLowerLimit #

getPropertyLowerLimit(label: str, propName: str) -> float

getPropertySequenceMaxLength #

getPropertySequenceMaxLength(
    label: str, propName: str
) -> int

getPropertyType #

getPropertyType(label: str, propName: str) -> PropertyType

getPropertyUpperLimit #

getPropertyUpperLimit(label: str, propName: str) -> float

getPumpFlowrate #

getPumpFlowrate(pumpLabel: str) -> float

getPumpMaxVolume #

getPumpMaxVolume(pumpLabel: str) -> float

getPumpPressureKPa #

getPumpPressureKPa(pumpLabel: str) -> float

getPumpVolume #

getPumpVolume(pumpLabel: str) -> float

getRemainingImageCount #

getRemainingImageCount() -> int

getSLMBytesPerPixel #

getSLMBytesPerPixel(slmLabel: str) -> int

getSLMDevice #

getSLMDevice() -> str

getSLMExposure #

getSLMExposure(slmLabel: str) -> float

getSLMHeight #

getSLMHeight(slmLabel: str) -> int

getSLMNumberOfComponents #

getSLMNumberOfComponents(slmLabel: str) -> int

getSLMSequenceMaxLength #

getSLMSequenceMaxLength(slmLabel: str) -> int

getSLMWidth #

getSLMWidth(slmLabel: str) -> int

getSerialPortAnswer #

getSerialPortAnswer(portLabel: str, term: str) -> str

getShutterDevice #

getShutterDevice() -> str

getStageSequenceMaxLength #

getStageSequenceMaxLength(stageLabel: str) -> int

getState #

getState(stateDeviceLabel: str) -> int

getStateFromLabel #

getStateFromLabel(
    stateDeviceLabel: str, stateLabel: str
) -> int

getStateLabel #

getStateLabel(stateDeviceLabel: str) -> str

getStateLabels #

getStateLabels(stateDeviceLabel: str) -> list[str]

getSystemState #

getSystemState() -> Configuration

getSystemStateCache #

getSystemStateCache() -> Configuration

getTimeoutMs #

getTimeoutMs() -> int

getVersionInfo #

getVersionInfo() -> str

getXYStageDevice #

getXYStageDevice() -> str

getXYStageSequenceMaxLength #

getXYStageSequenceMaxLength(xyStageLabel: str) -> int

hasProperty #

hasProperty(label: str, propName: str) -> bool

hasPropertyLimits #

hasPropertyLimits(label: str, propName: str) -> bool

home #

home(xyOrZStageLabel: str) -> None

incrementalFocus #

incrementalFocus() -> None

initializeAllDevices #

initializeAllDevices() -> None

initializeCircularBuffer #

initializeCircularBuffer() -> None

initializeDevice #

initializeDevice(label: str) -> None

invertPumpDirection #

invertPumpDirection(pumpLabel: str, invert: bool) -> None

isBufferOverflowed #

isBufferOverflowed() -> bool

isConfigDefined #

isConfigDefined(groupName: str, configName: str) -> bool

isContinuousFocusDrive #

isContinuousFocusDrive(stageLabel: str) -> bool

isContinuousFocusEnabled #

isContinuousFocusEnabled() -> bool

isContinuousFocusLocked #

isContinuousFocusLocked() -> bool

isExposureSequenceable #

isExposureSequenceable(cameraLabel: str) -> bool

isFeatureEnabled staticmethod #

isFeatureEnabled(name: str) -> bool

isGroupDefined #

isGroupDefined(groupName: str) -> bool

isMultiROIEnabled #

isMultiROIEnabled() -> bool

isMultiROISupported #

isMultiROISupported() -> bool

isPixelSizeConfigDefined #

isPixelSizeConfigDefined(resolutionID: str) -> bool

isPropertyPreInit #

isPropertyPreInit(label: str, propName: str) -> bool

isPropertyReadOnly #

isPropertyReadOnly(label: str, propName: str) -> bool

isPropertySequenceable #

isPropertySequenceable(label: str, propName: str) -> bool

isPumpDirectionInverted #

isPumpDirectionInverted(pumpLabel: str) -> bool

isStageLinearSequenceable #

isStageLinearSequenceable(stageLabel: str) -> bool

isStageSequenceable #

isStageSequenceable(stageLabel: str) -> bool

isXYStageSequenceable #

isXYStageSequenceable(xyStageLabel: str) -> bool

loadDevice #

loadDevice(
    label: str, moduleName: str, deviceName: str
) -> None

loadExposureSequence #

loadExposureSequence(
    cameraLabel: str, exposureSequence_ms: Sequence[float]
) -> None

loadGalvoPolygons #

loadGalvoPolygons(galvoLabel: str) -> None

loadPropertySequence #

loadPropertySequence(
    label: str, propName: str, eventSequence: Sequence[str]
) -> None

loadSLMSequence #

loadSLMSequence(
    slmLabel: str, pixels: Sequence[ArrayLike]
) -> None

loadStageSequence #

loadStageSequence(
    stageLabel: str, positionSequence: Sequence[float]
) -> None

loadSystemConfiguration #

loadSystemConfiguration(fileName: object) -> None

Loads a system configuration from a file.

loadSystemState #

loadSystemState(fileName: str) -> None

loadXYStageSequence #

loadXYStageSequence(
    xyStageLabel: str,
    xSequence: Sequence[float],
    ySequence: Sequence[float],
) -> None

pointGalvoAndFire #

pointGalvoAndFire(
    galvoLabel: str,
    x: float,
    y: float,
    pulseTime_us: float,
) -> None

popNextImage #

popNextImage() -> ArrayLike

prepareSequenceAcquisition #

prepareSequenceAcquisition(cameraLabel: str) -> None

pressurePumpCalibrate #

pressurePumpCalibrate(pumpLabel: str) -> None

pressurePumpRequiresCalibration #

pressurePumpRequiresCalibration(pumpLabel: str) -> bool

pressurePumpStop #

pressurePumpStop(pumpLabel: str) -> None

pumpDispenseDurationSeconds #

pumpDispenseDurationSeconds(
    pumpLabel: str, seconds: float
) -> None

pumpDispenseVolumeUl #

pumpDispenseVolumeUl(
    pumpLabel: str, microLiter: float
) -> None

pumpStart #

pumpStart(pumpLabel: str) -> None

readFromSerialPort #

readFromSerialPort(portLabel: str) -> list[str]

registerCallback #

registerCallback(cb: MMEventCallback) -> None

Register a callback (listener class).

MMCore will send notifications on internal events using this interface

renameConfig #

renameConfig(
    groupName: str, oldConfigName: str, newConfigName: str
) -> None

renameConfigGroup #

renameConfigGroup(
    oldGroupName: str, newGroupName: str
) -> None

renamePixelSizeConfig #

renamePixelSizeConfig(
    oldConfigName: str, newConfigName: str
) -> None

reset #

reset() -> None

runGalvoPolygons #

runGalvoPolygons(galvoLabel: str) -> None

runGalvoSequence #

runGalvoSequence(galvoLabel: str) -> None

saveSystemConfiguration #

saveSystemConfiguration(fileName: str) -> None

saveSystemState #

saveSystemState(fileName: str) -> None

setAutoFocusDevice #

setAutoFocusDevice(focusLabel: str) -> None

setAutoFocusOffset #

setAutoFocusOffset(offset: float) -> None

setAutoShutter #

setAutoShutter(state: bool) -> None

setCameraDevice #

setCameraDevice(cameraLabel: str) -> None

setChannelGroup #

setChannelGroup(channelGroup: str) -> None

setCircularBufferMemoryFootprint #

setCircularBufferMemoryFootprint(sizeMB: int) -> None

setConfig #

setConfig(groupName: str, configName: str) -> None

setDeviceAdapterSearchPaths #

setDeviceAdapterSearchPaths(paths: Sequence[str]) -> None

setDeviceDelayMs #

setDeviceDelayMs(label: str, delayMs: float) -> None

setFocusDevice #

setFocusDevice(focusLabel: str) -> None

setFocusDirection #

setFocusDirection(stageLabel: str, sign: int) -> None

setGalvoDevice #

setGalvoDevice(galvoLabel: str) -> None

setGalvoIlluminationState #

setGalvoIlluminationState(
    galvoLabel: str, on: bool
) -> None

setGalvoPolygonRepetitions #

setGalvoPolygonRepetitions(
    galvoLabel: str, repetitions: int
) -> None

setGalvoPosition #

setGalvoPosition(
    galvoLabel: str, x: float, y: float
) -> None

setGalvoSpotInterval #

setGalvoSpotInterval(
    galvoLabel: str, pulseTime_us: float
) -> None

setImageProcessorDevice #

setImageProcessorDevice(procLabel: str) -> None

setMultiROI #

setMultiROI(
    xs: Sequence[int],
    ys: Sequence[int],
    widths: Sequence[int],
    heights: Sequence[int],
) -> None

setParentLabel #

setParentLabel(
    deviceLabel: str, parentHubLabel: str
) -> None

setPixelSizeAffine #

setPixelSizeAffine(
    resolutionID: str, affine: Sequence[float]
) -> None

setPixelSizeConfig #

setPixelSizeConfig(resolutionID: str) -> None

setPixelSizeOptimalZUm #

setPixelSizeOptimalZUm(
    resolutionID: str, optimalZ: float
) -> None

setPixelSizeUm #

setPixelSizeUm(resolutionID: str, pixSize: float) -> None

setPixelSizedxdz #

setPixelSizedxdz(resolutionID: str, dXdZ: float) -> None

setPixelSizedydz #

setPixelSizedydz(resolutionID: str, dYdZ: float) -> None

setPrimaryLogFile #

setPrimaryLogFile(
    filename: object, truncate: bool = False
) -> None

setPumpFlowrate #

setPumpFlowrate(pumpLabel: str, volume: float) -> None

setPumpMaxVolume #

setPumpMaxVolume(pumpLabel: str, volume: float) -> None

setPumpPressureKPa #

setPumpPressureKPa(pumpLabel: str, pressure: float) -> None

setPumpVolume #

setPumpVolume(pumpLabel: str, volume: float) -> None

setSLMDevice #

setSLMDevice(slmLabel: str) -> None

setSLMExposure #

setSLMExposure(slmLabel: str, exposure_ms: float) -> None

setSLMImage #

setSLMImage(slmLabel: str, pixels: ArrayLike) -> None

setSerialPortCommand #

setSerialPortCommand(
    portLabel: str, command: str, term: str
) -> None

setSerialProperties #

setSerialProperties(
    portName: str,
    answerTimeout: str,
    baudRate: str,
    delayBetweenCharsMs: str,
    handshaking: str,
    parity: str,
    stopBits: str,
) -> None

setShutterDevice #

setShutterDevice(shutterLabel: str) -> None

setStageLinearSequence #

setStageLinearSequence(
    stageLabel: str, dZ_um: float, nSlices: int
) -> None

setState #

setState(stateDeviceLabel: str, state: int) -> None

setStateLabel #

setStateLabel(
    stateDeviceLabel: str, stateLabel: str
) -> None

setSystemState #

setSystemState(conf: Configuration) -> None

setTimeoutMs #

setTimeoutMs(timeoutMs: int) -> None

setXYStageDevice #

setXYStageDevice(xyStageLabel: str) -> None

sleep #

sleep(intervalMs: float) -> None

snapImage #

snapImage() -> None

startContinuousSequenceAcquisition #

startContinuousSequenceAcquisition(
    intervalMs: float,
) -> None

startExposureSequence #

startExposureSequence(cameraLabel: str) -> None

startPropertySequence #

startPropertySequence(label: str, propName: str) -> None

startSLMSequence #

startSLMSequence(slmLabel: str) -> None

startSecondaryLogFile #

startSecondaryLogFile(
    filename: object,
    enableDebug: bool,
    truncate: bool = True,
    synchronous: bool = False,
) -> int

startStageSequence #

startStageSequence(stageLabel: str) -> None

startXYStageSequence #

startXYStageSequence(xyStageLabel: str) -> None

stderrLogEnabled #

stderrLogEnabled() -> bool

stop #

stop(xyOrZStageLabel: str) -> None

stopExposureSequence #

stopExposureSequence(cameraLabel: str) -> None

stopPropertySequence #

stopPropertySequence(label: str, propName: str) -> None

stopSLMSequence #

stopSLMSequence(slmLabel: str) -> None

stopSecondaryLogFile #

stopSecondaryLogFile(handle: int) -> None

stopStageSequence #

stopStageSequence(stageLabel: str) -> None

stopXYStageSequence #

stopXYStageSequence(xyStageLabel: str) -> None

supportsDeviceDetection #

supportsDeviceDetection(deviceLabel: str) -> bool

systemBusy #

systemBusy() -> bool

unloadAllDevices #

unloadAllDevices() -> None

unloadDevice #

unloadDevice(label: str) -> None

unloadLibrary #

unloadLibrary(moduleName: str) -> None

updateCoreProperties #

updateCoreProperties() -> None

updateSystemStateCache #

updateSystemStateCache() -> None

usesDeviceDelay #

usesDeviceDelay(label: str) -> bool

volumetricPumpHome #

volumetricPumpHome(pumpLabel: str) -> None

volumetricPumpRequiresHoming #

volumetricPumpRequiresHoming(pumpLabel: str) -> bool

volumetricPumpStop #

volumetricPumpStop(pumpLabel: str) -> None

waitForConfig #

waitForConfig(group: str, configName: str) -> None

waitForDevice #

waitForDevice(label: str) -> None

waitForDeviceType #

waitForDeviceType(devType: DeviceType) -> None

waitForSystem #

waitForSystem() -> None

writeToSerialPort #

writeToSerialPort(
    portLabel: str, data: Sequence[str]
) -> None

CMMError #

Bases: RuntimeError

Configuration #

Configuration()

Encapsulation of configuration information.

A configuration is a collection of device property settings.

Methods:

addSetting #

addSetting(setting: PropertySetting) -> None

deleteSetting #

deleteSetting(device: str, property: str) -> None

getVerbose #

getVerbose() -> str

isConfigurationIncluded #

isConfigurationIncluded(cfg: Configuration) -> bool

isPropertyIncluded #

isPropertyIncluded(device: str, property: str) -> bool

isSettingIncluded #

isSettingIncluded(setting: PropertySetting) -> bool

size #

size() -> int

DeviceDetectionStatus #

Bases: IntEnum

Attributes:

CanCommunicate class-attribute instance-attribute #

CanCommunicate = 1

CanNotCommunicate class-attribute instance-attribute #

CanNotCommunicate = 0

Misconfigured class-attribute instance-attribute #

Misconfigured = -1

Unimplemented class-attribute instance-attribute #

Unimplemented = -2

DeviceInitializationState #

Bases: IntEnum

Attributes:

InitializationFailed class-attribute instance-attribute #

InitializationFailed = 2

InitializedSuccessfully class-attribute instance-attribute #

InitializedSuccessfully = 1

Uninitialized class-attribute instance-attribute #

Uninitialized = 0

DeviceNotification #

Bases: IntEnum

Attributes:

Attention class-attribute instance-attribute #

Attention = 0

Done class-attribute instance-attribute #

Done = 1

StatusChanged class-attribute instance-attribute #

StatusChanged = 2

DeviceType #

Bases: IntEnum

Attributes:

AnyType class-attribute instance-attribute #

AnyType = 1

AutoFocusDevice class-attribute instance-attribute #

AutoFocusDevice = 9

CameraDevice class-attribute instance-attribute #

CameraDevice = 2

CoreDevice class-attribute instance-attribute #

CoreDevice = 10

GalvoDevice class-attribute instance-attribute #

GalvoDevice = 16

GenericDevice class-attribute instance-attribute #

GenericDevice = 8

HubDevice class-attribute instance-attribute #

HubDevice = 15

ImageProcessorDevice class-attribute instance-attribute #

ImageProcessorDevice = 11

MagnifierDevice class-attribute instance-attribute #

MagnifierDevice = 13

SLMDevice class-attribute instance-attribute #

SLMDevice = 14

SerialDevice class-attribute instance-attribute #

SerialDevice = 7

ShutterDevice class-attribute instance-attribute #

ShutterDevice = 3

SignalIODevice class-attribute instance-attribute #

SignalIODevice = 12

StageDevice class-attribute instance-attribute #

StageDevice = 5

StateDevice class-attribute instance-attribute #

StateDevice = 4

UnknownType class-attribute instance-attribute #

UnknownType = 0

XYStageDevice class-attribute instance-attribute #

XYStageDevice = 6

FocusDirection #

Bases: IntEnum

Attributes:

FocusDirectionAwayFromSample class-attribute instance-attribute #

FocusDirectionAwayFromSample = 2

FocusDirectionTowardSample class-attribute instance-attribute #

FocusDirectionTowardSample = 1

FocusDirectionUnknown class-attribute instance-attribute #

FocusDirectionUnknown = 0

MMEventCallback #

MMEventCallback()

Interface for receiving events from MMCore.

Use by passing an instance to CMMCore.registerCallback.

Methods:

onChannelGroupChanged #

onChannelGroupChanged(newChannelGroupName: str) -> None

Called when the channel group changes

onConfigGroupChanged #

onConfigGroupChanged(
    groupName: str, newConfigName: str
) -> None

Called when a configuration group changes

onExposureChanged #

onExposureChanged(name: str, newExposure: float) -> None

onPixelSizeAffineChanged #

onPixelSizeAffineChanged(
    v0: float,
    v1: float,
    v2: float,
    v3: float,
    v4: float,
    v5: float,
) -> None

Called when the pixel size affine transformation changes

onPixelSizeChanged #

onPixelSizeChanged(newPixelSizeUm: float) -> None

Called when the pixel size changes

onPropertiesChanged #

onPropertiesChanged() -> None

Called when properties are changed

onPropertyChanged #

onPropertyChanged(
    name: str, propName: str, propValue: str
) -> None

Called when a specific property is changed

onSLMExposureChanged #

onSLMExposureChanged(name: str, newExposure: float) -> None

onStagePositionChanged #

onStagePositionChanged(name: str, pos: float) -> None

onSystemConfigurationLoaded #

onSystemConfigurationLoaded() -> None

Called when the system configuration is loaded

onXYStagePositionChanged #

onXYStagePositionChanged(
    name: str, xpos: float, ypos: float
) -> None

Metadata #

Methods:

  • Clear

    Clears all tags

  • Dump

    Dumps metadata in human-readable format

  • GetArrayTag

    Gets an array tag by key

  • GetKeys

    Returns all tag keys

  • GetSingleTag

    Gets a single tag by key

  • HasTag

    Checks if a tag exists for the given key

  • Merge

    Merges new tags into the metadata

  • PutImageTag

    Adds an image tag

  • PutTag

    Adds a MetadataSingleTag

  • RemoveTag

    Removes a tag by key

  • Restore

    Restores metadata from a serialized string

  • Serialize

    Serializes the metadata

  • SetTag

    Sets a tag

Clear #

Clear() -> None

Clears all tags

Dump #

Dump() -> str

Dumps metadata in human-readable format

GetArrayTag #

GetArrayTag(key: str) -> MetadataArrayTag

Gets an array tag by key

GetKeys #

GetKeys() -> list[str]

Returns all tag keys

GetSingleTag #

GetSingleTag(key: str) -> MetadataSingleTag

Gets a single tag by key

HasTag #

HasTag(key: str) -> bool

Checks if a tag exists for the given key

Merge #

Merge(newTags: Metadata) -> None

Merges new tags into the metadata

PutImageTag #

PutImageTag(key: str, value: str) -> None

Adds an image tag

PutTag #

PutTag(key: str, deviceLabel: str, value: str) -> None

Adds a MetadataSingleTag

RemoveTag #

RemoveTag(key: str) -> None

Removes a tag by key

Restore #

Restore(stream: str) -> bool

Restores metadata from a serialized string

Serialize #

Serialize() -> str

Serializes the metadata

SetTag #

SetTag(tag: MetadataTag) -> None

Sets a tag

MetadataArrayTag #

Bases: MetadataTag

Methods:

AddValue #

AddValue(val: str) -> None

Adds a value to the array

Clone #

Clone() -> MetadataTag

Clones this tag

GetDevice #

GetDevice() -> str

Returns the device label

GetName #

GetName() -> str

Returns the name of the tag

GetQualifiedName #

GetQualifiedName() -> str

Returns the qualified name

GetSize #

GetSize() -> int

Returns the size of the array

GetValue #

GetValue(idx: int) -> str

Gets a value at a specific index

IsReadOnly #

IsReadOnly() -> bool

Checks if the tag is read-only

Restore #

Restore(stream: str) -> bool

Restores from a serialized string

Serialize #

Serialize() -> str

Serializes this tag to a string

SetDevice #

SetDevice(device: str) -> None

Sets the device label

SetName #

SetName(name: str) -> None

Sets the name of the tag

SetReadOnly #

SetReadOnly(readOnly: bool) -> None

Sets the read-only status

SetValue #

SetValue(val: str, idx: int) -> None

Sets a value at a specific index

ToArrayTag #

ToArrayTag() -> MetadataArrayTag

Returns this object as MetadataArrayTag

ToSingleTag #

ToSingleTag() -> MetadataSingleTag

Converts to MetadataSingleTag if applicable

MetadataIndexError #

Bases: IndexError

MetadataKeyError #

Bases: KeyError

MetadataSingleTag #

Bases: MetadataTag

Methods:

Clone #

Clone() -> MetadataTag

Clones this tag

GetDevice #

GetDevice() -> str

Returns the device label

GetName #

GetName() -> str

Returns the name of the tag

GetQualifiedName #

GetQualifiedName() -> str

Returns the qualified name

GetValue #

GetValue() -> str

Returns the value

IsReadOnly #

IsReadOnly() -> bool

Checks if the tag is read-only

Restore #

Restore(stream: str) -> bool

Restores from a serialized string

Serialize #

Serialize() -> str

Serializes this tag to a string

SetDevice #

SetDevice(device: str) -> None

Sets the device label

SetName #

SetName(name: str) -> None

Sets the name of the tag

SetReadOnly #

SetReadOnly(readOnly: bool) -> None

Sets the read-only status

SetValue #

SetValue(val: str) -> None

Sets the value

ToArrayTag #

ToArrayTag() -> MetadataArrayTag

Converts to MetadataArrayTag if applicable

ToSingleTag #

ToSingleTag() -> MetadataSingleTag

Returns this object as MetadataSingleTag

MetadataTag #

Methods:

Clone #

Clone() -> MetadataTag

Creates a clone of the MetadataTag

GetDevice #

GetDevice() -> str

Returns the device label

GetName #

GetName() -> str

Returns the name of the tag

GetQualifiedName #

GetQualifiedName() -> str

Returns the qualified name

IsReadOnly #

IsReadOnly() -> bool

Checks if the tag is read-only

Restore #

Restore(stream: str) -> bool

Restores from a serialized string

Serialize #

Serialize() -> str

Serializes the MetadataTag to a string

SetDevice #

SetDevice(device: str) -> None

Sets the device label

SetName #

SetName(name: str) -> None

Sets the name of the tag

SetReadOnly #

SetReadOnly(readOnly: bool) -> None

Sets the read-only status

ToArrayTag #

ToArrayTag() -> MetadataArrayTag

Converts to MetadataArrayTag if applicable

ToSingleTag #

ToSingleTag() -> MetadataSingleTag

Converts to MetadataSingleTag if applicable

PortType #

Bases: IntEnum

Attributes:

HIDPort class-attribute instance-attribute #

HIDPort = 3

InvalidPort class-attribute instance-attribute #

InvalidPort = 0

SerialPort class-attribute instance-attribute #

SerialPort = 1

USBPort class-attribute instance-attribute #

USBPort = 2

PropertySetting #

Methods:

generateKey staticmethod #

generateKey(device: str, prop: str) -> str

Generates a unique key based on device and property

getDeviceLabel #

getDeviceLabel() -> str

Returns the device label

getKey #

getKey() -> str

Returns the unique key

getPropertyName #

getPropertyName() -> str

Returns the property name

getPropertyValue #

getPropertyValue() -> str

Returns the property value

getReadOnly #

getReadOnly() -> bool

Returns the read-only status

getVerbose #

getVerbose() -> str

Returns a verbose description

isEqualTo #

isEqualTo(other: PropertySetting) -> bool

Checks if this property setting is equal to another

PropertyType #

Bases: IntEnum

Attributes:

Float class-attribute instance-attribute #

Float = 2

Integer class-attribute instance-attribute #

Integer = 3

String class-attribute instance-attribute #

String = 1

Undef class-attribute instance-attribute #

Undef = 0

patch_pymmcore #

patch_pymmcore()

Add a meta path hook to redirect imports of pymmcore to pymmcore_nano.