Shop OBEX P1 Docs P2 Docs Learn Events
BS2 on Linux — Parallax Forums

BS2 on Linux

slackjackslackjack Posts: 25
edited 2006-09-27 13:08 in BASIC Stamp
Hey all,

Is there a tutorial that I can follow to get the basic stamp working on linux. Can someone tell me how to so this?

--thank you.

Comments

  • FranklinFranklin Posts: 4,747
    edited 2006-09-22 02:48
    This might be a good startin place. www.parallax.com/html_pages/downloads/tokenizer/tokenizer.asp

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Stephen
  • brsbrs Posts: 33
    edited 2006-09-24 12:49
    Try using wine (a windows emulator). It's a free program that allows you to install and run windows' programs. works like a champ!

    www.winehq.com/

    Enjoy,
    Bryce
  • RsadeikaRsadeika Posts: 3,837
    edited 2006-09-24 13:04
    As an added note, wine does not work on 64bit linux, make sure you have installed a 32bit version of linux.

    Ray
  • nashnash Posts: 1
    edited 2006-09-24 15:35
    I would also like to develop for the BASIC Stamp 2 (USB interface) in 64-bit linux (Ubuntu). Does anyone know where information can be found about getting going with this combo? It seems that the tokenizer.so library won't run in 64-bit.

    Thanks
  • slackjackslackjack Posts: 25
    edited 2006-09-24 22:22
    I got it to work. I followed these instructions: http://bstamp.sourceforge.net/install/
  • stevewrightstevewright Posts: 4
    edited 2006-09-26 10:19
    So far I have downloaded the two packages listed for Linux at the download page. I unpacked them and followed the README instructions. This is in 32 bit mode, so, sorry, no help for the 64 bit system. I am running Fedora Core 5 on a pentium 3. I am able to open the pbasic editor, write programs, and run them on my "Homework Board". But, not everything works. I am finding that some pbasic commands do work and some do not. Currently I am putting together a list of what does and does not wok. For example I have found that the PIN assignment does not. I follow the syntax of pinname PIN pinnumber, for my program it is SDA PIN 3. ( I was given a program from one of the parallax gurus, it is a program for interfacing with a page memory eeprom. It is an extensive program, and comprehensive - very generous of him who's name I will remember later. sorry.) The compiling fails on PIN, it wants SDA to be a label. FOR ... NEXT works, IF ... THEN seems not to at this point, DEBUG works, DEBUGIN not so. And so on. The source code is included in the download, and maybe I will compile that and see what happens, but for now I will keep building the list and rechecking my syntax.
  • Tom WalkerTom Walker Posts: 509
    edited 2006-09-26 13:08
    stevewright,
    With just a little guessing, it appears that the commands that don't seem to work are those that were added to the 2.5 update. Under normal circumstances, placing the PBASIC 2.5 directive at the start of your program would allow these to be compiled, but I am not aware if the tokenizer for linux is pre- or post-2.5. I believe that the 2.5 directive has been covered in other threads, albeit not for a linux implementation.

    HTH

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Truly Understand the Fundamentals and the Path will be so much easier...
  • slackjackslackjack Posts: 25
    edited 2006-09-26 13:30
    The PIN command does work (if I recall correctly). I will confirm this later. And yes placing the pbasic 2.5 directive does solve most of the errors. The changelog states that it has full support for pbasic 2.5.

    I have the same problem with debugin however. I cant figure out which key (<enter> doesnt work) sends the user inputed data to the basic stamp. I have emailed one of the developers about this problem and I'm awaiting his reply.
  • Mike GreenMike Green Posts: 23,101
    edited 2006-09-26 14:26
    The Stamp uses the "carriage return" code for the end of line (decimal 13) while Linux uses the "line feed" code normally (decimal 10)
  • slackjackslackjack Posts: 25
    edited 2006-09-26 15:44
    Mike Green,

    Could you please elaborate on that. Perhaps an Example if its no trouble.
  • allanlane5allanlane5 Posts: 3,815
    edited 2006-09-26 15:56
    Hmm. '\n' vs '\r'. aka Ctrl-M vs Ctrl-J
  • slackjackslackjack Posts: 25
    edited 2006-09-27 02:41
    Typing a number followed by ctrl-m or ctrl-j doesnt work. It just goes to a new line (same as pressing <enter>). The code wasnt changed though. allanlane5, were you trying to explain Mike Green's reply?
  • Mike GreenMike Green Posts: 23,101
    edited 2006-09-27 04:05
    Allan is correct. Linux and Unix use the line feed character (Ctrl-J or \n) for a newline (end of line) character while the Stamp (and the Mac OS) uses the carriage return character (Ctrl-M or \r) for the end of line. Windows uses both (return, then line feed) for the same purpose. When you hit the Return key, Linux translates it into a newline normally. DEBUGIN may expect the carriage return character to mark the end of the line.
  • slackjackslackjack Posts: 25
    edited 2006-09-27 13:08
    Okay, so here is what I did. I enetred my data from the debug terminal. I press enter (to give a new line), then I hit CTRL-J (to end the line). Still nothing happens. I am using this in the wrong way? DId you get it to work linux?
Sign In or Register to comment.