Legacy Forum: Preserving Nearly 20 Years of Community History - A Time Capsule of Discussions, Memories, and Shared Experiences.

LCD for RN1

Hitec robotics including ROBONOVA humanoid, HSR-8498HB servos, MR C-3024 Controllers and RoboBasic
62 postsPage 3 of 51, 2, 3, 4, 5
62 postsPage 3 of 51, 2, 3, 4, 5

Post by Gort » Thu Jan 24, 2008 3:34 am

Post by Gort
Thu Jan 24, 2008 3:34 am

Sorry no, I have been busy helping out a school with their First robot. It has too be a problem with the baud rate. At lest now I know it is just not my LCD. We need to find a way to set then write the Baud rate to the EEPROM.
Sorry no, I have been busy helping out a school with their First robot. It has too be a problem with the baud rate. At lest now I know it is just not my LCD. We need to find a way to set then write the Baud rate to the EEPROM.
Gort
Savvy Roboteer
Savvy Roboteer
User avatar
Posts: 555
Joined: Wed May 31, 2006 1:00 am
Location: KC, MO, USA

Post by Entrastic » Thu Jan 24, 2008 5:05 am

Post by Entrastic
Thu Jan 24, 2008 5:05 am

The baud rate is being set properly when I use i-Bot's program. I am even able to print the test message on screen properly provided I dont unplug the power of the LCD. This means that the commands are perfect, and the communication between LCD and robonova is working. However, for osme irritating reason, it is not getting stored in the EEPROM. It gets restored to 9600 when disconnected from power.
The baud rate is being set properly when I use i-Bot's program. I am even able to print the test message on screen properly provided I dont unplug the power of the LCD. This means that the commands are perfect, and the communication between LCD and robonova is working. However, for osme irritating reason, it is not getting stored in the EEPROM. It gets restored to 9600 when disconnected from power.
Entrastic
Savvy Roboteer
Savvy Roboteer
Posts: 31
Joined: Fri Oct 05, 2007 7:43 am

Post by Entrastic » Thu Jan 24, 2008 7:06 am

Post by Entrastic
Thu Jan 24, 2008 7:06 am

ok this is weird..

i unplugged the LCD out of the robot today and supplied external power and connected it to a PC using a level shifter. When I ran hyperterminal, i found that the baud rate was alread set to 4800. I didnot use the hyperterminal to change the baud rate. It was already seet to 4800. So now the situation is even worse. The baud rate is somehow getting stored in the EEPROM and being loaded on power up. but the LCD for some other reason is not compatible with the c3024 board.

Now I know for sure that the baud rate is 4800, i will connect it back to my robot and try the LCD port and print commmand again. I will let you all know whether it is still giving me garbage.
ok this is weird..

i unplugged the LCD out of the robot today and supplied external power and connected it to a PC using a level shifter. When I ran hyperterminal, i found that the baud rate was alread set to 4800. I didnot use the hyperterminal to change the baud rate. It was already seet to 4800. So now the situation is even worse. The baud rate is somehow getting stored in the EEPROM and being loaded on power up. but the LCD for some other reason is not compatible with the c3024 board.

Now I know for sure that the baud rate is 4800, i will connect it back to my robot and try the LCD port and print commmand again. I will let you all know whether it is still giving me garbage.
Entrastic
Savvy Roboteer
Savvy Roboteer
Posts: 31
Joined: Fri Oct 05, 2007 7:43 am

Post by i-Bot » Thu Jan 24, 2008 10:53 am

Post by i-Bot
Thu Jan 24, 2008 10:53 am

I am thinking it may be a power or power on problem.

My LCD is on a C3024 with not many devices powered from 5V. I did not try on my fully loaded RN, because that has special firmware and is 9600 on the LCD port.

The SerLCD backlight take quite a load, so I am wondering if powerup is too slow or something. So it may take defaults rather than EEPROM values.

When the speed is right, then there is no compatability problem, except you use the SerLCD commands for clear screen and cursor position, not the RoboBasic commands.

If you are willing to reflash your C3024, then it may be easier to set that to 9600.
I am thinking it may be a power or power on problem.

My LCD is on a C3024 with not many devices powered from 5V. I did not try on my fully loaded RN, because that has special firmware and is 9600 on the LCD port.

The SerLCD backlight take quite a load, so I am wondering if powerup is too slow or something. So it may take defaults rather than EEPROM values.

When the speed is right, then there is no compatability problem, except you use the SerLCD commands for clear screen and cursor position, not the RoboBasic commands.

If you are willing to reflash your C3024, then it may be easier to set that to 9600.
i-Bot
Savvy Roboteer
Savvy Roboteer
User avatar
Posts: 1142
Joined: Wed May 17, 2006 1:00 am

Post by Entrastic » Fri Jan 25, 2008 5:05 pm

