My version specifically tested with the Flexiforce. It is essentially the same as Jon's in function but uses the RCTime liberry.
OBJ
pst : "FullDuplexSerial"
rc : "RCTime"
CON
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
PUB Go | Sense
pst.start(31, 30, 0, 115200)
repeat
rc.rctime(0, 1, @Sense) ' Flexiforce to pin 0, read rc
pst.Str(String("Value: "))
pst.dec(Sense / 100) ' Display rc time decay in Sense var
pst.tx(13)
waitcnt(clkfreq / 2 + cnt) ' 1/2 second delay
Do you have a Propeller board with an ADC input? If so, you can use the Flexiforce as you would any variable resistor for ADC. For PropC, you could use any of the examples Andy has done that use the ADC inputs of the PAB or PropBOE. Go through the Learn examples -- the latest are on learn.parallax.com.
Comments
Do you have a Propeller board with an ADC input? If so, you can use the Flexiforce as you would any variable resistor for ADC. For PropC, you could use any of the examples Andy has done that use the ADC inputs of the PAB or PropBOE. Go through the Learn examples -- the latest are on learn.parallax.com.