Did you try the character pacing define mentioned in my earlier post?
Did you try the character pacing define mentioned in my earlier post?
I tried character pacing and it had no effect on the way the menu displays. just mad it slower. I also tried making a new hyperterminal window also with no change. the menu displays the same on realterm and teraterm so the 1 line scrolling in hyperterminal was also not the problem.
Thank you for trying
jamie
I've run the routine you supplied, well ... had to add some stuff cause it was just a snippet, and my crystal was different.
It ended up looking like this ...And here is what it displayed ...Code:DEFINE OSC 10 SO VAR PORTC.6 SI VAR PORTC.7 Bank0A CON 0 ; No idea RTCHr VAR BYTE : RTCHr = $17 RTCMin VAR BYTE : RTCMin = $44 RTCSec VAR BYTE : RTCSec = $28 RTCMonth VAR BYTE : RTCMonth = 1 RTCDate VAR BYTE : RTCDate = 3 RTCYear VAR BYTE : RTCYear = 9 SamTime VAR BYTE : SamTime = 12 SYSVolts VAR BYTE : SYSVolts = 5 DirtyMem VAR BIT : DirtyMem = 1 TurStatus VAR BIT : TurStatus = 1 LogData VAR BIT : LogData = 1 PCCommand VAR BYTE : PCCommand = 0 ADDR VAR BYTE : ADDR = 0 Cont VAR BYTE : Cont = 0 Serout2 SO,32,[" ITCV2.0 Turbine Controller (SW - V1.0) System Voltage is ",Dec SYSVolts," Volts", 10,13] Serout2 SO,32,[" < ",HEX2 RTCHr,":",HEX2 RTCMin,":",HEX2 RTCSec," ",HEX2 RTCMonth,"/",HEX2 RTCDate,"/",HEX2 RTCYear," Sample time = ",Dec SamTime," Sec >",10,10,13] If DirtyMem <> 255 Then Serout2 SO,32,[27,91,53,109," MEMORY Contains DATA!",27,91,48,109,10,10,13] ' flash the text EndIf If TurStatus <> 255 Then Serout2 SO,32,[27,91,53,102," TURBINE IS DE-ACTIVATED!",27,91,48,109,10,10,13] ' flash the text EndIf Serout2 SO,32,[ " (1) Turbine Setup Menu (2) Download Memory Banks",13,10] Serout2 SO,32,[ " (3) Erase Memory Banks (4) Set the sample time",13,10] Serout2 SO,32,[ " (5) Set the Clock (6) Log Data ("] If LogData = 1 Then Serout2 SO,32,[ "ON)",13,10] Else Serout2 SO,32,[ "OFF)",13,10,13,10] EndIf Serout2 SO,32,[ " (C) CLEAR THE SCREEN",10,13] Serout2 SO,32,[ "HOLD (A) while LOGGING returns to this menu",13,10] SerIn2 SI,32,[PCCommand] If PCCommand = 49 Then TurbineSetup If PCCommand = 51 Then ClrMem If PCCommand = 53 Then SetClock If PCCommand = 52 Then SampleTime If PCCommand = 67 Or PCCommand = 99 Then Menu If PCCommand = 54 Then If LogData = 0 Then LogData = 1:GoTo Menu If LogData = 1 Then LogData = 0:GoTo Menu EndIf If PCCommand = 50 Then Serout2 SO,32,[ 13,10] ADDR = 0 Cont = Bank0A GoTo DumpMem EndIf TurbineSetup: ClrMem: SetClock: SampleTime: Menu: DumpMem:
<img src="http://www.picbasic.co.uk/forum/attachment.php?attachmentid=3092" /><!---->
The problem doesn't seem to be in that routine.
Maybe somewhere else in the code?
Need more Input.
<br>
DT
Darrel, Thats exactly as it's supposed to look. Thank you for verifying the code. I wonder if you hit 'C' and clear the screen a bunch of times does it screw up the display for you?
I will keep searching. That routine is was screws up on my end. if I try adding menu items (7) and (8) ect it really messes up.
I will look at it much closer
Thanks for taking the time Darrel
Jamie
I just realized the menu: lablel was missing from the top of the text
That whole routine is called menu so when you hit 'C' it just repaints it while clearing the screen
I added the routine Clearscreen: a few weeks ago to try and solve my problem but it never helped.
here it is
DEFINE OSC 10
SO VAR PORTC.6
SI VAR PORTC.7
RTCHr VAR BYTE : RTCHr = $17
RTCMin VAR BYTE : RTCMin = $44
RTCSec VAR BYTE : RTCSec = $28
RTCMonth VAR BYTE : RTCMonth = 1
RTCDate VAR BYTE : RTCDate = 3
RTCYear VAR BYTE : RTCYear = 9
SamTime VAR BYTE : SamTime = 12
SYSVolts VAR BYTE : SYSVolts = 5
DirtyMem VAR BIT : DirtyMem = 1
TurStatus VAR BIT : TurStatus = 1
LogData VAR BIT : LogData = 1
PCCommand VAR BYTE : PCCommand = 0
ADDR VAR BYTE : ADDR = 0
Cont VAR BYTE : Cont = 0
Menu:
Serout2 SO,32,[27,91,48,109]
GoSub ClearScreen:Serout2 SO,32,[27,91,48,109]
Serout2 SO,32,[" ITCV2.0 Turbine Controller (SW - V1.0) System Voltage is ",Dec SYSVolts," Volts", 10,13]
Serout2 SO,32,[" < ",HEX2 RTCHr,":",HEX2 RTCMin,":",HEX2 RTCSec," ",HEX2 RTCMonth,"/",HEX2 RTCDate,"/",HEX2 RTCYear," Sample time = ",Dec SamTime," Sec >",10,10,13]
If DirtyMem <> 255 Then
Serout2 SO,32,[27,91,53,109," MEMORY Contains DATA!",27,91,48,109,10,10,13] ' flash the text
EndIf
If TurStatus <> 255 Then
Serout2 SO,32,[27,91,53,102," TURBINE IS DE-ACTIVATED!",27,91,48,109,10,10,13] ' flash the text
EndIf
Serout2 SO,32,[ " (1) Turbine Setup Menu (2) Download Memory Banks",13,10]
Serout2 SO,32,[ " (3) Erase Memory Banks (4) Set the sample time",13,10]
Serout2 SO,32,[ " (5) Set the Clock (6) Log Data ("]
If LogData = 1 Then
Serout2 SO,32,[ "ON)",13,10]
Else
Serout2 SO,32,[ "OFF)",13,10,13,10]
EndIf
Serout2 SO,32,[ " (C) CLEAR THE SCREEN",10,13]
Serout2 SO,32,[ "HOLD (A) while LOGGING returns to this menu",13,10]
SerIn2 SI,32,[PCCommand]
If PCCommand = 49 Then TurbineSetup
If PCCommand = 51 Then ClrMem
If PCCommand = 53 Then SetClock
If PCCommand = 52 Then SampleTime
If PCCommand = 67 Or PCCommand = 99 Then Menu
If PCCommand = 54 Then
If LogData = 0 Then LogData = 1:GoTo Menu
If LogData = 1 Then LogData = 0:GoTo Menu
EndIf
If PCCommand = 50 Then
Serout2 SO,32,[ 13,10]
ADDR = 0
Cont = Bank0A
GoTo DumpMem
EndIf
ClearScreen:
serout2 SO,32,[27,91,50,74]
Return
TurbineSetup:
ClrMem:
SetClock:
SampleTime:
Menu:
DumpMem:
Still no problems Jamie.
I get the same screen, and when pressing C it redraws the screen.
Doesn't matter how many times or how fast I press C, it always comes up correct. I can press C fast enough that it misses some of them, but that's to be expected with SERIN2.
Do you have any other ANSI sequences in your program?
<br>
DT
Bookmarks