diff --git a/src/ds/timer.c b/src/ds/timer.c index 748908c58..2cd661b7b 100644 --- a/src/ds/timer.c +++ b/src/ds/timer.c @@ -54,34 +54,34 @@ void DSTimerInit(struct DS* ds) { ds->ds7.timers[0].event.context = &ds->ds7; ds->ds7.timers[0].event.priority = 0x20; ds->ds7.timers[1].event.name = "DS7 Timer 1"; - ds->ds7.timers[0].event.callback = DSTimerUpdate1; - ds->ds7.timers[0].event.context = &ds->ds7; + ds->ds7.timers[1].event.callback = DSTimerUpdate1; + ds->ds7.timers[1].event.context = &ds->ds7; ds->ds7.timers[1].event.priority = 0x21; ds->ds7.timers[2].event.name = "DS7 Timer 2"; - ds->ds7.timers[0].event.callback = DSTimerUpdate2; - ds->ds7.timers[0].event.context = &ds->ds7; + ds->ds7.timers[2].event.callback = DSTimerUpdate2; + ds->ds7.timers[2].event.context = &ds->ds7; ds->ds7.timers[2].event.priority = 0x22; ds->ds7.timers[3].event.name = "DS7 Timer 3"; - ds->ds7.timers[0].event.callback = DSTimerUpdate3; - ds->ds7.timers[0].event.context = &ds->ds7; + ds->ds7.timers[3].event.callback = DSTimerUpdate3; + ds->ds7.timers[3].event.context = &ds->ds7; ds->ds7.timers[3].event.priority = 0x23; memset(ds->ds9.timers, 0, sizeof(ds->ds9.timers)); ds->ds9.timers[0].event.name = "DS9 Timer 0"; ds->ds9.timers[0].event.callback = DSTimerUpdate0; - ds->ds9.timers[0].event.context = ds; + ds->ds9.timers[0].event.context = &ds->ds9; ds->ds9.timers[0].event.priority = 0x20; ds->ds9.timers[1].event.name = "DS9 Timer 1"; ds->ds9.timers[1].event.callback = DSTimerUpdate1; - ds->ds9.timers[1].event.context = ds; + ds->ds9.timers[1].event.context = &ds->ds9; ds->ds9.timers[1].event.priority = 0x21; ds->ds9.timers[2].event.name = "DS9 Timer 2"; ds->ds9.timers[2].event.callback = DSTimerUpdate2; - ds->ds9.timers[2].event.context = ds; + ds->ds9.timers[2].event.context = &ds->ds9; ds->ds9.timers[2].event.priority = 0x22; ds->ds9.timers[3].event.name = "DS9 Timer 3"; ds->ds9.timers[3].event.callback = DSTimerUpdate3; - ds->ds9.timers[3].event.context = ds; + ds->ds9.timers[3].event.context = &ds->ds9; ds->ds9.timers[3].event.priority = 0x23; }