
Originally Posted by
Darrel Taylor
The Scott Edwards display is expecting Inverted serial levels.
The USART puts out True levels by default.
Add this setting ...
Code:
BAUDCON.4 = 1 ; Transmit inverted data to the TX/CK pin
Thanks Darrel! It works now except the LCD shows a strange character in the 1st position (looks like "F1" with the "1" being a subscript).
Code:
#IFDEF USE_LCD_FOR_DEBUG
HSEROUT [LCD_INST, LCD_CLR]
pause 5
HSEROUT ["DutyVar1=", DEC DutyVar1, 13, 10] ' Send text followed by carriage return and linefeed
#ENDIF
Main:
ADCIN 1, adval
if adval <> oldDutyVar1 then
oldDutyVar1 = adval
DutyVar1 = adval
#IFDEF USE_LCD_FOR_DEBUG
HSEROUT [LCD_INST, LCD_CLR, LCD_L1]
HSEROUT ["DutyVar1=", DEC DutyVar1, " ", 13, 10] ' Send text followed by carriage return and linefeed
#ENDIF
EndIf
Pause 100
Goto Main
Bookmarks