Shop OBEX P1 Docs P2 Docs Learn Events
Boe-Bot question discussion — Parallax Forums

Boe-Bot question discussion

CupcakeNinjaCupcakeNinja Posts: 2
edited 2013-09-15 16:39 in General Discussion
Hello there, I have a question regarding the basic Boe-Bot programming. I am aware that the Boe-Bot can calculate different mathematical problems (given the correct format), but where does it get the answer? How can I access this part of the programming (the place where the answer is already provided or solved)? I want to be able to give input and then receive a response I designate. Is it possible to do this? Thank you and I look forward to seeing your responses. :lol:

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2013-09-15 12:00
    First of all, the BoeBot is just a Stamp Board of Education on a small robot chassis. The Board of Education is a convenient board that makes it easy to use a Basic Stamp. The device you'd program is the Basic Stamp itself which does all the work. This Stamp includes a voltage regulator, so you can use it with an unregulated 6-9V power supply and it includes a serial port interface that can be used for programming and communications with the PC used for writing and downloading programs. You can get a USB adapter for this if your PC doesn't have a built-in serial port and most versions of the Board of Education already include this adapter.

    Parallax Basic (PBasic) includes statements that can send (DEBUG) and receive (DEBUGIN) serial data from the PC connection and the Stamp Editor includes a debug window specifically for use with these statements although you can use other PC programs to do the same thing. Look in the Stamp Manual or in the Stamp Editor's help files for details on these statements. As a trivial example, you could do:
    ' {$STAMP BS2}
    ' {$PBASIC 2.5}
    
    a   var   word
    b   var   word
    
    DO
      DEBUG "Enter two numbers",CR
      DEBUGIN DEC a, DEC b
      DEBUG "The sum is ",DEC a+b,CR
      DEBUG "The product is ",DEC a*b,CR
    LOOP
    
    If you want some other way to enter and display information, you can attach a keypad and small display to the Stamp and use similar statements to read and display data. A simple and inexpensive display is this one. A simple and inexpensive keypad for numeric input is this one. The indicated webpages have links for programming examples.
  • CupcakeNinjaCupcakeNinja Posts: 2
    edited 2013-09-15 16:39
    Thank you Mike :D That is a heap of help! I will definitely be using this.
Sign In or Register to comment.