Too right.
So, what's the "fluid"?
How much?
How critical?
Is "contamination" a concern?
I've thought that the "beam" from a cheap laser pen could be reflected off the surface of a fluid to a sensor.
So, I just got out my cheap laser pen module and filled a basin with water and can confirm that it works - the laser gets reflected off the surface of the water.
I ran across the SR04 modules this morning for $1.64 each... well $16.44 for 10. I don't have an urgent need for the critters, but I think I'll order some anyhow.
So who has figured out how to use these with a Stamp or Prop since there are 4 pins? I ordered some of them last year but still have not done anything with them yet.
Aren't you the guy with a bazillion 4-wire CD cables? Stock, it works like a PING except you use 2 seperate wires (trig and echo) instead of the PING's one wire. Ergo, a 4-wire connector could be used. Otherwise, add one resistor as detailed in this thread and use it with 3 wires.
So who has figured out how to use these with a Stamp or Prop since there are 4 pins? I ordered some of them last year but still have not done anything with them yet.
Some kind chap has posted code to use these with the Propeller in post #32.
I forget, did you get it working in one pin mode with the Prop?
No, I didn't. I didn't spend much time trying to get a one pin version to work so it may be possible. I did get four sensors working using five pins by sharing the echo line (I don't recall if it required a few extra passives, I'll try to find the thread (I think Martin started the thread) and post a link here)..
To all interested, I succeeded in getting the HY-SRF05 modules working with 1 pin only with the propeller. Here I leave the schematic and quick and dirty code.
It might get better after I plug the scope (another day), but it's working reliably so far.
To all interested, I succeeded in getting the HY-SRF05 modules working with 1 pin only with the propeller. Here I leave the schematic and quick and dirty code.
I have a cartload of the cheapos. I'm not sorry I bought them, but they do present serious issues with repeatability, reliability and range.
As a cheap intro to the technology and for making small bots... absolutely fine.
For anything that would injure a small child, absolutely not:)
Let's not forget that the cheapo sensors are missing the Ping)))'s most important feature. The LED that blinks when it is actively sensing! Besides being fun the LED has spared me time debugging when I simply had the Ping))) connected to the wrong pin.
Let's not forget that the cheapo sensors are missing the Ping)))'s most important feature. The LED that blinks when it is actively sensing! Besides being fun the LED has spared me time debugging when I simply had the Ping))) connected to the wrong pin.
You know as silly as it is, yes that is an issue sometimes. Visual verification that something is actually happening is nice and I end up often using MC pins to replicate that. They definitely are not as rock-solid on the measurements as the Ping))) is. The lack of timeout on the echo line is also something to watch out for if you don't account for it in your code.
Which begs the question: can you add a 1-cent LED to the cheapie sensor for feedback? Echo line, maybe? Low current, prolly?
Duane? Martin_H? Rick? Mike? Who will answer the call before I do? I have a birthday weekend to tend to.
Good question.... I never did because I had no idea how much current it could safely source from that pin but most of those are using some kind of MC under the hood and they usually have fairly generous specs. Would save me some pins and code complexity not to have to do it from the Propeller. I may look at that next week.
Comments
So, what's the "fluid"?
How much?
How critical?
Is "contamination" a concern?
I've thought that the "beam" from a cheap laser pen could be reflected off the surface of a fluid to a sensor.
So, I just got out my cheap laser pen module and filled a basin with water and can confirm that it works - the laser gets reflected off the surface of the water.
:zombie: --"Oh well."
This drawing shows a number of detectors where levels of concern could be noted, but all that's necessary is triggering the alarm level.
We need an grimace emoticon
I guess the need wasn't so vital after all.
@
Please share your link, Amanda, that others may share in our gluttony.
A thousand pardons Sahib. That was before my morning coffee. >=:-]
http://www.ebay.com/itm/10-x-Ultrasonic-Module-HC-SR04-Distance-Measuring-Transducer-Sensor-for-Arduino-/130705106799?pt=LH_DefaultDomain_0&hash=item1e6ea1a76f
@
Yet another tacit nod to the '67 Corvair's 164 CID!
http://forums.parallax.com/showthread.php/147666-Cheaper-Robotic-Car?p=1181388&highlight=corvair#post1181388
http://www.ebay.com/itm/10-x-Ultrasonic-Module-HC-SR04-Distance-Measuring-Transducer-Sensor-for-Arduino-/130705106799?pt=LH_DefaultDomain_0&hash=item1e6ea1a76f
@
Makes this seller's $8.70 five-pack ($1.74 each, and that's his SALE price) seem downright silly:
http://www.ebay.com/itm/5pcs-Ultrasonic-Module-HC-SR04-Distance-Measuring-Transducer-Sensor-for-Arduino/121117287177?rt=nc&_trksid=p2047675.m1851&_trkparms=aid%3D222002%26algo%3DSIC.FIT%26ao%3D1%26asc%3D163%26meid%3D177443938741227470%26pid%3D100005%26prg%3D1088%26rk%3D1%26rkt%3D4%26sd%3D370852298103%26
Some kind chap has posted code to use these with the Propeller in post #32.
No, I didn't. I didn't spend much time trying to get a one pin version to work so it may be possible. I did get four sensors working using five pins by sharing the echo line (I don't recall if it required a few extra passives, I'll try to find the thread (I think Martin started the thread) and post a link here)..
It might get better after I plug the scope (another day), but it's working reliably so far.
Here the testing code
Demo PING v1.0 - Archive [Date 2013.08.07 Time 23.44].zip
Enjoy
Alex
Fantastic!
Thanks for sharing your work.
This will come in very handy.
I have a cartload of the cheapos. I'm not sorry I bought them, but they do present serious issues with repeatability, reliability and range.
As a cheap intro to the technology and for making small bots... absolutely fine.
For anything that would injure a small child, absolutely not:)
Rich
Or $1.35 each in a ten-pack: http://www.ebay.com/itm/10PCS-Ultrasonic-Sensor-Module-HC-SR04-Distance-Measuring-Sensor-for-arduino-/170897438131?pt=LH_DefaultDomain_0&hash=item27ca47f5b3
The sensor costs less than the mounting bracket! http://www.ebay.com/itm/1PC-Ultrasonic-Sensor-Fixed-Bracket-For-HC-SR04-Ultrasonic-Module-New-/130977996823?pt=LH_DefaultDomain_0&var=&hash=item1e7ee5a017
Let's not forget that the cheapo sensors are missing the Ping)))'s most important feature. The LED that blinks when it is actively sensing! Besides being fun the LED has spared me time debugging when I simply had the Ping))) connected to the wrong pin.
You know as silly as it is, yes that is an issue sometimes. Visual verification that something is actually happening is nice and I end up often using MC pins to replicate that. They definitely are not as rock-solid on the measurements as the Ping))) is. The lack of timeout on the echo line is also something to watch out for if you don't account for it in your code.
Duane? Martin_H? Rick? Mike? Who will answer the call before I do? I have a birthday weekend to tend to.
Good question.... I never did because I had no idea how much current it could safely source from that pin but most of those are using some kind of MC under the hood and they usually have fairly generous specs. Would save me some pins and code complexity not to have to do it from the Propeller. I may look at that next week.
The good news is that the cost to find out is only $1.48!
http://www.ebay.com/itm/10PCS-Ultrasonic-Sensor-Module-HC-SR04-Distance-Measuring-Sensor-for-arduino-/170897438131?pt=LH_DefaultDomain_0&hash=item27ca47f5b3
@
What family doesn't need a couple 10 packs??
These are cheap enough that you could line a wall and make an ultrasonic sensor organ.....
...no, I mean like a sound organ!
Cheaper than a diet coke now. The buggers here just raised the soda machine price from $1.35 to $1.50!
Edit: But the cheesy plastic brackets are still $1.45! http://www.ebay.com/itm/141032348675