Author Topic: Industrial LCD RS232 connection  (Read 6488 times)

0 Members and 1 Guest are viewing this topic.

Offline StonentTopic starter

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Industrial LCD RS232 connection
« on: May 25, 2014, 10:05:10 pm »
I picked up a 2x16 panel mount LCD from Tanner Electronics that was marked as "UNKNOWN LCD". It is about twice as wide as a standard 2x16 LCD.

It has 8 screw terminals on it, so my first thought was some kind of industrial LCD.
The screw terminals are marked +,-,-,RX,-,TX,+,-
There is a Sipex SP232ECT chip next to the terminals so I had a pretty good feeling this used RS-232

One sticker says "58688-400 05B and 0402 on the bottom"  Googling that gets me to a site that sells PLC related hardware and indicates this LCD was made by Rapistan/Dematic. They were out of stock and last sold for about $44 (I paid $6 so I did well)

There is a bar code on the top that says "1FSM6377304/16/02"
Since both stickers have an 04 and 02 and all chips are late 2001, early 2002, I'm assuming that is an April 16, 2002 Mfg date.

Searching on the 1FSM63773 gets me to a German site that is selling these for about 7 Euro.
http://www.pollin.de/shop/dt/NTc2OTc4OTk-/Bauelemente_Bauteile/Aktive_Bauelemente/Displays/LC_Display_RAPISTAN_1FSM563773.html

And also a thread on another forum in German
http://www.mikrocontroller.net/topic/148447
It looks like he got it working somehow at 19200, but then it appears they were talking about removing the 8051 and using an AVR, but since the google translation missed a few things, I can't tell.
All the + and all the - connections are tied together and feed into a 7805 regulator.

When I connect a 9V battery, the top row goes black for a half second or so and then a "_" in the first position. Each character has a 1x5 cursor row underneath. The characters appear to all be 5x8.

I wasn't sure if the RX and TX labels were indicating what to connect them to, or what they were, so when I wire them to my laptop's serial port RX to RX and TX to TX, no matter what baud rate I choose, I get what I type echoed back to my terminal.

If I connect RX to TX and TX to RX, I get nothing at any baud rate.

Nothing I type on the various baud rates and connections changes the LCD, it just stays there with a "_" at the first position.

Additional parts are:
OKI M5839C 40 dot LCD driver
Hitachi HD44780
Philips P87C51 SBBB OTP 8051 (PQFP-44)
8 way DIP switch

I've spent a few hours tracing pins and here's what I have:

The top half of the DIP switches are all tied to ground.
The bottom pins 1 through 8 are tied to pins 18 through 25 on the MCU.

1 - 18 P2.0/A8
2 - 19 P2.1/A9
3 - 20 P2.2/A10
4 - 21 P2.3/A11
5 - 22 P2.4/A12
6 - 23 P2.5/A13
7 - 24 P2.6/A14
8 - 25 P2.7/A15

There are 10K pull ups on MCU pins 18 through 25 going to +5V.  Flipping the corresponding dip switch pulls them to GND.

V1 through V5 on the Hitachi chip tap off of a string of 1 or 2 ohm resistors wired in series with the starting end going to ground.
When I flip the dip switches (while everything off), the resistance to ground increases on each V1 through V5 pin. So I suspect in that case, since those DIP switches are grounded on one side and 10k pullups on the other that the DIP switches may in part be some kind of contrast adjustment via some sort of resistor divider network, however changing them does not appear to change the contrast that I can see.

V1 through V5 are listed as "Power Supply for LCD Drive VCC –V5 = 11 V (max)"  I'm not sure what the MCU pins have to do with it though.

So I'm not really sure if I'll be able to get it to work now or not since I think I'm talking to the MCU over RS232 and it may be waiting for some kind of information over serial before it works.
« Last Edit: May 25, 2014, 10:11:59 pm by Stonent »
The larger the government, the smaller the citizen.
 

Offline Paul Price

  • Super Contributor
  • ***
  • Posts: 1433
Re: Industrial LCD RS232 connection
« Reply #1 on: May 25, 2014, 10:49:53 pm »
You may have paid $6 too much for this display.  However if Pollin has shown in its advert that they can display with it, contact them to get info on the display. This is the best way to get this thing to work, get the data they have about it from them, ask them how they got this display to display or else all is lost  The Pollin download only has datasheets for three IC's and nada for the MCU interface. Think Translate.Google.com

It doesn't cost that much to get a 16x2 working display new from Farnell or some other electronics part house, so how many gray hears will you grow before you get this thing to work? I usually encourage people to hack and learn something in the process, but there is even a limit to my encouragement.

Your only other option might be to divest the display of the 87C51 and directly send commands and data to the LCD driver chip pins of the Hitachi HD44780. That will work but a lot of trouble for 16x2 lines.

There are so many possible possibilities here to get the display MCU to recognize any command, too many for you in your short lifetime to guess. It could be that 5 or 7 positions of the dip-switch set the address of the display, maybe the other three set baudrate or ????

But  then what does that help if you don't know the format of the expected serial bit stream to the MCU or the command syntax or order of commands and data etc.
« Last Edit: May 25, 2014, 11:19:08 pm by Paul Price »
 

