mirror of
https://github.com/BotChain-Robots/firmware.git
synced 2026-07-08 17:47:21 +02:00
Display control code
This commit is contained in:
@@ -9,7 +9,13 @@
|
||||
|
||||
#include "flatbuffers_generated/RobotModule_generated.h"
|
||||
|
||||
inline std::unordered_map<int, int> MODULE_TO_NUM_CHANNELS_MAP {{ModuleType_SPLITTER, 4}, {ModuleType_SERVO_1, 2}, {ModuleType_DC_MOTOR, 1}, {ModuleType_SERVO_2, 2}};
|
||||
inline std::unordered_map<int, int> MODULE_TO_NUM_CHANNELS_MAP {
|
||||
{ModuleType_SPLITTER, 4},
|
||||
{ModuleType_SERVO_1, 2},
|
||||
{ModuleType_DC_MOTOR, 1},
|
||||
{ModuleType_SERVO_2, 2},
|
||||
{ModuleType_DISPLAY, 1}
|
||||
};
|
||||
|
||||
#define PC_ADDR 0
|
||||
|
||||
@@ -22,6 +28,9 @@ inline std::unordered_map<int, int> MODULE_TO_NUM_CHANNELS_MAP {{ModuleType_SPLI
|
||||
#define DC_ENCODER_A 15
|
||||
#define DC_ENCODER_B 16
|
||||
|
||||
#define OLED_SDA 17
|
||||
#define OLED_SCL 18
|
||||
|
||||
inline std::unordered_map<uint8_t, uint8_t> CHANNEL_TO_0_DEG_MAP{{0, 9} };
|
||||
inline std::unordered_map<uint8_t, uint8_t> CHANNEL_TO_90_DEG_MAP{{0, 7} };
|
||||
inline std::unordered_map<uint8_t, uint8_t> CHANNEL_TO_180_DEG_MAP{{0, 8} };
|
||||
|
||||
Reference in New Issue
Block a user