Experimenting With Velostat


#1

I’m making a dance floor for my kids and thought that it would be fun to add some pressure sensors in the floor to flash some lights, etc… So I did some research and found that using velostat hooked up to an analog pin might work for it. I was trying to figure out the best way to do it, but I’m having trouble figuring out how to get accurate measurements of the resistance. The numbers seem to jump around quite a bit and never seem to settle, I’m confused by what I’m seeing.

Anyone have insight into what I’m seeing? or any suggestions how how to better measure it? or anything I can add to the circuit to make things clearer?

I’ve uploaded a video showing what’s happening. I would appreciate any help or suggestions anyone has.


#2

I would expect it to be somewhat noisy and that you would have to do some software smoothing of sensor values if you wanted to improve the accuracy of the pressure measurement. But perhaps you don’t need that much accuracy. I know that Adafruit has some tutorials on using soft circuits as sensors. Like this one https://learn.adafruit.com/firewalker-led-sneakers/test-circuit.

In their example they use velostat as a trigger on an analog pin. That pin is set up as part of a voltage divider created between an internal pull-up on A9 ( pinMode(9, INPUT_PULLUP); ) and the potentiometer created with the conductive thread and the velostat. analogRead will take the voltage read at pin 9 (it will be between 0v and Vcc) and map that between 0 and 255.

Does that help?


#3

But perhaps you question is more along the lines of how do I ignore the small fluctuations in values and concentrate on the larger changes?


#4

It’s not really the accuracy of the pressure that I’m concerned about, it’s why the value keeps changing over time while it’s just sitting there. I don’t know if it’s because of how I’m testing it, what I’m using to test it or some sort of build up of charge, static electricity, capacitance? Now that you explain it as a voltage divider on the analog pins, I’m thinking that reproducing that in my test circuit might help, which means it’s like a floating pin on a micro?


#5

Well, air pressure is not constant. Could that be the cause? And I don’t think that it will ever “settle”. Here is a video from a manufacturer of Linqstat. https://youtu.be/bX_oo1hr1ag Note that the multimeter does not settle in any of their measurements.

Also, on a side note, you can use velostat to protect yourself from alien mind control. http://www.stopabductions.com/

edited to add the linqstat link.


#6

Aha, at 5:20 he says “… because of the particle distribution of the carbon in the conductive film it’s difficult …”, so I guess that’s something to hang my hat on. I’d still like to understand how I could try to smooth things out in an analog way before getting a value in software. Thanks for that link, it was helpful at least to see that I wasn’t seeing something out of the ordinary.

If the velostat isn’t going to work for the dance floor at least I’ll have another use for it!


#7

There is a short introduction to smoothing on the arduino forum https://www.arduino.cc/en/tutorial/smoothing. But that is a big topic and the tutorial shows a simple implementation of a “boxcar” filter. Basically a running average (past readings all have same weight on the average). It does smooth well, but has latency. There are many other smoothing algorithms and all of them can be broadly categorized as low pass filters. http://playground.arduino.cc/main/smooth is another example and uses what is called exponential smoothing (influence of past readings have exponentially less influence as time goes on).

But you might not need any of that. If it is just a switch you are creating set up the voltage divider so that in the unloaded state is far enough away from the loaded state and you don’t have to worry.