Shop OBEX P1 Docs P2 Docs Learn Events
adventures in programming the Boe Bot — Parallax Forums

adventures in programming the Boe Bot

BeowolfganzBeowolfganz Posts: 2
edited 2005-03-18 04:46 in Robotics
I've been doing QBASIC programming for about 10 years,and was quite pleased to find that the PBASIC language used with the BOE BOT was verysimilar to what I had used for so long. Then as I started using the programs in the book that came with my BotI noticed a disturbing trend. programs typed verbatim from the book (including spacing and capitalization) would have strange errors, like commands the book said would work not working. This inscluded DEC and CRSRXY. I thought these were just anomalies till I -started working with the whisker assembly. adding the components was easy, but when the program burped on an IF THEN statement that was perfect,verbatimfrom the book,I was shocked. The error was that there was a missing character and when I compared what I typed to what was in the book,I did not see the missing character. any thoughts?















+

+++

Comments

  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-03-17 14:20
    Do you have this at the top of your programs?

    {$PBASIC 2.5}

    This tells the compiler to use newer features -- if you don't have these features enabled then the compiler will complain about things like CRSRXY and IF-THEN-ELSE constructs.· You don't have to type this in; there's a button on the toolbar that looks like a gear with a little "2.5" on it -- just click that button and you should be set.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
    Dallas, TX· USA
  • BeowolfganzBeowolfganz Posts: 2
    edited 2005-03-18 04:10
    Thanks for the tip, that seems to have fixed the problem. with any luck it will clear the ay for me to finish the book that came with the bot so I can move on to other things with the bot. Odlly enough I did have that line on my program on line 2,but it onlyworked when I used the button to put in for the whiskers.
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-03-18 04:46
    If it worked after you clicked the toolbar button then the line you typed in had a very subtle typo -- this happens, hence the suggestion for the button. Have fun with your Boe-Bot.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
    Dallas, TX· USA
Sign In or Register to comment.