P2 Accessory Set - Control Board issue
JRoark
Posts: 1,215
in Propeller 2
I think I found an issue using the Control Board from the P2X8C4M64P-ES Accessory Set on a Rev B P2 Eval Board. This little 4-button-widget doesn't pull its switched outputs to the supply rails:
- When a button is pressed, it firmly pulls the associated P2 pin to the 3.3V rail (good!)
- When a button is **released**, the input pin simply floats. (bad)
You can sometimes watch an unterminated output from this board wander. Sometimes if you keep reading an input for a few minutes and you'll see the boards output wander between a 0 and a 1. Bring your hand near it and it will sometimes change states. Touch it with a floating test lead and it makes a decent random number generator. This seems to violate the old mantra that "all pins MUST go somewhere (pick a rail) to prevent undefined operation".
Here is the FlexBASIC code I'm using to demo the oddity:
I'm going to mod my Control Board to include 10k pull-down resistors on each of the boards outputs, but certainly Parallax tested this. What am I missing?
- When a button is pressed, it firmly pulls the associated P2 pin to the 3.3V rail (good!)
- When a button is **released**, the input pin simply floats. (bad)
You can sometimes watch an unterminated output from this board wander. Sometimes if you keep reading an input for a few minutes and you'll see the boards output wander between a 0 and a 1. Bring your hand near it and it will sometimes change states. Touch it with a floating test lead and it makes a decent random number generator. This seems to violate the old mantra that "all pins MUST go somewhere (pick a rail) to prevent undefined operation".
Here is the FlexBASIC code I'm using to demo the oddity:
direction(39,32) = input do print input(39,32) ' 64006-ES(a) Control board is attached on pins 32-39 pauseMS(500) loop
I'm going to mod my Control Board to include 10k pull-down resistors on each of the boards outputs, but certainly Parallax tested this. What am I missing?
Comments
Try this:
The order of the LEDs is different than the PB's.
I mod'ed the board, but I did it in a way that lets me unmod it easily. I'm trying to use these Control Boards as part of an exercise for my Minions... and they're using BASIC with no idea how to in-line asm. So I'll make a BASIC function wrapper for your code and make it part of a library they can call. Easy-peasy.
Thanks, Chip!!