Post by Entrastic
Fri Jan 25, 2008 5:05 pm

I would happily refalsh the c3024 but the only problem is that the Robonova I am working on is not mine!! its a part of a school project.

I know i posted in my last mail that it appeared as if the baud rate change is getting stored in the EEPROM, it didnt work today. The baud rate was not getting stored. I was starting to get really irritated and abort hte whole plan of using LCD when I received a reply from the Sparkfun technical support. I have pasted the mail below...

"
Hi,

If you look through the code for the serial LCD. The baud rate change is not permanently stored in EEPROM. In the datasheet it says that all settings are stored on onboard EEPROM, these are the settings that allow communication to the HD44780 controller on the LCD. If you want to permanently change the settings, you will need to alter the code on the PIC to store the setting in EEPROM.

"


i-Bot, are you sure that ur BD is getting stored in EEPROM. Coz I do not completely trust the Sparkfun people.

By the way, for everyone who wants to use this LCD on the C3024 LCD port, the easiest and simplest way to do that would be to use a 5V relay to switch between the serial port and LCD port. Connect the NC to the LCD port and the NO to the LCD port. activate the relay using some other port by outputting a digital 1 ( command OUT 32, 1 for AD0). Of course, the signal pin of that port shud be connected to the Vcc of the relay. Send the two commands to change the baud rate and turn off the relay by outputting a 0. now u can use the LCD using hte normal PRINT commands

I know its kinda silly, but it works perfectly and is really simple. If you have something else attached to ur serial port, u can use another set of contact in ur relay ( buy a relay with multiple NC/NO contacts) to disconnect it while the LCD is connected to the serial port ( That is connect the serial device to the NC with the serial port as common).

I guess I am gonna continue doing that. Since the LCD port is connected to the NC of the relay, there is no power consumption also except for couple of second used to change the baud rate.

Changin gthe baud rate can be one of hte first things u do in ur program before ur main program so that the new BD will be maintained for the rest of the programs and the serial port will be free
I would happily refalsh the c3024 but the only problem is that the Robonova I am working on is not mine!! its a part of a school project.

I know i posted in my last mail that it appeared as if the baud rate change is getting stored in the EEPROM, it didnt work today. The baud rate was not getting stored. I was starting to get really irritated and abort hte whole plan of using LCD when I received a reply from the Sparkfun technical support. I have pasted the mail below...

"
Hi,

If you look through the code for the serial LCD. The baud rate change is not permanently stored in EEPROM. In the datasheet it says that all settings are stored on onboard EEPROM, these are the settings that allow communication to the HD44780 controller on the LCD. If you want to permanently change the settings, you will need to alter the code on the PIC to store the setting in EEPROM.

"


i-Bot, are you sure that ur BD is getting stored in EEPROM. Coz I do not completely trust the Sparkfun people.

By the way, for everyone who wants to use this LCD on the C3024 LCD port, the easiest and simplest way to do that would be to use a 5V relay to switch between the serial port and LCD port. Connect the NC to the LCD port and the NO to the LCD port. activate the relay using some other port by outputting a digital 1 ( command OUT 32, 1 for AD0). Of course, the signal pin of that port shud be connected to the Vcc of the relay. Send the two commands to change the baud rate and turn off the relay by outputting a 0. now u can use the LCD using hte normal PRINT commands

I know its kinda silly, but it works perfectly and is really simple. If you have something else attached to ur serial port, u can use another set of contact in ur relay ( buy a relay with multiple NC/NO contacts) to disconnect it while the LCD is connected to the serial port ( That is connect the serial device to the NC with the serial port as common).

I guess I am gonna continue doing that. Since the LCD port is connected to the NC of the relay, there is no power consumption also except for couple of second used to change the baud rate.

Changin gthe baud rate can be one of hte first things u do in ur program before ur main program so that the new BD will be maintained for the rest of the programs and the serial port will be free
Entrastic
Savvy Roboteer
Savvy Roboteer
Posts: 31
Joined: Fri Oct 05, 2007 7:43 am

Post by i-Bot » Fri Jan 25, 2008 5:46 pm

Post by i-Bot
Fri Jan 25, 2008 5:46 pm

I just turned m C3024 and SerLCD on with serLCD on the ERX port.

Ran
ETX 4800, &HFE
ETX 4800, &H01
ETX 4800, 52
ETX 4800, 56
ETX 4800, 48
ETX 4800, 48
and the display read "4800"

I don't trust the reply from Sparkfun.

When they say "If you look through the code for the serial LCD" ,V2.5 of the source code is not released only V2 is released. Sure in V2 the speed is not saved to EEPROM, but then you can't even change the speed in V2.

The V2.5 datasheet Section 3 says all settings are saved, and there is even a description of how to reset to 9600 during the splash screen.

I had a reply on the Sparkfun forum from someone else who could not get the baud rate to stick either.

