firmware
v0.1.2
Chromation Spectrometer Dev-Kit
|
See cfg/microspec.json
in the Python API repository.
More...
#include "stdint.h"
#include "stdbool.h"
Go to the source code of this file.
Typedefs | |
typedef uint8_t const | status_code |
Status codes are type status_code . | |
typedef uint8_t const | led_state |
Indicator LEDs have three possible states: OFF , GREEN , and RED . | |
Functions | |
bool | led_setting_is_valid (led_state setting) |
Variables | |
status_code | OK |
status_code | ERROR |
status_code | INVALID_CMD |
led_state | OFF |
led_state | GREEN |
led_state | RED |
uint8_t | PADDING |
When status_code is ERROR, pad responses to send expected number of bytes. | |
See cfg/microspec.json
in the Python API repository.
"global"
defines the protocol byte codes."global"
definitions."protocol":"command"
defines the commands and command parameters sent by the USB host."protocol":"serial"
defines the expected response from the USB board usb-bridge
."protocol":"sensor"
defines the expected response from the sensor board vis-spi-out
.STATUS CODES
"globals"
defines the status codes: OK
, ERROR
, INVALID_CMD
OK
: the sender understood the message it just received and it successfully performed the taskERROR
: the sender understood the message but could not perform the taskINVALID_CMD
: the sender received an unrecognized commandINDICATOR LED STATES
"globals"
defines the LED states: OFF
, GREEN
, or RED
set
the indicator LEDget
the indicator LEDDefinition in file StatusCode.h.
|
inline |
led_setting_is_valid behavior:
Definition at line 53 of file StatusCode.h.