Shop OBEX P1 Docs P2 Docs Learn Events
HELP — Parallax Forums

HELP

pelonapelona Posts: 3
edited 2008-09-26 00:49 in Learn with BlocklyProp
hi, I was just wondering if anyone could help me I need to get my boe-bot to beep continuously so i used the program below but it only beeps once and then says waiting for reset over and over, so I was wondering if anyones maybe had any ideas, I need this by tomorrow because I get a grade either A for doing it or an F for not doing so any ideas would be appreciated Thanks. This program was taken from page 110 on the boe-bot manual

' Robotics with the Boe-Bot - StartResetIndicator.bs2
' Test the piezospeaker circuit.

' {$STAMP BS2} ' Stamp directive.
' {$PBASIC 2.5} ' PBASIC directive.

DEBUG CLS, "Beep!!!" ' Display while speaker beeps.
FREQOUT 4, 2000, 3000 ' Signal program start/reset.

DO ' DO...LOOP
DEBUG CR, "Waiting for reset…" ' Display message
PAUSE 500 ' every 0.5 seconds
LOOP ' until hardware reset.

Comments

  • Steph LindsaySteph Lindsay Posts: 767
    edited 2008-09-26 00:00
    Hello Pelona,

    You can start by reading about the DO...LOOP command on page 44 of your Robotics book. You can look up each of the commands in the index of your book. Or, look up each of the commands in the BASIC Stamp Editor Help: DO...LOOP, DEBUG, FREQOUT, PAUSE, so you know what each one does.

    Whatever is between the DO and the LOOP commands, your program will do over and over again. In your program, what two commands are in the DO...LOOP? Your program is doing exactly what it is written to do, exactly the way you described it.

    If you want it to make a beep continuously, what command would you need to put in the DO...LOOP?

    -Stephanie
  • SRLMSRLM Posts: 5,045
    edited 2008-09-26 00:49
    Are you trying to evoke pity? Seems like a form a plaugerism to be asking for an answer (this from a UC freshman). Anyway, thanks Lindsay for handling it with tact.

    Anyway, you can also take a look at the "Basic Stamp Syntax and Reference Manual" available for free download from the Parallax website.
Sign In or Register to comment.