Do other things save to EEPROM OK, like the backlight and splash screen enable ?
I just turned m C3024 and SerLCD on with serLCD on the ERX port.

Ran
ETX 4800, &HFE
ETX 4800, &H01
ETX 4800, 52
ETX 4800, 56
ETX 4800, 48
ETX 4800, 48
and the display read "4800"

I don't trust the reply from Sparkfun.

When they say "If you look through the code for the serial LCD" ,V2.5 of the source code is not released only V2 is released. Sure in V2 the speed is not saved to EEPROM, but then you can't even change the speed in V2.

The V2.5 datasheet Section 3 says all settings are saved, and there is even a description of how to reset to 9600 during the splash screen.

I had a reply on the Sparkfun forum from someone else who could not get the baud rate to stick either.

Do other things save to EEPROM OK, like the backlight and splash screen enable ?
i-Bot
Savvy Roboteer
Savvy Roboteer
User avatar
Posts: 1142
Joined: Wed May 17, 2006 1:00 am

Post by Entrastic » Fri Jan 25, 2008 6:01 pm

Post by Entrastic
Fri Jan 25, 2008 6:01 pm

Actually, I dont trust hte LCD at all.

I dont have much experience with serial communication, but I know this quite weird. Yesterday I plugged the LCD into my robot. This is the code I used

send="T"
etx 9600, send
delay 500

send="E"
etx 9600, send
delay 500

send="S"
etx 9600, send
delay 500

send="T"
etx 9600, send
delay 500


L1: A=remocon(1)
if A<>1 then goto L1

print " LCD"

I upoloaded the code into the robot and plugged in the LCD. I had chaged the BD to 4800 before. I wanted to check whether the CD had gotten stored in the EEPROM. So I ran the code with te LCD plugged initially to the C3024 serial port. It displayed "TEST". So I thot the BD had not gotten stored in the EEPROM. Then I unplugged only the signal cable( leaving hte LCD still on) and plugged it into the LCD port expecting to get garbage result. But it actually print "LCD".

I ran this couple of times to make sure I am not doing nything wrong. But the result was the same.

How is this even possible?? Whats the possible mistake I made?
Actually, I dont trust hte LCD at all.

I dont have much experience with serial communication, but I know this quite weird. Yesterday I plugged the LCD into my robot. This is the code I used

send="T"
etx 9600, send
delay 500

send="E"
etx 9600, send
delay 500

send="S"
etx 9600, send
delay 500

send="T"
etx 9600, send
delay 500


L1: A=remocon(1)
if A<>1 then goto L1

print " LCD"

I upoloaded the code into the robot and plugged in the LCD. I had chaged the BD to 4800 before. I wanted to check whether the CD had gotten stored in the EEPROM. So I ran the code with te LCD plugged initially to the C3024 serial port. It displayed "TEST". So I thot the BD had not gotten stored in the EEPROM. Then I unplugged only the signal cable( leaving hte LCD still on) and plugged it into the LCD port expecting to get garbage result. But it actually print "LCD".

I ran this couple of times to make sure I am not doing nything wrong. But the result was the same.

How is this even possible?? Whats the possible mistake I made?
Entrastic
Savvy Roboteer
Savvy Roboteer
Posts: 31
Joined: Fri Oct 05, 2007 7:43 am

Post by i-Bot » Fri Jan 25, 2008 8:03 pm

Post by i-Bot
Fri Jan 25, 2008 8:03 pm

When I run your code with my display at 4800, I see four garbage characters on ERX, then "LCD" on lcd. When at 9600, I see TEST on ERX, then rubbish on LCD.

I read the 16F688 on the serlcd . The code is not the same as on the Sparkfun site.

I see a location in EEPROM (0x2D) change when I change the speed (4800 = 1, 9600 = 2)

Maybe there are different code versions out there. Do you have an ICD2 or Pickit ? I can send you my hex file.

Or maybe better to bang the table at Sparkfun
When I run your code with my display at 4800, I see four garbage characters on ERX, then "LCD" on lcd. When at 9600, I see TEST on ERX, then rubbish on LCD.

I read the 16F688 on the serlcd . The code is not the same as on the Sparkfun site.

I see a location in EEPROM (0x2D) change when I change the speed (4800 = 1, 9600 = 2)

Maybe there are different code versions out there. Do you have an ICD2 or Pickit ? I can send you my hex file.

Or maybe better to bang the table at Sparkfun
i-Bot
Savvy Roboteer
Savvy Roboteer
User avatar
Posts: 1142
Joined: Wed May 17, 2006 1:00 am

Post by Gort » Thu Jan 31, 2008 4:12 am

Post by Gort
Thu Jan 31, 2008 4:12 am

