Skip to content

Commit

Permalink
Swap registers for mounted LED
Browse files Browse the repository at this point in the history
  • Loading branch information
sebromero committed Sep 9, 2024
1 parent 0c6cac0 commit 97371aa
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/registers.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,15 @@ constexpr RegisterInfo SLAVE_ADDRESS_REGISTER_INFO{0x01, "uint8", 1};
constexpr RegisterInfo CONTROL_REGISTER_INFO{0x02, "uint8", 1};
constexpr RegisterInfo ORANGE_LED_REGISTER_INFO{0x03, "uint8", 1};
constexpr RegisterInfo RGB_LED_RED_REGISTER_INFO{0x04, "uint8", 1};
constexpr RegisterInfo RGB_LED_GREEN_REGISTER_INFO{0x05, "uint8", 1};
constexpr RegisterInfo RGB_LED_BLUE_REGISTER_INFO{0x06, "uint8", 1};

/*
According to the firmware design speciation the Green LED register is at address 0x05
and the Blue LED register is at address 0x06. However due to a different LED
being used in the final design the addresses are swapped.
*/
constexpr RegisterInfo RGB_LED_GREEN_REGISTER_INFO{0x06, "uint8", 1};
constexpr RegisterInfo RGB_LED_BLUE_REGISTER_INFO{0x05, "uint8", 1};

constexpr RegisterInfo INTENSITY_REGISTER_INFO{0x07, "uint8", 1};
constexpr RegisterInfo UART_CONTROL_REGISTER_INFO{0x08, "uint8", 1};
constexpr RegisterInfo CSV_DELIMITER_REGISTER_INFO{0x09, "uint8", 1};
Expand Down

0 comments on commit 97371aa

Please sign in to comment.