1 #ifndef EAGLE_EBOARD_HELPLIB_I2CINOUT 2 #define EAGLE_EBOARD_HELPLIB_I2CINOUT 6 #define DIGITAL_IN_INV 0x1 8 #define DIGITAL_IN_PULLUP 0x2 10 #define DIGITAL_IN_PULLUP_INV 0x3 12 #define DIGITAL_OUT 0x4 14 #define DIGITAL_OUT_INV 0x5 16 #define DIGITAL_OUT_LOW 0x6 18 #define DIGITAL_OUT_HIGH 0x7 20 #define ANALOG_IN_8_BIT 0x8 22 #define ANALOG_IN_10_BIT 0x9 24 #define ANALOG_IN_MEAN_8_BIT 0xA 26 #define ANALOG_IN_MEAN_10_BIT 0xB 28 #define COUNTER_8_BIT 0xC 30 #define COUNTER_16_BIT 0xD 32 #define COUNTER_RISE_8_BIT 0xE 34 #define COUNTER_RISE_16_BIT 0xF 44 #define COUNTER_B_DIR 0xC 46 #define COUNTER_B_DIR_PULLUP 0xD 48 #define COUNTER_MEAN_8_BIT 0xE 50 #define COUNTER_MEAN_16_BIT 0xF 83 #if EBOARD_USE_UTILITY > 0x0 84 inline void read(
void);
95 inline void write(
void);
107 this->
A=0x0;this->
B=0x0;this->
C=0x0;
109 #if EBOARD_USE_UTILITY > 0x0 110 void I2CInOut::read(
void) {}
111 void I2CInOut::changeAddress(
optVAL_t){}
void writePWM(optVAL_t val)
write a clamped pwm value to an output pin
optVAL_t C
storing value for C-pin [MOTOR SPE]
[COPY&PASTE] This is the SoccerBoard ghost struct :D
void write(void)
this will write values stored in B and C
optVAL_t B
storing value for B-pin [MOTOR DIR]
I2CInOut(SoccerBoard &, optVAL_t, optVAL_t, optVAL_t, optVAL_t)
The constructor.
[COPY&PASTE] This is the I2CInOut ghost struct :D
optVAL_t A
storing value for A-pin (๐ง I prevent errors!)