Shop OBEX P1 Docs P2 Docs Learn Events
Stingray with IR — Parallax Forums

Stingray with IR

ratronicratronic Posts: 1,451
edited 2010-11-30 12:38 in Robotics
I have looked but didn't see any postings on how to use the stingray with the parallax ir detector. The easiest way is thru one of the servo headers set at 5 volts. See the attached schematic. You will need to place a 3.3k resistor (thanks to modemman) between the detector's Vcc pin and the detector's Vout pin to make the translator happy.

Edit: This post has been edited from where I showed how to hook it up by by-passing the voltage translators (the harder way)
Edit2: Changed extra pull-up resistor to a 3.3k from a 4.7k
640 x 480 - 212K

Comments

  • ScribblerKartScribblerKart Posts: 45
    edited 2010-07-16 04:48
    This is fantastic. Sorry for the late reply!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ScribblerKart


    Uh oh, ScribblerKart time!
  • ratronicratronic Posts: 1,451
    edited 2010-10-02 18:43
    The reason I am bumping this back up is I have edited the first post to show the easiest method for using the parallax ir detector with the stingray.

    After looking at the control board instructions and the internal diagram for the detector I see the voltage translators need to see 4k or less resistance. The panasonic ir detector only has a 20k internal pull up resistor. So the translators don't have to be by-passed if you put a 3.3k resistor between the detector's Vcc pin and the detector's Vout pin
  • modemmanmodemman Posts: 41
    edited 2010-11-30 12:09
    I wish I saw your post earlier - I'm using a Vishay TSOP34840 IR detector (almost identical to the Panasonic) and played with it for days until I got it right. One time I miswired it and it popped with a nasty smoke/smell, good think I got a bunch from mouser. With the MSR1 and its translators, most interfacing is slightly different, people following Boe-Bot (because it was 5v, people might think it should work) or regular Propeller docs "by the book" should be warned.

    Anyway, what I wanted to say is that for me it did not work with 4.7k. It would flip to 0 when I would press a button on the remote, but would be stuck there until I would touch the ground with my fingers (I know... not too scientifical), or reset the board. I tried different values until I got it to work with 3.3k.

    I basically used this code to very roughly decide if the signal is stable:
      dira[irpin]~           'irpin is the pin linked to the data pin of the IR chip (defined in CON)
      repeat
        if ina[irpin] 
          term.out(".")      'displays dots in a terminal for 1
        else                 'otherwise fills with string of zeroes
          term.out("0")
    

    This is based on Bob Belleville's "IR Kit" from Obex. Basically it displays dots in fast succession. Then, when you hit a button on the remote, it registers the succession of 0s as a series of dots, so you kind of "see", very roughly, the 38kHz patterns of every button press. After experimenting, I was able to "see" if I'm capturing data reliably, or I'm skipping 0s, etc...

    Now, why didn't it work with a 4.7k resistor, and what is the precise science of figuring out what pullups/pulldowns to use while interfacing different sensors to the MSR1?
  • ratronicratronic Posts: 1,451
    edited 2010-11-30 12:38
    modemman - according to page 10 of the data sheet (near the bottom) for the translator chips, they need +/- 2 m.a. drive to operate. The Panasonic PNA4601 has a 20k internal pull-up resistor which (5v/20k = .25 m.a.).
    So I used a 4.7k which (5v/4.7k = ~1 m.a.). That still doesn't meet the 2 m.a. requirement but it worked for me. I'm glad you have it working at 3.3k!
    Chris Savage just posted in this thread - http://forums.parallax.com/showthread.php?t=118789&page=2 that Parallax is working on more solutions for the translators.
Sign In or Register to comment.