auto-configuring attached hardware...
bcw1011
Posts: 8
I plan on building controller that, when powered up will do a 5-4-3-2-1 count on a large 7 segment display.· this is going to be used as a start light for a rc car race.· but in the long run the display will have several types to mimmic different styles of racing.· I'm using a basic stamp as the brains.· the display is to be housed in a seperate remote enclosure, using a 9 pin cable to connect it to a controller.· so to keep operator ease at mind i want to have the display "auto configure" using a minimum of components.· I also want the stamp to be able to tell if the display has power or not.·in addition this needs to be fairly reliable too
my thoughts were to use 2 pins as inputs one would read resistance (with a certain value resistor assigned to each display) and using a LOOKDOWN commmand would be albe to tell what type of display it was.· and a second pin as digital "fault"· ex.· high indicates ok, low lindicates a problem.··
this sound like a good plan, or is there a better way to go about this?
my thoughts were to use 2 pins as inputs one would read resistance (with a certain value resistor assigned to each display) and using a LOOKDOWN commmand would be albe to tell what type of display it was.· and a second pin as digital "fault"· ex.· high indicates ok, low lindicates a problem.··
this sound like a good plan, or is there a better way to go about this?
Comments
Button1 = 5 count
Button2 = 10 count
Button3 = Timeclock
etc...
For the button pushers, you could print up & laminate a quick reference card.
000 = NO POWER
001 = 5 count
010 = 10 count
011 = TimeClock
etc...
That might be easier than using resistance which could vary.
If you've got all zeros on the three "display mode/status" pins, then you know you've got no power in the display.
The pin scenario presumes you've actually got *different* displays -- it's unclear from your post if you are talking about different displays that, by the very act of plugging them into your controller, configure themselves and report power status.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
When the going gets weird, the weird turn pro. -- HST
By using a hex rotary switch (see attached) you can get 16 unique codes from·4·data lines·connected to your various displays. In addition, there will be no response if nothing is connected.
Regards,
Bruce Bates
I originally liked the idea of using resistance to detect the display but it looks like there are some better methods out.
thanks for the advice!
Another option, since you only have a few displays, would be to build a seperate controller for each display. If you use something like an SX protoboard, it wouldn't be too expensive. The SX boards are $10, and you could get a programmer (without debug) for $30, or (with debug) $50. You could build the controller standalone, or interface it with the BS2, and use the BS2 for choosing the display.
Post Edited (bubblehead) : 11/14/2006 4:42:58 PM GMT