Using IR with the Javelin
Hi,
I’m trying to do on the Javelin the IR experiment described on page 239 of the Robotics with the Boe-Bot student guide.
The guide asks to generate a harmonic at 38.5 KHz. From the documentation of the Javelin I don’t see any way of doing it. Is it possible to do this? If yes, how?
Thanks,
Enrique
I’m trying to do on the Javelin the IR experiment described on page 239 of the Robotics with the Boe-Bot student guide.
The guide asks to generate a harmonic at 38.5 KHz. From the documentation of the Javelin I don’t see any way of doing it. Is it possible to do this? If yes, how?
Thanks,
Enrique
Comments
the PWM virtual peripheral, with a low period of 1 and a high period of 2,
giving total of T = 3*8.68 usec = 26.04 usec --> f = 38402 Hz.
(this is a signal with 66% dutycycle).
regards peter
I wired the IR circuit so that the IR diode is fed from pin 8 and the IR receiver feeds pin 9. At pin 0 I have a regular LED.
When I run the attached program the regular LED will turn off for approximately one second when I place a white piece of paper in from of the IR diode/ IR receiver pair. After one second the regular LED turns back on. If I take away the paper and the place it back again the regular LED again turns off and on.
I have checked with a probe and at pin 8 the PWM outputs continuously (it doesn’t stop after the regular LED has turned back on while the paper is in front of the IR diode/ IR receiver pair). While the piece of paper is in front of the IR diode/ IR receiver pair, and the PWM is pulsing, the output of the detector goes low. After approximately one second the detector will not got low at the pulsing (this explains why the regular LED turns on).
My question is, why does the IR receiver stop going low after one second?