| optoICC

Loading...
Searching...
No Matches
optoICC.registers.icc_registers.ICCStatus Class Reference

Parent class => Status
More...

Inheritance diagram for optoICC.registers.icc_registers.ICCStatus:

## Public Member Functions
| __init__ (self, board=None)
| GetDeviceEEPROMactiveChannel (self)
| Gets the number of the EEPROM active channel.
| SetDeviceEEPROMactiveChannel (self, channel)
| Sets the number of the EEPROM active channel.
| parse_error_flags (self, int error_flag_data)
| Parses status register value based on active bits which are corresponding to the individual errors.
| GetDeviceDetectSwitchMask (self)
| Gets the value of the device detect switch.
| SetDeviceDetectSwitchMask (self, mask)
| Sets the value of the device detect switch.
| GetMCUid (self)
| Gets MCU type identification number.
| GetMCUtype (self, index, count)
| Gets MCU type string.
| GetMCUload (self)
| Gets the Signal Flow execution load in %.
| GetMCUoverloadCounter (self)
| Counter that increments if Signal Flow execution load > 95%.
DeviceModel | GetDeviceID (self, channel)

## Static Public Member Functions
| help ()

## Public Attributes
dict | device_eeprom_active_channel
dict | device_detect_switch_mask
dict | device_type_chan0
dict | device_type_chan1
dict | device_type_chan2
dict | device_type_chan3
dict | mcu_id
dict | mcu_load
dict | mcu_overload_counter
dict | warning_flag_register
dict | mcu_type = {'id': self.sys_id << 8 | 0x02, 'type': str}
| name = self.__class__.__name__

## Static Protected Attributes
bool | _is_a_system = False

## Detailed Description

Parent class => Status

    * Register map:
    *
    * Address | Name                  | Default      | Description                                     | Format and value        | Access     |
    * --------|-----------------------|--------------|-------------------------------------------------|-------------------------|------------|
    * 0x1000  |FW Id                  |              |                                                 | uint32                  | read only  |
    * 0x1001  |FW Branch              |              |                                                 | uint32                  | read only  |
    * 0x1002  |FW Type                |              |                                                 | uint32                  | read only  |
    * 0x1003  |FW Version Major       |              |                                                 | uint32                  | read only  |
    * 0x1004  |FW Version Minor       |              |                                                 | uint32                  | read only  |
    * 0x1005  |FW Version Build       |              |                                                 | uint32                  | read only  |
    * 0x1006  |FW Version Revision    |              |                                                 | uint32                  | read only  |
    * 0x1007  |System status errors   | 0 - No error | Register encodes system status and errors       | Read:<br/>   Bit#<br/>0 - Channel 0 output fault condition<br/>1 - Channel 0 output had fault condition<br/>2 - Channel 1 output fault condition<br/>3 - Channel 1 output had fault condition<br/>4 - Channel 2 output fault condition<br/>5 - Channel 2 output had fault condition<br/>6 - Channel 3 output fault condition<br/>7 - Channel 3 output had fault condition<br/>8 - Driver over-heat fault<br/>9 - Driver had over-heat fault<br/>10 - Device on channel 0 not detected<br/>11 - Device on channel 0 was not detected<br/>12 - Device on channel 1 not detected<br/>13 - Device on channel 1 was not detected<br/>14 - Device on channel 2 not detected<br/>15 - Device on channel 2 was not detected<br/>16 - Device on channel 3 not detected<br/>17 - Device on channel 3 was not detected<br/>18 - Channel 0 has over-current fault on 3V3 supply line<br/>19 - Channel 0 had over-current fault on 3V3 supply line<br/>20 - Channel 1 has over-current fault on 3V3 supply line<br/>21 - Channel 1 had over-current fault on 3V3 supply line<br/>22 - Channel 2 has over-current fault on 3V3 supply line<br/>23 - Channel 2 had over-current fault on 3V3 supply line<br/>24 - Channel 3 has over-current fault on 3V3 supply line<br/>25 - Channel 3 had over-current fault on 3V3 supply line<br/>26-31 - Reserved<br/>Write:<br/> Writing to this register resets all history error flags (odd bits 1, 3, .. 25)<br/> | read write |
    * 0x1008  |Dev.EEPROM active chan.| 0 = channel 0| Register switches I2C bus among channels        | uint32                  | read write |
    * 0x1009  |Dev.detect switch mask | 0            | SW switch parallel to Dev.Det.switches          | uint32                  | read write |
    * 0x100a  |DEV_TYPE0              | 0            | get device type on channel 0                    | uint32                  | read only  |
    * 0x100b  |DEV_TYPE1              | 0            | get device type on channel 1                    | uint32                  | read only  |
    * 0x100c  |DEV_TYPE2              | 0            | get device type on channel 2                    | uint32                  | read only  |
    * 0x100d  |DEV_TYPE3              | 0            | get device type on channel 3                    | uint32                  | read only  |
    * 0x100e  |MCU ID                 | 0            | get MCU type identification number              | uint32                  | read only  |
    * 0x100f  |MCU load               | 0            | get Signal Flow execution load in %             | uint32                  | read only  |
    * 0x1010  |MCU overload counter   | 0            | increments if Signal Flow execution load > 95%  | uint32                  | read only  |
    * 0x1011  |System status warning  | 0            | Register encodes system status and warnings     | uint32                  | read only  |
    *
    *
    *
    * Vector map (vectors have their own address space):
    * Address | Name           | Default  | Description | Format and value | Access    |
    * --------|----------------|----------|-------------|------------------|-----------|
    * 0x1000  |Firmware SN     |          |             | ascii string     | read only |
    * 0x1001  |Git HEAD SHA1   |          |             | ascii string     | read only |
    * 0x1002  |MCU type string |          |             | ascii string     | read only |
    *
    *

