Serial Commands

Special Serial Commands

Through a Serial Terminal, not only motion data as described in Chapter 11 can be sent, but also additional control commands and data queries. This allows for controlling the controller.

Sending Commands:
Syntax:

  1. Startbytes: 2 bytes <f9><f9> (hex) or <249><249> (decimal)
  2. Command: 2 bytes <0-ffff> (hex) or <0..65535>
  3. Value: 2 bytes <0-ffff> (hex) or <0..65535>
  4. Stopbytes: 2 bytes <0a><0d> (hex) or <10><13>

Total of 8 bytes.

Receiving Commands:
Syntax:

  1. Startbytes: 2 bytes <f9><f9> (hex) or <249><249> (decimal)
  2. Command: 2 bytes <0-ffff> (hex) or <0..65535>
  3. Value: 2 bytes <0-ffff> (hex) or <0..65535>
  4. Stopbytes: 2 bytes <0a><0d> (hex) or <10><13>

Total of 8 bytes.

The command part always responds with the requested value.

Commands:

Commands:

  1. RIG Status
    • Send: f9f9 0000 0000 0a0d
    • Returns: f9f9 0000 XXXX 0a0d
    • Where XXXX is:
      • Preparing: 0x0000
      • Parking: 0x0001 or 0x0030
      • Emergency: 0x0002 or 0x0004
      • Offline: 0x0008, 0x0010, 0x0020
      • Ready: 0x0031
      • Standby: 0x0032
      • Wait UART: 0x0033, 0x0034
      • Online: 0x0035
  2. Port ID
    • Send: f9f9 0100 0000 0a0d
    • Returns: f9f9010001000a0d (motion USB port) or f9f9010002000a0d (native USB port)
  3. Firmware Version
    • Send: f9f9 0200 0000 0a0d
    • Returns: f9f9 0002 0002 0a0d (not implemented yet)
  4. Request Bootloader Mode
    • Send: f9f9 0300 0000 0a0d
    • Returns: Reboots to bootloader mode
  5. Enable Soft Override for Handheld App
    • Send: f9f9 0400 0000 0a0d
    • Returns: f9f9 0004 0002 0a0d
  6. Enable Emergency
    • Send: f9f9 0500 0000 0a0d
    • Returns: f9f9 0005 00xx 0a0d (emergency status 0 or 1)
  7. Enable Online
    • Send: f9f9 0600 0000 0a0d
    • Returns: f9f9 0006 00xx 0a0d (online status 0 or 1)
  8. Factory Reset
    • Send: f9f9 0800 00xx 0a0d (0 for linear, 1 for rotary)
    • Returns: f9f9 0800 0001 0a0d (reboots)
  9. Reboot
    • Send: f9f9 0900 0000 0a0d
    • Returns: (no response)
  10. Request Actuators Status
    • Send: f9f9 1000 0000 0a0d
    • Returns: f9f9 1000 00xx 0a0d where xx is:
      • ‘x’: not connected
      • ‘C’: Calibrating
      • ‘P’: Preparing
      • ‘!’: Moving
      • ‘R’: Ready
  1. Request Mastergain
    • Send: f9f9 3000 0000 0a0d
    • Return: f9f9 0030 00XX 0a0d (where XX ranges from 1-40*10 in %, where 10 represents 100%)
  2. Set Mastergain
    • Send: f9f9 3100 00XX 0a0d (where XX ranges from 1-40)
    • Return: f9f9 0031 0002 0a0d (if set)
  3. Set Filter
    • Send: f9f9 4000 XXXX 0a0d (to set filter to XXXX or read if XXXX=0)
    • Return: f9f9 4000 XXXX 0a0d (returns filter size, emalp)
  4. Enable/Disable Filter
    • Send: f9f9 4100 XXXX 0a0d (to enable/disable filter, where XXXX = 1 or 0)
    • Return: filterstat if XXXX=2
  5. Enable/Disable Spikefilter
    • Send: f9f9 4200 XXXX 0a0d (to enable/disable spikefilter, where XXXX = 1 or 0)
    • Return: f9f9 0042 XXXX 0a0d (returns filterstat if XXXX=2)
  6. Set Spikefilter
    • Send: f9f9 4300 XXXX 0a0d (to set spikefilter to XXXX or read if XXXX=0)
    • Return: f9f9 4300 XXXX 0a0d (returns spike filter size)
  7. Set Spikefilterwindows
    • Send: f9f9 4400 XXXX 0a0d (to set spikefilterwindows to XXXX or read if XXXX=0)
    • Return: f9f9 0044 XXXX 0a0d (returns spike filter size)
  8. Homing
    • Send: f9f9 5000 0000 0a0d
  9. Send Display Frame
    • Send: f9f9 0060 0000 0a0d (send display frame back, ask for details)
    • Returns: 38 bytes f9f9, followed by 32 bytes of characters of display 0a0d
  10. Encoder Button Pressed
    • Send: f9f9 0070 0000 0a0d
  11. Encoder Left Pressed
    • Send: f9f9 0071 0000 0a0d
  12. Encoder Right Pressed
    • Send: f9f9 0072 0000 0a0d
  13. Go Online After Homing Without Input
    • Send: f9f9 0080 0000 0a0d

These commands provide various functionalities for controlling the controller and interacting with the system.

Leave a Reply

Your email address will not be published. Required fields are marked *