Is there a way to set the baud rate when the LCD is connected to the LCD port?
Is there a way to set the baud rate when the LCD is connected to the LCD port?
Gort
Savvy Roboteer
Savvy Roboteer
User avatar
Posts: 555
Joined: Wed May 31, 2006 1:00 am
Location: KC, MO, USA

Post by treborz » Mon Feb 11, 2008 3:59 am

Post by treborz
Mon Feb 11, 2008 3:59 am

*** RX output port not working ***

Can someone with a working RN-1 RX/TX port tell me what voltage they get from RX AND TX to GND, or if someone already knows what it should be, please advise me?

I was able to use the Rx output port with an ETX command and receive it properly on my test accessory that activates a sound effect. In the mean time I wired the RX output port for another project. During this test I burned out a computer chip on the accessory apparently due to my shorting a wire. Since then I have not been able to get the RX port to work with my original project. I get a 5volt drop on the TX port without any programs running but only get a trace of voltage on the RX port. Is this correct? I thought that during idle operation, prior to my problem, that I had measured a 5Volt drop on both RX and TX ports.

Robert
*** RX output port not working ***

Can someone with a working RN-1 RX/TX port tell me what voltage they get from RX AND TX to GND, or if someone already knows what it should be, please advise me?

I was able to use the Rx output port with an ETX command and receive it properly on my test accessory that activates a sound effect. In the mean time I wired the RX output port for another project. During this test I burned out a computer chip on the accessory apparently due to my shorting a wire. Since then I have not been able to get the RX port to work with my original project. I get a 5volt drop on the TX port without any programs running but only get a trace of voltage on the RX port. Is this correct? I thought that during idle operation, prior to my problem, that I had measured a 5Volt drop on both RX and TX ports.

Robert
treborz
Robot Builder
Robot Builder
Posts: 9
Joined: Sun Nov 18, 2007 4:11 pm

I want to make serlcd2.5

Post by jeffchifu » Thu Mar 06, 2008 3:38 pm

Post by jeffchifu
Thu Mar 06, 2008 3:38 pm

Hi i-bot,
Sorry! I want to make SerLcd2.5 but I found source code in Spark Fun .
It seems version 2(Serlcd V2).Do you have V2.5 source code.
I already make V2 but it can't change baud rate 4800.
:cry:
thanks
jeff
Hi i-bot,
Sorry! I want to make SerLcd2.5 but I found source code in Spark Fun .
It seems version 2(Serlcd V2).Do you have V2.5 source code.
I already make V2 but it can't change baud rate 4800.
:cry:
thanks
jeff
jeffchifu
Robot Builder
Robot Builder
Posts: 20
Joined: Thu Mar 08, 2007 4:16 am

Post by i-Bot » Thu Mar 06, 2008 5:52 pm

Post by i-Bot
Thu Mar 06, 2008 5:52 pm

I don't think the source for v2.5 is published anywhere. I only have the .hex file, and a partial disassembly of it.

You could hard code the v2 to be at 4800 by changing the value set in the SPBRG register.
I don't think the source for v2.5 is published anywhere. I only have the .hex file, and a partial disassembly of it.

You could hard code the v2 to be at 4800 by changing the value set in the SPBRG register.
i-Bot
Savvy Roboteer
Savvy Roboteer
User avatar
Posts: 1142
Joined: Wed May 17, 2006 1:00 am

Hi i-bot, Can you send V2.5 .hex file to me?

Post by jeffchifu » Fri Mar 07, 2008 2:49 am

Post by jeffchifu
Fri Mar 07, 2008 2:49 am

Hi i-bot,
Can you send V2.5 .hex file to me?
thank you!
jeff :lol:
Hi i-bot,
Can you send V2.5 .hex file to me?
thank you!
jeff :lol:
jeffchifu
Robot Builder
Robot Builder
Posts: 20
Joined: Thu Mar 08, 2007 4:16 am

Post by i-Bot » Fri Mar 07, 2008 12:58 pm

Post by i-Bot
Fri Mar 07, 2008 12:58 pm

Jeff,
I sent you a PM

Richard
Jeff,
I sent you a PM

Richard
i-Bot
Savvy Roboteer
Savvy Roboteer
User avatar
Posts: 1142
Joined: Wed May 17, 2006 1:00 am

I bought SerLCD from sparkfun

Post by jeffchifu » Sat Mar 29, 2008 11:55 am

Post by jeffchifu
Sat Mar 29, 2008 11:55 am

Is it work in RN-1?
I found problem in connecting to RN-1.It cannot use cls commond and display not right in print commond.
Is it work in RN-1?
I found problem in connecting to RN-1.It cannot use cls commond and display not right in print commond.
jeffchifu
Robot Builder
Robot Builder
Posts: 20
Joined: Thu Mar 08, 2007 4:16 am

PreviousNext
62 postsPage 3 of 51, 2, 3, 4, 5
62 postsPage 3 of 51, 2, 3, 4, 5