Skip to content

Commit 57baa03

Browse files
authored
Fix I2C slave compilation error for CH32V30x (openwch#126)
See issue openwch#124
1 parent 75335cf commit 57baa03

File tree

1 file changed

+2
-2
lines changed
  • libraries/Wire/src/utility

1 file changed

+2
-2
lines changed

libraries/Wire/src/utility/twi.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -679,12 +679,12 @@ void I2C2_EV_IRQHandler(void) __attribute__((interrupt("WCH-Interrupt-fast")));
679679
void I2C2_EV_IRQHandler(void)
680680
{
681681
#if OPT_I2C_SLAVE
682-
//I2C_HandleTypeDef *handle = i2c_handles[I2C2_INDEX]; // MMOLE: was commented
682+
I2C_HandleTypeDef *handle = i2c_handles[I2C2_INDEX]; // MMOLE: was commented
683683
// MMOLE: I2C2_EV_IRQHandler is the event handler, handle is an I2C_HandleTypeDef struct containing parameters and pointer to the registers
684684
static int _nCounterEV2=1;
685685
_nCounterEV2++;
686686
i2c_slave_process(get_i2c_obj(handle)); // process I2C transmissions, for now only events, not errors
687-
// MMOLLE: tested only using I2C1
687+
// MMOLE: tested only using I2C1
688688
#endif
689689
}
690690

0 commit comments

Comments
 (0)