main: fix disabling the twl4030 watchdog timer. - now uses the correct i2c chip id - now writes the address and data in one transaction. this is sufficent to get rid of the timeout errors. i have not yet tested it on real hardware.
1 files changed, 6 insertions(+), 5 deletions(-) M src/main.c
M src/main.c => src/main.c +6-5
@@ 39,11 39,12 @@ uxn_interrupt(void) void watchdog_init(void) { Uint8 data; Uint8 data[2]; /* silence the twl4030 watchdog (i hope) */ data = 0x5e; i2c_write(PHYSI2C1, 0x4a, &data, 1); data = 0; i2c_write(PHYSI2C1, 0x4a, &data, 1); data[0] = 0x5e; data[1] = 0x0; i2c_write(PHYSI2C1, 0x4b, data, 2); } @@ void 57,7 58,7 @@ main(void) i2c_init(PHYSI2C1); i2c_init(PHYSI2C2); /* watchdog_init(); NOT WORKING */ watchdog_init(); screen_init(&uxn_screen); uxn_init();