Ping))) with arduino and relays...

hey all,

I am very new to arduino platform...I want to control a (220-240V/50Hz) lamp's brightness with arduino.

I went through all the posts related to different ultrasonic sensors (Ping))), SRF04). and also massimo's post about using velleman K8064 dimmer kit.

what I am not understanding is...
what is the difference between the two ultrasonic range sensors(which will be more suitable for this project)
How do I change the pulse count (of the sensor) to the information light dimmer(K8064) is seeking to control the lamp.
what relay should I select for this project.

OR ELSE

It would be smart to hack a remote control light dimmer connected to infrared sensor or a ping))) sensor.

any thoughts on how to do it???

thanks in advance.

The difference between the SRF04 and the Ping is that the SRF04 can be connected 2 ways, either with seperate input and output pins or with a shared in/out pin (like the Ping). The advantage to seperate pins is that your code is a little simpler (you don't need to change the pin you use between input and output modes). The advantage to a single pin is that you use fewer of your Arduino pins (if you are using many rangefinders this is a consideration).
There may be a price difference, too, depending on who you buy from.