Hi Henrik,

Sorry to bother u again, but I am still new to PBP. I cant figure out how to view data stored in array on LCD in the format given in attatchment.

Please help me, if this work I can use the BCD data to change the frequecies of Third radio I have got. Entire idea is to recycle old radios in to something usefull.

below is my code . Pls bear with my stupid code.

Can u pls explain why have u declared array (mystring var byte (16) of 16.

Right now display shows some constant number " 253" when I choose R-10 radio in the PC software. If I choose another radio it doesnt show anything ecept LCD OK, which I have put in the code to check display.


'************************************************* *****************
@ device pic16F628A, intrc_osc_noclkout
trisb = %00000001
trisA = %11110011
include "modedefs.bas"
' Define LCD registers and bits
Define LCD_DREG PORTB
Define LCD_DBIT 4
Define LCD_RSREG PORTA
Define LCD_RSBIT 0
Define LCD_EREG PORTA
Define LCD_EBIT 1

DEFINE LCD_LINES 4 'Define using a 2 line LCD
DEFINE LCD_COMMANDUS 2000 'Define delay time between sending LCD commands
DEFINE LCD_DATAUS 50 'Define delay time between data sent.
'define osc 4
'* hser setup
DEFINE HSER_RCSTA 90h ' Enable serial port & continuous receive
DEFINE HSER_TXSTA 20h ' Enable transmit, BRGH = 0
DEFINE HSER_SPBRG 25 ' FOR 20MHZ 129 = 2400, 32=9600,25 @ 4 for 2400
DEFINE HSER_CLROERR 1 ' Clear overflow automatically
DEFINE HSER_BAUD 2400
cnt var byte
CMCON = 7 ' PORTA is digital
Pause 100 ' Wait for LCD to startup
r10data VAR BYTE[16]
lcdout $FE,1
LCDOUT "LCD OK"
PAUSE 200
clear

loop:

' CANT FIGURE OUT HOW TO EXTRACT NECESSARY BCD INFO FROM ARRAY

HSERIN WAIT($52,$E0), STR r10data\16\$FD]
'for cnt = 1 to 16
lcdout $FE,1
LCDOUT $fe,$80,dec r10data
'LCDOUT $fe,$c0+cnt," ",dec r10data [cnt]
'next cnt

PAUSE 10

GOTO LOOP

End
'************************************************* **************


hoping for some relpy from u, please help.

regards
vu2iia