Author Topic: How do you make an SRF05 act as a Ping)))?  (Read 1989 times)

0 Members and 1 Guest are viewing this topic.

Offline MaltiKTopic starter

  • Robot Overlord
  • ****
  • Posts: 300
  • Helpful? 2
How do you make an SRF05 act as a Ping)))?
« on: December 07, 2008, 08:10:46 PM »
I know it is possible, in fact I remember someone saying if you ground the "no connection"/ "mode" pin they will act the same way. I dont know if that is true, can someone confirm this?
I want the SRF05 to be 3-pinned, can I make one pin be I+O?
Would I have to change code than if it were PING-Based?
Warranty

Offline Ro-Bot-X

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,431
  • Helpful? 25
  • Store: RoBotXDesigns.ca
Re: How do you make an SRF05 act as a Ping)))?
« Reply #1 on: December 07, 2008, 09:05:18 PM »
Quote
A new operating mode (tying the mode pin to ground) allows the SRF05 to use a single pin for both trigger and echo, thereby saving valuable pins on your controller. When the mode pin is left unconnected, the SRF05 operates with separate trigger and echo pins, like the SRF04.

Voltage: 5V only Required
Low Current: 4 mA Typical!
Frequency: 40 KHz
Maximum Range: 4 meters (~13 ft.)
Minimum Range: 1 cm (<1/2")
Modes: Single pin for trig/echo or 2 Pin SRF04 compatible.
Input Trigger: 10 uSec min. TTL level pulse
Echo Pulse: Positive TTL level signal, width proportional to range
Size: 1.69 x 0.79 x 0.67 in.
43 x 20 x 17 mm

Check out the uBotino robot controller!

Offline MaltiKTopic starter

  • Robot Overlord
  • ****
  • Posts: 300
  • Helpful? 2
Re: How do you make an SRF05 act as a Ping)))?
« Reply #2 on: December 08, 2008, 05:25:30 AM »
so then which pin will be the designated I/O pin?, so I can use only 3 pins thru this strat?

So I should disregard the regular GND pin, and GND the Mode pin instead, and only use one of the Trigger/Echo pins? Does it matter which one?
Also is the code any different than it would be if it were a Ping)))?
« Last Edit: December 08, 2008, 05:39:00 AM by MaltiK »
Warranty

Offline Ro-Bot-X

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,431
  • Helpful? 25
  • Store: RoBotXDesigns.ca
Re: How do you make an SRF05 act as a Ping)))?
« Reply #3 on: December 08, 2008, 06:36:13 AM »
You tie BOTH GND and Mode pins to GND.
You use the Trigger pin to do both functions.
You look at the specs I quote for you in the last post and see there is a little difference in the trigger timing. This sensor needs at least 10us trigger signal, the Ping needs at least 3us trigger signal, typical 5us. So you adjust the code acordingly.

More info here: http://www.robot-electronics.co.uk/htm/srf05tech.htm
« Last Edit: December 08, 2008, 06:39:50 AM by Ro-Bot-X »
Check out the uBotino robot controller!

Offline MaltiKTopic starter

  • Robot Overlord
  • ****
  • Posts: 300
  • Helpful? 2
Re: How do you make an SRF05 act as a Ping)))?
« Reply #4 on: December 08, 2008, 07:52:04 AM »
So I will need a Y-Harness for the GND and Mode pins if I want only 3 pins, and I will not connect anything to the Echo pin.
Warranty

 


Get Your Ad Here

data_list