sylvandb / gruvin9x

Automatically exported from code.google.com/p/gruvin9x
0 stars 0 forks source link

WDT reset when trying to access model menu #62

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
As at r1154

What steps will reproduce the problem?
1. Switch on
2. Attempt to enter model menu [RIGHT LONG]

Note that the model menu appears briefly but the system immediately reboots.
 (A WDT reset? Perhaps there's an unintentional infinite loop occurring?)

The RADIO SETUP menu and all other functions appear to be working OK.

Original issue reported on code.google.com by gru...@gmail.com on 14 Oct 2011 at 1:04

GoogleCodeExporter commented 8 years ago
Fault is not evident in simu, which appears to work fine still.

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:05

GoogleCodeExporter commented 8 years ago
Fault was first noted on stock '64 chip radio -- not V4.

But V4 is worse -- the system boot up but starts spewing random characters all 
over the screen -- just sitting in main views.

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:07

GoogleCodeExporter commented 8 years ago
r1151 is OK. Seems to be the changes made in r1152 causing the problem.

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:11

GoogleCodeExporter commented 8 years ago
No -- r1152 is OK. Fault appears at r1153. Confirmed.

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:13

GoogleCodeExporter commented 8 years ago
Hmmm. Looked through all DIFFs for r1153 but can't see anything that would 
cause this. :/ 

Tested r1153 on simu (PCB=STD). No fault observed.

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:21

GoogleCodeExporter commented 8 years ago
Something is going wring with the pointer her (lcd.cpp)

putsStrIdx(x, y, PSTR("MODEL"), id+1, att|LEADING0);

The screen displays only " 03", instead of "MODEL03" before crashing.

Must be some compiler issue to do with pgmspace pointers again

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:29

GoogleCodeExporter commented 8 years ago
Very strange. Somehow, BSS flag is being set in function call chain from 
putsModelName

putsModelName(4*FW, y, name, k, 0); <-- att is clearly 0

putsStrIdx(x, y, PSTR("MODEL"), id+1, att|LEADING0); <-- BSS flag is NOT set. 
CRASH though.

putsStrIdx(x, y, PSTR("MODEL"), id+1, att|LEADING0 &~BSS); <-- No crash. All 
works.

Something must be wrong with LEADING0 flag?!? :/ Huh?

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:54

GoogleCodeExporter commented 8 years ago
Yes -- when I add &BSS, LEADING0 is dropped as well (MODE3 instead of MODEL03 
appears). There is a flag bit conflict.

I best leave this one to you now Bertrand.

Original comment by gru...@gmail.com on 14 Oct 2011 at 1:56

GoogleCodeExporter commented 8 years ago
Oh I see the problem. BSS and ZCHAR were intended only for 'puts', while 
LEADING0, etc were intended only for outdez. We are now mixing both functions. 
DOH.

Original comment by gru...@gmail.com on 14 Oct 2011 at 4:40

GoogleCodeExporter commented 8 years ago
Changed to low priority, since I have a reasonable patch installed now.

Original comment by gru...@gmail.com on 14 Oct 2011 at 7:46

GoogleCodeExporter commented 8 years ago

Original comment by gru...@gmail.com on 14 Oct 2011 at 7:46

GoogleCodeExporter commented 8 years ago

Original comment by bson...@gmail.com on 14 Oct 2011 at 7:58