## Constructor & Destructor Documentation

## ◆ __init__()

optoICC.registers.icc_registers.ICCStatus.__init__ | ( |  | self,
|  |  | board = None )

## Member Function Documentation

## ◆ help()

optoICC.registers.icc_registers.ICCStatus.help | ( |  | ) |
| static

## ◆ GetDeviceEEPROMactiveChannel()

optoICC.registers.icc_registers.ICCStatus.GetDeviceEEPROMactiveChannel | ( |  | self | ) |

Gets the number of the EEPROM active channel.

When reading device EEPROM, data is read from this channel.

## ◆ SetDeviceEEPROMactiveChannel()

optoICC.registers.icc_registers.ICCStatus.SetDeviceEEPROMactiveChannel | ( |  | self,
|  |  | channel )

Sets the number of the EEPROM active channel.

When reading device EEPROM data is read from this channel.

## ◆ parse_error_flags()

optoICC.registers.icc_registers.ICCStatus.parse_error_flags | ( |  | self,
|  | int | error_flag_data )

Parses status register value based on active bits which are corresponding to the individual errors.

This method is used inside of the method GetErrorFlagRegister

## ◆ GetDeviceDetectSwitchMask()

optoICC.registers.icc_registers.ICCStatus.GetDeviceDetectSwitchMask | ( |  | self | ) |

Gets the value of the device detect switch.

SW switch parallel to Device Detect switches. (bit 0 => Channel 0, bit 1 => Channel 1,...)

## ◆ SetDeviceDetectSwitchMask()

optoICC.registers.icc_registers.ICCStatus.SetDeviceDetectSwitchMask | ( |  | self,
|  |  | mask )

Sets the value of the device detect switch.

SW switch parallel to Device Detect switches. (bit 0 => Channel 0, bit 1 => Channel 1,...)

## ◆ GetMCUid()

optoICC.registers.icc_registers.ICCStatus.GetMCUid | ( |  | self | ) |

Gets MCU type identification number.

## ◆ GetMCUtype()

optoICC.registers.icc_registers.ICCStatus.GetMCUtype | ( |  | self,
|  |  | index,
|  |  | count )

Gets MCU type string.

## ◆ GetMCUload()

optoICC.registers.icc_registers.ICCStatus.GetMCUload | ( |  | self | ) |

Gets the Signal Flow execution load in %.

## ◆ GetMCUoverloadCounter()

optoICC.registers.icc_registers.ICCStatus.GetMCUoverloadCounter | ( |  | self | ) |

Counter that increments if Signal Flow execution load > 95%.

This register resets after reading.

## ◆ GetDeviceID()

DeviceModel optoICC.registers.icc_registers.ICCStatus.GetDeviceID | ( |  | self,
|  |  | channel )

## Member Data Documentation

## ◆ _is_a_system

bool optoICC.registers.icc_registers.ICCStatus._is_a_system = False
| static protected

## ◆ device_eeprom_active_channel

dict optoICC.registers.icc_registers.ICCStatus.device_eeprom_active_channel

Initial value:
= {'id': self.sys_id << 8 | 0x08,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ device_detect_switch_mask

dict optoICC.registers.icc_registers.ICCStatus.device_detect_switch_mask

Initial value:
= {'id': self.sys_id << 8 | 0x09,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ device_type_chan0

dict optoICC.registers.icc_registers.ICCStatus.device_type_chan0

Initial value:
= {'id': self.sys_id << 8 | 0x0a,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ device_type_chan1

dict optoICC.registers.icc_registers.ICCStatus.device_type_chan1

Initial value:
= {'id': self.sys_id << 8 | 0x0b,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ device_type_chan2

dict optoICC.registers.icc_registers.ICCStatus.device_type_chan2

Initial value:
= {'id': self.sys_id << 8 | 0x0c,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ device_type_chan3

dict optoICC.registers.icc_registers.ICCStatus.device_type_chan3

Initial value:
= {'id': self.sys_id << 8 | 0x0d,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ mcu_id

dict optoICC.registers.icc_registers.ICCStatus.mcu_id

Initial value:
= {'id': self.sys_id << 8 | 0x0e,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ mcu_load

dict optoICC.registers.icc_registers.ICCStatus.mcu_load

Initial value:
= {'id': self.sys_id << 8 | 0x0f,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ mcu_overload_counter

dict optoICC.registers.icc_registers.ICCStatus.mcu_overload_counter

Initial value:
= {'id': self.sys_id << 8 | 0x10,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ warning_flag_register

dict optoICC.registers.icc_registers.ICCStatus.warning_flag_register

Initial value:
= {'id': self.sys_id << 8 | 0x11,
'type': int,
'unit': None,
'range': None,
'default': None,
'value': None}

## ◆ mcu_type

optoICC.registers.icc_registers.ICCStatus.mcu_type = {'id': self.sys_id << 8 | 0x02, 'type': str}

## ◆ name

optoICC.registers.icc_registers.ICCStatus.name = self.__class__.__name__