Ahh… I almost understand this, now.
I’ve been looking at phidget’s .2" FSR’s and I think that they’re the way to go.
I’ve never used a pot before, though, so I don’t know what kind to get.
Can you show me a link of one that would work well for this application?
And, could you explain how to use one?
Thanks.
a pot is a variable resistor you can find them anywhere ie the shack, i think you could start with a 100k ohm. what you are trying to do is get the max voltage range coming out of the sensor when you have no load and then full load(which is specific to your robot). once you find that setting by playing with the pot you take an ohm reading off of that and install a similar resistor
my method does not require pots or resistors. sensors were placed as follows on the foot:
W- was on the front left corner of the foot
X- was on the front right
Y- was on the back left
Z- was on the back right
each sensor has two leads, i connected one of sensor W leads to ground then the other lead to one of sensor Z the other lead of Z was to 5v. i then used an Analog to Digital Converter (ADC) to find the voltage of the wire between W and Z. this gives me my first input, i did the same with X and Y to get my second input. with a little math you can find the CG but my program tried to make the values from each input the same which meant that the CG was along the fore and aft axis of the foot. one both values are 2.5 the CG is centered. if you need a better explanation just let me know.
nick
Damn, I swear that I almost understood that!
I have a few general questions left, concerning the actual function of the pressure sensor:
From what I’ve read, it seems to me that the pressure sensor is a resistor that varies according to pressure. The more the pressure, the less voltage comes through the sensor. Kind of like kinking a water hose.
Did I get that right?
So, if I hook two diagonal sensors up in a series, as you have done, they really end up functioning as a single sensor, don’t they?
You said that the program that you wrote compensates to get the fore and aft sensors at 2.5 (volts?).
That goes against what I just said, though, doesn’t it?
I mean, if the program can tell the difference between the front and back sensors, then they can’t be functioning as one.
I’m confused.
How does your microcontroller know the difference between them if they are in series?
Oh, by the way, you mentioned that you didn’t use the SSC-32.
Did you use phidget’s 8/8/8?
Think of how you would read a single sensor. You’d connect one side of it either to 5V or gnd and the other side to a fixed resistor from which you’d be creating a voltage divider. You can read the voltage with an ADC.
He’s using fore and aft as the both sides of a voltage divider. When one has 2x the resistance of the other, the voltage read in the middle will be either 1/3 or 2/3’s of 5volts based on which is higher. So the micro can tell the ratio between fore and aft, but not the absolute values. So it could tell the balance, but not whether or not it was carrying a gorilla piggy back.
Ahhhhhh!
Now it makes sense.
Thanks, guys!
(^.^)
Hold on a sec… I just had a mental fart.
The independant fixed resistor…
what is its purpose?
Does it compensate for the normal pressure applied to the FSR’s from the biped’s resting weight?
NICK_A,
Can you provide a schematic of what you are describing?
Ok Nick take a look at doctronics.co.uk/voltage.htm
What Nick_A is doing gets rid of any fixed resistors or pots. He’s using the sensors as both sides of the voltage dividers depicted at this site.
Ahhhh!
Eureika!
Thanks for the link, Andy; I’ve spent the afternoon reading that page and the whole website, as well.
As you may have guessed, I needed that.
From your description, NickA, I’ve drawn this:
x11.putfile.com/12/35217095179-thumb.jpg
To what did you connect the two inputs that I have marked with a question mark?
And my last (well, that’s probably a lie) question goes to anyone familiar with the SSC-32…
Where would I plug in the inputs from “W” and “X” on the SSC-32?
Directly into the ABCD inputs, or would I need some sort of interface before that?
Thanks, everyone for all the help and patience.
Allow me to appologise now for any and all past, present, and future inexperience/stupidity on my part.
Not quite there yet Nick
Take a look at vizlog.com/robot/nickscircuit.gif
V1 and V2 are the analog voltages that you need to read with a couple of analog pins.
Damn!
No cigar, eh?
Sorry, Andy, but that wasn’t dumb enough for me to understand it.
Which ones are the analog pins?
The ABCD inputs?
And, does the polarity matter?
You’re creating resistor dividers with pairs of sensors. If you connect a wire in between one of the pairs, you get some voltage between 0 and 5V. The particular voltage you’ll get is dependant upon the ration of the resistances on either side. This voltage is what you are after. You’ll need a micro that has analog inputs to read this voltage (analog meaning a continuous value, a voltage like 2.5 or 1.6, not on or off). When I said analog pins I intended that you would use whatever pins on your micro lets you read analog values.
Polarity, in terms of which side of which sensors is high and which is low matters only in how you interpret the signal in the middle. If the relative resistances yield 2V one way, they’ll yield 4V the other way. So if that’s what you meant, not really, just as a matter of programming to make sense of the data.
ABCD inputs? Is this an ATOM thing? I’m not familiar with it, but a quick survey of the Atom chips seems to indicate that they all have at least 3 A/D (Analog) inputs.
the ssc-32 does not have analog ,those four that you are talking about are digital as are most pins on typical micros. i had to use an ADC (analog to digital converter) to return the four inputs. if there is a micro with four A/D inputs i am unaware of it.
this goes back to using a micro for sensor data retrival, i just cant see a bot being able to get away with only the ssc-32 for wireless control (at least not one equiped with more then four switches)
also thanks andy for clarifying
nick
Nick_A,
Where in Hoston are you? I live in Tomball @ 249 & Spring Cypress.
For all I know, you could be my next door neibor.
pearland, way south
but i think a duel will be in order once we finish our bots, your going down
nick
I see you’re point, now Nick.
By the way, which ADC did you use?
I tried froogling “analog to digital converter”, but all I’m getting are a bunch of large and clunky audio and video ADC’s.
google “a/d converter”
i dont remember what i used but what im using this time will be a 12 bit, i2c capable, 4 channel from analog devices. part AD7994
if you sign up you can usually get a sample or two free
nick
Thanks, Nick!
(^.^)
(I feel like I’m talking to myself, lol)
No Nick, the SSC-32 Does have 4 analog inputs. A, B, C, D are either Analog, Digital, or Latching Digital inputs. Depending on which command you use to read the pins.
really had no idea
i guess i should start reading
ok nick you can use the ssc-32 which has and 8 bit a/d. this should be more then enough to get a balancing biped though you have now taken all of your inputs. i suppose you could use some of the pins using discret output to multiplex your inputs.
i think personally will still use the 12 bit with a micro so mid dynamic stride when i lose com (and i will lose com per murphy’s law) i can still run a recovery subroutine
sorry for my mistake
nick