Offline StonentTopic starter

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Re: Industrial LCD RS232 connection
« Reply #2 on: May 25, 2014, 11:10:38 pm »
You may have paid $6 too much for this display.  However if Pollin has shown in its advert that they can display with it, contact them to get info on the display. This is the best way to get this thing to work, get the data they have about it from them.

Download verfügbar. means Download Available!

Your only other option might be to divest the display of the 87C51 and directly send commands and data to the LCD driver chip pins of the Hitachi HD44780. That will work.

There are so many possible possibilities here to get the display MCU to recognize any command, too many for you in your short lifetime to guess. It could be that 5 or 7 positions of the dip-switch set the address of the display, maybe the other three set baudrate or ????

But  then what does that help if you don't know the format of the expected serial bit stream to the MCU or the command syntax or order of commands and data etc.

The zip file on their site has a datasheet for the LCD controller chips and the RS232 chip, no other information unfortunately.

Apparently this was made with both Hitachi and JRC LCD chips, but they appear to be pin compatible with each other.
The larger the government, the smaller the citizen.
 

Offline mariush

  • Super Contributor
  • ***
  • Posts: 5141
  • Country: ro
  • .
Re: Industrial LCD RS232 connection
« Reply #3 on: May 25, 2014, 11:16:01 pm »
It's really not worth your time, unless you really want to do some reverse engineering. You can get LCD displays for 2-3$ on eBay, or from Digikey for under 10$ each.

Sipex sp232e is a line driver, it converts that serial data at normal higher voltages to the 0-5v TTL signals for microcontrollers.  Here's the datasheet: http://www.farnell.com/datasheets/70951.pdf

Specs say it can tolerate +/-15v from outside, it sends +/-6v to outside, it works with 0 (digital 0) or at least 3.5v (digital 1) with microcontroller attached to it.

So this chip simply converts this rs232 from the connector to something the microcontroller can tolerate.

Next you have there on the board that OKI M5839C .. that's a 40 segment led driver: http://savedonthe.net/download/554/IC-ON-LINE.CN_msm5839c_308497.html

If you check the datasheet, this chip is basically 2 shift registers, each 20 bit. So you have one input pin + clock pin for the first 20bit shift register, one input pin + one clock pin for 2nd 20bit shift register and a pin that when it goes high, makes the shift registers latch and the 40 bits are sent to the driver.  So if you want, you can solder 5 wires to those pins (there are probably traces on the pcb going to the MCU) to your own microcontroller and you're done.
I'm not sure  why it's used, maybe they have more pixels than the hd44780 can drive directly? No clue.
As for hd44780 you can easily find datasheet online, you could tap into those pins and do what the microcontroller does. 

But it would take so much time it's just easier to buy another module.
 

Offline StonentTopic starter

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Re: Industrial LCD RS232 connection
« Reply #4 on: May 25, 2014, 11:32:02 pm »
Well another thing is when I bought it, I thought it was 2x24 or 2x32, but after powering it on it was just a really big 2x16 display.
The larger the government, the smaller the citizen.
 

Offline Paul Price

  • Super Contributor
  • ***
  • Posts: 1433
Re: Industrial LCD RS232 connection
« Reply #5 on: May 25, 2014, 11:33:42 pm »
LUMEX - LCM-S01602DSR/D - DISPLAY, DOT MATRIX, LCD, 16 X 2

about $35 US from Farnell.com, but many more much different variations of this theme and  cheaper on ebay.
 

Offline AlfBaz

  • Super Contributor
  • ***
  • Posts: 2187
  • Country: au
Re: Industrial LCD RS232 connection
« Reply #6 on: May 25, 2014, 11:41:57 pm »
If you are getting PLC hits with your searches, it's most likely using one of the many automation protocols getting around.

Around these parts alan bradely PLC's seem to be the norm. They use DF1 which is just a straight connection from one device to another. The specs for this are freely available. They have a multi-drop protocol, which I believe uses the same commands outlines in the DF1 spec but the phy is proprietary.

Another likely candidate is Modbus or one of its variants.

Seeing you got hits from Germany it could also be profibus, which if memory serves is the preferred protocol for seimens S5/S7 plcs
 

Offline StonentTopic starter

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Re: Industrial LCD RS232 connection
« Reply #7 on: May 26, 2014, 12:17:15 am »
If you are getting PLC hits with your searches, it's most likely using one of the many automation protocols getting around.

Around these parts alan bradely PLC's seem to be the norm. They use DF1 which is just a straight connection from one device to another. The specs for this are freely available. They have a multi-drop protocol, which I believe uses the same commands outlines in the DF1 spec but the phy is proprietary.

Another likely candidate is Modbus or one of its variants.

Seeing you got hits from Germany it could also be profibus, which if memory serves is the preferred protocol for seimens S5/S7 plcs

That's some good information, thanks!  Rapistan (now Dematic) is a US company in Michigan that makes conveyors and other warehouse and inventory related hardware and I remember hearing the name Seimens-Dematic before.
The larger the government, the smaller the citizen.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf