HP-15C LE -- endless loop in SOLVER



#9

The HP-15C LE will alternate forever between "running" and "Error 0" in this example:

001- f LBL A
002- g LN
003- /
004- g pi
005- -
006- g RTN

1 ENTER f SOLVE A -> running
Error 0
running
Error 0
.
.
.


#10

Interesting. The 15C emulator in Nonpareil gets stuck at the first error message, as would be expected. I suppose the original 15C behaves the same. This is strange, since the 15C LE is based on the same firmware. The error handling seems to be influenced in some way.


#11

Quote:
Interesting. The 15C emulator in Nonpareil gets stuck at the first error message, as would be expected. I suppose the original 15C behaves the same. This is strange, since the 15C LE is based on the same firmware. The error handling seems to be influenced in some way.

I'd be quite surprised if this was due to a change in the
firmware error handling behaviour peculiar to the 15c le.

Gerson, is the alternating between "running" and "Error 0"
occurring at the same rate of the display blink frequency?
[I don't have a 15c le handy ATM.] If so I'd make a wild
guess this is somehow due to the display update minimization
logic along with an interaction of exiting the emulator driven
display blink mode. Although I can't really think of a reason
a shadow of the prior display contents would be needed.

Running this on KEMU I find the expected behaviour. The display
update sequence preceding this point looks quite vanilla as well
so I don't have a better guess.


#12

Yes, exactly the same rate of the display blinking frequency (according to my measurement).


#13

You can stop it with any key. It looks like a display problem.


#14

No big issue like the PSE bug, I agree, but worth taking into account in a future firmware upgrade.

#15

Quote:
Although I can't really think of a reason
a shadow of the prior display contents would be needed.

Ah, I suspected it may be rooted in the lcd controller as it
does provide a hardware timed blink. See section 34.5.6 Buffer
Swap Mode (pg 502)
here for details. There is a two level data
buffering scheme allowing update to a yet-to-be-displayed buffer
which is subsequently transferred to the lcd display (multiplex
scan) buffer. If the lcd controller is placed in "Buffer Swap Mode"
the data driven to the display will alternate between both buffers
at the hardware blink frequency. Seems like the controller is
unintentionally winding up in this mode vs. (presumably)
Normal Mode.


#16

You need to wait long enough after you have written to display memory before you can safely change the mode. The docs say it takes 2 refresh cycles but my experience is that waiting even longer is a good idea. WP 34S does not do a busy wait, the display refresh triggers an interrupt (at roughly 50 Hz) and the number of interrupts is counted. The logic is in the sources in main.c under LCD_interrupt():

	/*
* Wait for LCD controller to copy the user buffer to the display buffer.
* Then turn off the automatic update.
* WaitForLcd is set to 1 by finish_display()
*/
if ( WaitForLcd ) {
if ( ++WaitForLcd == 3 ) {
SLCDC_SetDisplayMode( AT91C_SLCDC_DISPMODE_LOAD_ONLY );
}
else if ( WaitForLcd == 4 ) {
WaitForLcd = 0;
}
}
I'm not using the blink option but I need the display memory for storing intermediate data. If I remove the 'else' part and clear the variable directly after mode switching, display memory gets corrupted. The trick is to wait for another cycle after switching to 'load only' mode.
#17

The emulator just blinks w/o showing 'running'.

Why does it blink in the first place?

#18

The HHC2010 15C+ just stops with Error 0.


Possibly Related Threads…
Thread Author Replies Views Last Post
  hp-prime solver and variable name fabrice48 22 8,482 12-10-2013, 03:25 AM
Last Post: fabrice48
  Solver issue with HP 17BII - different from 19BII Jeff Kearns 13 4,707 11-28-2013, 02:36 AM
Last Post: Don Shepherd
  HP Prime Triangle solver BruceH 29 8,805 11-28-2013, 12:03 AM
Last Post: Dale Reed
  HP prime: linear solver app Alberto Candel 1 1,458 11-21-2013, 01:57 AM
Last Post: Michael Carey
  HP Prime: Linear Solver app bug BruceH 0 1,167 11-15-2013, 06:36 PM
Last Post: BruceH
  HP Prime Solver Variables Issue Anibal Morones Ruelas 8 3,139 10-19-2013, 09:45 AM
Last Post: Harold A Climer
  WP34s integration trapped in infinite loop Bernd Grubert 25 7,099 10-17-2013, 08:50 AM
Last Post: Dieter
  HP Prime triangle solver oddity BruceH 0 1,069 10-13-2013, 09:08 PM
Last Post: BruceH
  Using units in Numeric Solver Harold A Climer 1 1,293 10-13-2013, 10:44 AM
Last Post: Tim Wessman
  Meltiple Equation Solver PRIME Vs. HP 50G Harold A Climer 5 1,867 10-07-2013, 05:11 PM
Last Post: CR Haeger

Forum Jump: