| Nodes: | Valid adresses: | Bus: | ||||||||||||
| shelfNodeId | 1-48 | CAN | ||||||||||||
| backplaneNodeId | 1-4 | |||||||||||||
| feederId | 1-8 | Modbus | ||||||||||||
| Name/Description | Message Direction | Message ID (11bit) | PAYLOAD | |||||||||||
| From | To | Type (5bit) | Node (6bit) | Byte 1 | Byte 2 | Byte 3 | Byte 4 | Byte 5 | Byte 6 | Byte 7 | Byte 8 | |||
| Master Heartbeat | Master | All | 1 | 0 | ||||||||||
| Execute Shelf Command | Master | Shelf | 2 | shelfNodeId | shelfCmd | shelfCmdParam | ||||||||
| Execute Feeder Command | Master | Shelf | 3 | shelfNodeId | feederId | feederCmd | feederCmdParam | feederTaskId | ||||||
| Execute Backplane Command | Master | Backplane | 4 | backplaneNodeId | backplaneCmd | shelfNodeId | ||||||||
| Backplane Heartbeat & Shelf Status | Backplane | Master | 5 | backplaneNodeId | presentShelves | activeShelves | ||||||||
| Backplane Event | Backplane | Master | 6 | backplaneNodeId | backplaneEvent | shelfNodeId | ||||||||
| Assign ShelfNodeId | Backplane | Shelf | 7 | backplaneNodeId | shelfNodeId | |||||||||
| Shelf Heartbeat & Active Feederes | Shelf | Backplane, Master | 8 | shelfNodeId | activeFeeders | |||||||||
| Feeder Telemetry 1 | Shelf | Master | 9 | shelfNodeId | feederId | feederTaskState | feederTaskStateParam | feederCurrentTaskId | feederState | feederInputFlags | feederLedState | |||
| Feeder Telemetry 2 | Shelf | Master | 10 | shelfNodeId | feederId | adcRaw24v | adcRaw3v3 | adcRawMotorCurrent | feederErrorFlags | |||||
| Feeder Telemetry 3 | Shelf | Master | 11 | shelfNodeId | feederId | feederUuidChunk | feederUuid [12] (2 x 6) | |||||||
| Feeder Telemetry 4 | Shelf | Master | 12 | shelfNodeId | feederId | feederType | softwareVersionMajor | softwareVersionMinor | softwareVersionBuild | |||||
| Shelf Telemetry 1 | Shelf | Master | 13 | shelfNodeId | adcRaw24v | adcRaw3v3 | shelfErrorFlags | |||||||
| Shelf Telemetry 2 | Shelf | Master | 14 | shelfNodeId | feederId | adcRawCemCurrent | ||||||||
| Shelf Telemetry 3 | Shelf | Master | 15 | shelfNodeId | shelfType | softwareVersionMajor | softwareVersionMinor | softwareVersionBuild | ||||||
| Backplane Telemetry 1 | Backplane | Master | 16 | backplaneNodeId | adcRaw24v | adcRaw3v3 | backplaneErrorFlags | |||||||
| Backplane Telemetry 2 | Backplane | Master | 17 | backplaneNodeId | backplaneType | softwareVersionMajor | softwareVersionMinor | softwareVersionBuild | ||||||
| Parameter Name | Datatype | Values | Description | |||||||||||
| backplaneEvent ↶ | uint8_t | 1 – 4, 100 | 0 | RESERVED | ||||||||||
| 1 | SHELF_INSERTED | Shelf physically inserted but without communication yet. | ||||||||||||
| 2 | SHELF_ASSIGNED | Shelf been assigned nodeId and communication is successful. | ||||||||||||
| 3 | SHELF_LINK_LOST | Shelf communication has failed but is still inserted physically. | ||||||||||||
| 4 | SHELF_REMOVED | Shelf is removed physically. | ||||||||||||
| 100 | ASSIGN_ALL_FINISHED | Assigning all shelves process has been finished. | ||||||||||||
| Note: Events 1..4 will come with corresponding parameter shelfNodeId. | ||||||||||||||
| backplaneCmd ↶ | uint8_t | 1 – 4 | 0 | RESERVED | ||||||||||
| 1 | DISABLE_ALL | Disable all levels in backplane. | ||||||||||||
| 2 | DISABLE_ONE | Disable specific level. Provide shelfNodeId. | ||||||||||||
| 3 | ASSIGN_ALL | Try to discover and assign all present shelfes. | ||||||||||||
| 4 | ASSIGN ONE | Try to discover and assign shelf on specific level. Provide shelfNodeId. | ||||||||||||
| presentShelves ↶ | uin16_t | 0x0000 – 0x0FFF | Bits 0-11 describe state of each level in backplane. | |||||||||||
| 0 | Shelf not present physically | |||||||||||||
| 1 | Shelf is present physically | |||||||||||||
| activeShelves ↶ | uin16_t | 0x0000 – 0x0FFF | Bits 0-11 describe state of each level in backplane. | |||||||||||
| 0 | Shelf is not active (no communication). | |||||||||||||
| 1 | Shelf is active (communication estabilished). | |||||||||||||
| activeFeeders ↶ | uint8_t | 0x00 – 0xFF | Each bit describes if corresponding feeder state. | |||||||||||
| 0 | Feeder is not active (not present & no communication). | |||||||||||||
| 1 | Feeder is active (communication estabilished). | |||||||||||||
| adcRaw24v ↶ | uint16_t | 0 – 4095 | Raw 12bit ADC value. System voltage (24V rail). Calculate to engineering value using below formula: | |||||||||||
| ((adcRaw24v * ADC_REF_V) / ADC_MAX_RAW) * ((ADC_24V_RES_H + ADC_24V_RES_L) / ADC_24V_RES_L) | ||||||||||||||
| ADC_REF_V | 3.3 | |||||||||||||
| ADC_MAX_RAW | 4095 | |||||||||||||
| ADC_24V_RES_H | 150000 | |||||||||||||
| ADC_24V_RES_L | 10000 | |||||||||||||
| adcRaw3v3 ↶ | uint16_t | 0 – 4095 | Raw 12bit ADC value. Logic voltage (3.3V LDO). Calculate to engineering value using below formula: | |||||||||||
| ((adcRaw3v3 * ADC_REF_V) / ADC_MAX_RAW) * ((ADC_24V_RES_H + ADC_24V_RES_L) / ADC_24V_RES_L) | ||||||||||||||
| ADC_REF_V | 3.3 | |||||||||||||
| ADC_MAX_RAW | 4095 | |||||||||||||
| ADC_3V3_RES_H | 5100 | |||||||||||||
| ADC_3V3_RES_L | 10000 | |||||||||||||
| backplaneType ↶ | uint8_t | 1 | Backplane PCB type. Reserved for future use (eg. For backplanes with less or more levels). | |||||||||||
| 1 | STANDARD | |||||||||||||
| backplaneErrorFlags ↶ | uint8_t | 0x00 – 0x1F | Backplane Error Flags. Each bit corresponds to one error. If a bit is set (1), the error is asserted. | |||||||||||
| Bit: | ||||||||||||||
| 0 | Rail voltage too high. | |||||||||||||
| 1 | Rail voltage too low. | |||||||||||||
| 2 | Logic voltage too high. | |||||||||||||
| 3 | Logic voltage too low. | |||||||||||||
| 4 | Master heartbeat not received. | |||||||||||||
| 5-7 | RESERVED | |||||||||||||
| shelfErrorFlags ↶ | uint8_t | 0x00 – 0x1F | Shelf Error Flags. Each bit corresponds to one error. If a bit is set (1), the error is asserted. | |||||||||||
| Bit: | ||||||||||||||
| 0 | Rail voltage too high. | |||||||||||||
| 1 | Rail voltage too low. | |||||||||||||
| 2 | Logic voltage too high. | |||||||||||||
| 3 | Logic voltage too low. | |||||||||||||
| 4 | Master heartbeat not received. | |||||||||||||
| 5-7 | RESERVED | |||||||||||||
| softwareVersionMajor ↶ | uint8_t | 0-255 | Major Software Version. Together with softwareVersionMinor, softwareVersionBuild (major.minor.build) is written in firmware and should be marked in release package/tag. | |||||||||||
| softwareVersionMinor ↶ | uint8_t | 0-255 | Minor Software Version. Together with softwareVersionMajor, softwareVersionBuild (major.minor.build) is written in firmware and should be marked in release package/tag. | |||||||||||
| softwareVersionBuild ↶ | uint8_t | 0-255 | Build Software Version. Together with softwareVersionMajor, softwareVersionMinor (major.minor.build) is written in firmware and should be marked in release package/tag. | |||||||||||
| shelfType ↶ | uint8_t | 1 | Shelf type. Reserved for future use. | |||||||||||
| 1 | STANDARD | |||||||||||||
| adcRawCemCurrent ↶ | uint16_t | 0 – 4095 | Raw 12bit ADC value. Current on CEM output (card edge slots on shelf). Calculate to engineering value using below formula: | |||||||||||
| float v = (float)rawAdc * ADC_REF_V / ADC_MAX_RAW; | ||||||||||||||
| float iOut_A = (v <= CS_VOUT_LIN_MAX) ? (v * (TPS_CS_K / CS_R_GND)) : NAN; | ||||||||||||||
| ADC_REF_V | 3.3 | |||||||||||||
| ADC_MAX_RAW | 4095 | |||||||||||||
| TPS_CS_K | 500 | |||||||||||||
| CS_R_GND | 510 | |||||||||||||
| CS_R_SER | 270 | |||||||||||||
| TPS_CS_VIN_LIN_MAX | 4.0 | |||||||||||||
| CS_VOUT_LIN_MAX | (TPS_CS_VIN_LIN_MAX * (CS_R_GND / (CS_R_SER + CS_R_GND))) | |||||||||||||
| Note: Values higher than CS_VOUT_LIN_MAX should be marked as NaN – and treated as FAULT state. | ||||||||||||||
| Possible reasons for FAULT state: | ||||||||||||||
| Output short to GND | ||||||||||||||
| Power switch thermal swing/shutdown | ||||||||||||||
| feederType ↶ | uint8_t | 1, 2 | Feeder type. | |||||||||||
| 1 | STD_SINGLE | |||||||||||||
| 2 | STD_DOUBLE | |||||||||||||
| feederUuidChunk ↶ | bool | 0, 1 | Describes which UUID chunk is being sent, this was nessesary since UUID can't be send in one CAN payload. | |||||||||||
| 0 | First chunk (lower 6 bytes) | |||||||||||||
| 1 | Second chunk (upper 6 bytes) | |||||||||||||
| feederUuid ↶ | uint8_t [12] | - | Feeder 96 bit UUID (Unique identifier). It is split in two 48bits (6 bytes) chunks, to fit in the CAN frame. See feederUuidChunk. | |||||||||||
| adcRawMotorCurrent ↶ | uint16_t | 0 – 4095 | Raw 12bit ADC value. Feeder motor current. Calculate to engineering value using below formula: | |||||||||||
| float i_A = (((float)rawAdc * ADC_REF_V) / (float)ADC_MAX_RAW - MOT_IPROPI_OFFSET_V) / MOT_IPROPI_V_PER_A; | ||||||||||||||
| ADC_REF_V | 3.3 | |||||||||||||
| ADC_MAX_RAW | 4095 | |||||||||||||
| MOT_IPROPI_GAIN_UA_PER_A | 1575 | |||||||||||||
| MOT_IPROPI_RES_OHM | 1000 | |||||||||||||
| MOT_IPROPI_OFFSET_V | 0 | |||||||||||||
| MOT_IPROPI_V_PER_A | ((MOT_IPROPI_GAIN_UA_PER_A * 1.0e-6f) * MOT_IPROPI_RES_OHM) | |||||||||||||
| shelfCmd ↶ | uint8_t | 1, 2 | Shelf command. | |||||||||||
| 1 | DISCOVER_FEEDERS | Turns off all CEMs outputs, and starts power sequence, and discovering inserted feeders. | ||||||||||||
| 2 | DISABLE_FEEDER | Force disable one CEM output. Provide CEM index (feederId) as shelfCmdParam | ||||||||||||
| shelfCmdParam ↶ | uint8_t | 0 – 255 | Parameter for shelf command. See shelfCmd. | |||||||||||
| feederCmd ↶ | uint8_t | 1 – 7 | Commands for feeder. | |||||||||||
| 1 | STOP | Stops current movement. | ||||||||||||
| 2 | FEED | Starts feeding. Provide feederCmdParam with amount of products that should be dropped. | ||||||||||||
| 3 | RETRACT | Retracts feeder for loading. | ||||||||||||
| 4 | LED_HIGHLIGHT | Change led brightness without changing color. Provide feederCmdParam: 0=LED_NORMAL_BRIGHTNESS, 1=LED_MAX_BRIGHTNESS | ||||||||||||
| 5 | LED_CHANGE_COLOR | Changes LED behaviour/color. Provide feederCmdParam with led behaviour. See possible values feederLedState. | ||||||||||||
| 6 | TRIGGER_MODE | Changes trigger flap mode signal interpretation. Provide feederCmdParam: 0=TRIG_ON_PRESS, 1=TRIG_ON_RELEASE | ||||||||||||
| 7 | BRAKING_MODE | Change braking mode. Provide feederCmdParam: 0=BRAKE_MODE_COAST, 1=BRAKE_MODE_FORCE | ||||||||||||
| feederCmdParam ↶ | uint8_t | 0 – 255 | Parameter for feeder command. See feederCmd. | |||||||||||
| feederTaskId ↶ | uint16_t | 0-65535 | TaskID for feederCmd. This should be send by controller (master) and incremented for each new task, to later reliable track specific task execution state. | |||||||||||
| feederTaskState ↶ | uint8_t | 0 – 7 | Feeder task state: | |||||||||||
| 0 | NO_TASK | No command was received yet. | ||||||||||||
| 1 | RECEIVED | Command was received. | ||||||||||||
| 2 | ACCEPTED | Command is correct and can be executed. | ||||||||||||
| 3 | REJECTED | Command was either unknown or cannot be executed at a time. | ||||||||||||
| 4 | BUSY | Command is during execution. When current task was FEED, feederTaskStateParamwill contain amount of products dropped till now. | ||||||||||||
| 5 | COMPLETED_SUCCESS | Comand was completed with success. When current task was FEED, feederTaskStateParamwill contain amount of products dropped. | ||||||||||||
| 6 | COMPLETED_DROPPED_WRONG_AMOUNT | Comand was completed, but either dropped not enough products (not sufficient stock), or dropped too much (products glued together), feederTaskStateParamwill contain amount of products dropped. | ||||||||||||
| 7 | FAILED | Command execution failed (eg. Timeout or hardware issue) | ||||||||||||
| feederTaskStateParam ↶ | uint8_t | 0-255 | Parameter for feeder task state. During, and after FEED command execution it will contain amount of products dropped. | |||||||||||
| feederCurrentTaskId ↶ | uint16_t | 0-65535 | Feeder will copy feederTaskId to feederCurrentTaskId when the task is received. This allows the controller to ensure that the feederTaskState it reads refers to the same task instance not a previous one. | |||||||||||
| feederState ↶ | uint8_t | Feeder state. | ||||||||||||
| 1 | STOPPED | |||||||||||||
| 2 | FEEDING | |||||||||||||
| 3 | RETRACTING | |||||||||||||
| feederInputFlags ↶ | uint8_t | 0x00 – 0x3F | Feeder input or settings flags. Each bit corresponds to one flag. If a bit is set (1), the flag is asserted. | |||||||||||
| Bit: | ||||||||||||||
| 0 | TRIGGER_MODE | 0=TRIG_ON_PRESS, 1=TRIG_ON_RELEASE | ||||||||||||
| 1 | BRAKING_MODE | 0=BRAKE_MODE_COAST, 1=BRAKE_MODE_FORCE | ||||||||||||
| 2 | TRIGGER | 0=TRIGGER_PRESSED, 1=TRIGGER_RELEASED | ||||||||||||
| 3 | LIMIT_SW_F | 0=NOT_AT_LIMIT, 1=AT_LIMIT | ||||||||||||
| 4 | LIMIT_SW_R | 0=NOT_AT_LIMIT, 1=AT_LIMIT | ||||||||||||
| 5 | MOTOR | 0=STOPPED, 1=RUNNING | ||||||||||||
| 6 | LED_BRIGHTNESS | 0=LED_NORMAL_BRIGHTNESS, 1=LED_MAX_BRIGHTNESS | ||||||||||||
| 7 | RESERVED | |||||||||||||
| feederLedState ↶ | uint8_t | 0 – 8 | 0 | OFF | ||||||||||
| 1 | BLUE | |||||||||||||
| 2 | BLUE_BLINK | |||||||||||||
| 3 | GREEN | |||||||||||||
| 4 | GREEN_BLINK | |||||||||||||
| 5 | RED | |||||||||||||
| 6 | RED_BLINK | |||||||||||||
| 7 | YELLOW | |||||||||||||
| 8 | YELLOW_BLINK | |||||||||||||
| feederErrorFlags ↶ | uint8_t | Feeder Error Flags. Each bit corresponds to one error. If a bit is set (1), the error is asserted. | ||||||||||||
| Bit: | ||||||||||||||
| 0 | Rail voltage too high. | |||||||||||||
| 1 | Rail voltage too low. | |||||||||||||
| 2 | Logic voltage too high. | |||||||||||||
| 3 | Logic voltage too low. | |||||||||||||
| 4 | Motor current too high | |||||||||||||
| 5 | Motor open circuit. | |||||||||||||
| 6 | Movement timeout. | |||||||||||||
| 7 | Both limit switches are at limits. | |||||||||||||