The control flow assumes different behavior, at least two.
In the main function, the case instruction for time-slice (voic.c line 74) some times is reached, some times not.
I’ve looking for a program bug and have rewrited this logic many times in different ways, sorry but is possible there are a program bug that I can’t see.
Compiler version is
SDCC : mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/ds400/hc08 2.6.3 #4543 (Dec 31 2006) (MINGW32)
With Bug #1683515 fixed by program code (FSR saving).
whole project
Logged In: YES
user_id=1115835
Originator: NO
The archive you submitted contains an old libsdcc.lib, which does neither include the __sdcc_gsinit_startup routine nor __saved_fsr --> the code does not compile with a current SDCC. OK, these are not required (introduced on 2007-01-22)...
Hmm, can you give more details?
- How did ypu find out, that the case is reached sometimes?
- What symptoms do you observe?
- Does Timer0 cause unwanted interrupts?
- Is the watchdog disabled?
You might need to define some config word a la
__code unsigned __at(0x2007) foobar = _WDT_OFF & _BODEN_OFF & _PWRTE_OFF & _RC_OSC;
HTH,
Raphael
Logged In: YES
user_id=1694633
Originator: YES
- How did ypu find out, that the case is reached sometimes? When not
reached, the procedures portamento(), ringmodulator() and wave_sel()
didn't respond to voltage control changes.
- What symptoms do you observe? Idem above.
- Does Timer0 cause unwanted interrupts? No, only via software.
- Is the watchdog disabled? Yes
config word (setting through IC-Prog)
__code unsigned __at(0x2007) foobar = _WDT_OFF & _BODEN_OFF & _PWRTE_OFF &
_RC_OSC;
Ok for the fuses, but oscillator is set to HS because the fosc is 20 Mhz.
Logged In: NO
Compiled with the new version (20070330-4720) and the program don't run at all.
Goback with 2.6.3 and everything run again, with the same bug of course.
Logged In: YES
user_id=1115835
Originator: NO
I just fixed item #1704666 (Do "PAGESEL _main" prior to "GOTO _main") in SDCC r4767, could you try whether this also fixes this problem? At least the code should run again with the current svn revision, probably with the same bug as before.