Shop OBEX P1 Docs P2 Docs Learn Events
38.5KHz using the BS2P-40 — Parallax Forums

38.5KHz using the BS2P-40

Jeff SteenckenJeff Steencken Posts: 32
edited 2010-04-27 02:54 in BASIC Stamp
I am trying to figure out what variables to use with the BS2P to achieve 38500 Hz. I have been studying page 123 of the basic stamp manual and can't seem to get the 38.5KHz. The most I read on the frequency meter is around 3 KHz. Can someone help with the proper variables?
Thank You

Comments

  • FranklinFranklin Posts: 4,747
    edited 2010-04-27 02:03
    What code are you using now?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Stephen
  • Jeff SteenckenJeff Steencken Posts: 32
    edited 2010-04-27 02:23
    Hello Stephen,

    I initially was using the freqout example from the IR Test program for the boe bot (FREQOUT 8, 1, 38500 ) with that code I was getting about 1 KHZ. Realizing that I am using a BS2p not a bs2 I reviewed page 123. Looking at the chart I divided 38500 by 3.77 and used 10212 for the Freq variable. I also changed the Period to 3, I am not sure that was correct.
    The last code I tried was FREQOUT 8, 3, 10212. Thank you for your help.

    Jeff
  • PJAllenPJAllen Banned Posts: 5,065
    edited 2010-04-27 02:54
    Try a longer Duration in your argument· -- FREQOUT 8, 2000, 10212·

    With FREQOUT 8, 3, 10212 it's giving 3msec bursts of 38500Hz

    "FREQOUT 8, 1, 38500" gives 1msec bursts of.. a·value not allowed (0 - 32767, only)
Sign In or Register to comment.