Motion Master 6.0.0-alpha.50
Next-generation motion control software
Loading...
Searching...
No Matches
mm::comm::FieldbusDriver::SlaveStateRaw Struct Reference

One slave's AL Status and AL Status Code registers — the "where" and the "why". More...

#include <fieldbus_driver.h>

Public Attributes

uint16_t alStatus = 0
 AL Status register 0x0130: state (bits 3:0) + error bit 4.
 
uint16_t alStatusCode = 0
 AL Status Code register 0x0134: error reason; 0 when no error.
 

Detailed Description

One slave's AL Status and AL Status Code registers — the "where" and the "why".

They answer different questions, from two ESC registers (ETG.1000.6 §6.4.1):

  • alStatus (register 0x0130): the slave's current situation — the AL state in bits 3:0 (1=INIT, 2=PRE-OP, 3=BOOT, 4=SAFE-OP, 8=OP) plus a bit-4 error indicator, set when the slave rejects a requested state change or faults. Decode via alState / alHasError.
  • alStatusCode (register 0x0134): why an error was raised — a diagnostic code for a failed transition. Meaningful only while alStatus's error bit is set (else 0x0000). Decode via alStatusCodeName / isAlStatusCodeTerminal.

Examples:

  • Healthy in OP: alStatus 0x0008 (OP, error bit clear), alStatusCode 0x0000.
  • Couldn't hold OP after outputs stopped: alStatus 0x0014 (SAFE-OP | error bit), alStatusCode 0x001B ("Sync manager watchdog").
  • Illegal INIT->OP jump rejected: alStatus 0x0011 (INIT | error bit), alStatusCode 0x0011 ("Invalid requested state change"). The two share the value 0x0011 only by coincidence and mean completely different things — which is why they are separate.

Member Data Documentation

◆ alStatus

uint16_t mm::comm::FieldbusDriver::SlaveStateRaw::alStatus = 0

AL Status register 0x0130: state (bits 3:0) + error bit 4.

◆ alStatusCode

uint16_t mm::comm::FieldbusDriver::SlaveStateRaw::alStatusCode = 0

AL Status Code register 0x0134: error reason; 0 when no error.


The documentation for this struct was generated from the following file: