Shop OBEX P1 Docs P2 Docs Learn Events
Reading a 7 segment display. — Parallax Forums

Reading a 7 segment display.

HannaleeHannalee Posts: 3
edited 2009-07-03 21:16 in Accessories
Hello, I hope this is the right fourm.
I have 18 7 segment displays which I have to scan and then send the value of each display out as rs-232.

I know I could open each box and read the signal that is sent to the display, but I am not allowed to alter any of the hardware.

Short of using 126 ( 7 x 18 ) photo sensors anyone have any ideas? I though about maybe using a vision based system and then doing
some OCR, but I would like to do everything with STAMPS.

TIA

Maitin

Comments

  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2009-06-30 19:58
    Some questions:

    1. Do the displays themselves have to be visible after the modification, or does the RS232 connection substitute for that?

    2. If the displays have to remain visible, how close to the displays can the sensor be?

    3. Are these 18 individually-housed single-digit displays? How close together are they?

    4. How often do the values change?

    5. How often do you have to transmit updated values?

    6. Are the digits straight up and down or italicised? ('Weird question, I know, but I have a reason to ask.)

    The non-opening-the-box requirement is rather inane, IMO, but some customers/bosses are irrational or needlessly fearful, so I guess you just have to live with it.

    -Phil

    You've posted the same question in the BASIC Stamp forum. Cross-posting is not allowed. Please delete your other post (using the X in the upper right corner), before someone answers it.

    Post Edited (Phil Pilgrim (PhiPi)) : 6/30/2009 8:07:24 PM GMT
  • Loki008Loki008 Posts: 19
    edited 2009-06-30 20:37
    i have no idea what sort of LED displays you are dealing with, but i would see if there would be any way to measure the voltage off of the LED segments, I then would do something like assign each segment into arrays, where you have say 3 groups of probe pins distributed so that each segment would have a different "code" when it lights up.

    I know my description is lacking, ill try to simplfy it

    you have Pins 1,2,3,4,5,6
    you have displays 1 and 2 both with 4 segments so a total of 8 LEDs

    Pin 1 connects to every LED pin in Display 1, Pin 2 connects to every LED pin in Display 2

    Pin 3 connects to pin 1 on LED 1 in display 1 and display 2
    pin 4 connects to pin 2 on LED 1 in display 1 and display 2
    Pin 5 connects to pin 3 on LED 1 in display 1 and display 2
    Pin 6 connects to pin 4 on LED 1 in display 1 and display 2

    This way when ever a LED segment lights up, you will mesure voltage on 2 pins, for example pin 1 and 4 would tell me it is Display 1 segment 2


    This approach will get you down from 126 sensors down to 25. I would think you could probably cut this down further by using some sort of array approach to make a 3 or 4 pin combo with some thinking about the problem.
  • kwinnkwinn Posts: 8,697
    edited 2009-06-30 22:57
    Without tapping in to the signals driving the led displays I don't see any alternative to using some type of photo sensor. The simplest to decode would be a single sensor for each segment, but at the cost of hardware complexity. The simplest hardware would be an imaging chip viewing all 18 digits, but of course the software would be somewhat complex. Something similar has been done with CCD chips in optical spectrometers.
  • HannaleeHannalee Posts: 3
    edited 2009-07-01 21:20
    kwinn, yea that is sort of where I am. There are 3 seven segment leds on each box that I have to monitor. My plan is to use a ladder network and encode the displayed value of each seven segment as a resistance and read it on a a/d . As I envision it, there will be a stamp for each box. These 6 stamps will connect to a seventh stamp connected to a PINK and I can then monitor the boxes from anywhere.
  • kwinnkwinn Posts: 8,697
    edited 2009-07-02 14:49
    That will be pretty tricky to do reliably. Do you have a schematic for this approach? I had thought you would have an opto transistor for each segment of each display, read the resulting 7 bits in one digit at a time, and look up the number for each bit pattern.

    PS - These boxes, are they external to the main chassis, and if so do they have a ribbon or other cable going to them? Is there a connector on either end of the cable?

    Posting a picture of the box, it's cabling if any, and a schematic of what you plan would be helpful. Lots of ingenious folks on this forum.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2009-07-02 15:30
    Yeah, I'm a little confused now, too. Initially, it sounded like no electrical connection was possible. But the resistor network idea nearly demands such a connection. So which is it?

    -Phil
  • kwinnkwinn Posts: 8,697
    edited 2009-07-02 17:21
    BTW Hannalee you only need 6 of the 7 segments to decode the number on each digit if it uses a typical bcd to 7 segment decoding scheme. Segment C is only off for displaying a 2 and the other 6 segments produce a unique bit pattern for each number. Not a huge saving but every little bit helps.
  • HannaleeHannalee Posts: 3
    edited 2009-07-02 19:58
    Thank kwin, I actually had NOT thought of that. But it saves 18 photoresistors.


    Anyway to clarify, I have no electrical connection to the 6 boxes. Whatever solution I devise will have to be optical.

    The BS2p40 Seems like a good fit as it has plenty of i/o, enough to support one box ( 3 seven segment led ). This is even easier as I do not have to multiplex the 6-7 photoresitors . I could actually have the STAMP monitor 5 seven segment LEDs, but since they are in different racks I t might just be easier to have one stamp per box

    These 6 BS2p-40 will then output a string every so often ( 100 msec?) and a seventh stamp will poll 6 input pins it and then write it out to the web via PINK.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2009-07-02 20:37
    Duplicate thread in BASIC Stamps forum removed.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Engineering
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2009-07-02 22:00
    hannalee,

    Did you have time to consider the questions I posed above? It would help if you could answer them...

    -Phil
  • kwinnkwinn Posts: 8,697
    edited 2009-07-03 21:16
    Hannalee, if the photo resistors have a reasonably large change in value between a lit and unlit segment I do not see the need for an adc. You should be able to use the photo resistors in a voltage divider circuit to read a 0 or 1 directly. If not you may want to consider using a photo transistor instead.
Sign In or Register to comment.