Shop OBEX P1 Docs P2 Docs Learn Events
programming in linux — Parallax Forums

programming in linux

scooterx3scooterx3 Posts: 4
edited 2010-08-26 03:10 in BASIC Stamp
The BASIC Stamp 1 Starter Kit includes a special BS1 Serial Adapter that allows you to program in the Windows environment.

That's what the description for the BASIC Stamp 1 starter kit says. I know there's software to program in linux, but that it specifically says Windows environment, I figured I'd ask before I went and bought one of these so I don't get a surprise by finding out I can't program it in Linux. Any help appreciated. Thanks.

Comments

  • Peter KG6LSEPeter KG6LSE Posts: 1,383
    edited 2010-08-18 23:15
    I have yet to try WINE with the STAMP SW as My Mac is my main platform I do all my work on but I don't see any reason why it would not work.

    What Distro are you useing . I use RedHat and Fedora and CentOS ..

    Peter KG6LSE
  • scooterx3scooterx3 Posts: 4
    edited 2010-08-19 08:20
    I use Ubuntu, 10.04
  • velociostrichvelociostrich Posts: 40
    edited 2010-08-19 12:11
    I used to use bstamp under Ubuntu 9.04, but support for my Parallax USB-to-serial adapter (and all other such FTDI-based adapters) was broken in 9.10 before I bought a copy of Windows 7 that I now run Parallax's IDE in. I don't know if support for the adapter was fixed in 10.04, but you could certainly give it a try as it's free and open source: http://bstamp.sourceforge.net/

    I just now looked at the bug filed in Launchpad for the adapter, and it seems there's a fix (see posts 7 and 8): https://bugs.launchpad.net/ubuntu/+source/linux/+bug/460857
  • scooterx3scooterx3 Posts: 4
    edited 2010-08-19 16:25
    Oh sweet, that's good to know. Thanks.
  • icepuckicepuck Posts: 466
    edited 2010-08-19 20:21
    I'm running Ubuntu 10.04. BSE v2.5 will not run in wine but v2.4 will. v2.4 has problems in that it doesn't communicate with serial or usb ports because it has something to do with the way Delphi generated the exe, use C/C++ or (gag).Net next time.
    My BOE-USB shows up as....

    Bus 005 Device 003: ID 0403:6001 Future Technology Devices International, Ltd FT

    So communication is possible, just not with parallax software though.
    -dan
  • scooterx3scooterx3 Posts: 4
    edited 2010-08-20 07:27
    So you're using the windows editor under wine. What about the linux software that I see on the downloads page? How come you don't use that instead?
  • Kevin WoodKevin Wood Posts: 1,266
    edited 2010-08-20 08:12
    The Linux software on the downloads page isn't supported by Parallax. It's been provided by the community, and may be in various stages of development or maintenance. If the software isn't being actively developed, you may run into dependency problems when using it under a relatively recent Linux release.

    Honestly, your best experience with the Basic Stamp will happen under Windows. If you can't or won't use Windows, you'll either need to a) get hold of the Basic Stamp kit that you are interested in and try it out, or b) forego the Basic Stamp for something more Linux friendly.

    If you do decide to give the Basic Stamp a try, I suggest you consider getting a Basic Stamp 2 kit that supports USB. This is because the USB kits (Board of Education or Activity Kit w/USB2SER adapter) use the FTDI USB chipset, which is natively supported by Linux. This means that at the very minimum, you'll know that this part is supported. The BS2 would also give you more room for growth and more flexibility than the BS1. If you want to save a few bucks, you could get the "Summer Special" and a USB2SER (this is a Parallax product) and have the equivalent of the Activity Kit.

    For the Propeller chip, there is a community-provided editor called BST (Brad's Spin Tool) that I believe works under Linux, although I haven't tried it. I know that the USB drivers on the Propeller Demo board are recognized under Linux, and that PropForth ( a version of the Forth language) running on the Demo Board can be accessed under Linux. But all of this assumes that you would want to use a Propeller instead of Basic Stamp.

    My take on the matter is that if you're serious about Linux, then Parallax probably isn't the right choice, and if you're serious about Parallax, then Linux probably isn't the right choice.

    P.S. Welcome to the forums :)
  • velociostrichvelociostrich Posts: 40
    edited 2010-08-20 13:34
    Kevin Wood wrote: »
    If you do decide to give the Basic Stamp a try, I suggest you consider getting a Basic Stamp 2 kit that supports USB. This is because the USB kits (Board of Education or Activity Kit w/USB2SER adapter) use the FTDI USB chipset, which is natively supported by Linux. This means that at the very minimum, you'll know that this part is supported. The BS2 would also give you more room for growth and more flexibility than the BS1. If you want to save a few bucks, you could get the "Summer Special" and a USB2SER (this is a Parallax product) and have the equivalent of the Activity Kit.

    Perhaps you missed my post, but support for FTDI-based USB-to-serial adapters was broken in the version of the Linux kernel shipped with Ubuntu 9.10, and I haven't confirmed if there's it's been fixed for 10.04, but there is a fix on the bug page in Launchpad (see my original post above).

    I recently decided to have a look at the bstamp source code because it didn't always work even with an actual serial cable, and when it did, it uploaded code very slowly in comparison to Parallax's software, and I was surprised to realize that it, though licensed under the GPL, had quite a bit of proprietary code from Parallax's examples for how to use their tokenizer library, as well as the proprietary tokenizer library itself. Personally, I don't like using Parallax's IDE because it requires that I run Windows (which I own, but does not perform as well as Linux), and because I don't like the interface -- I much prefer writing code in Vim, for which I've even written a PBASIC syntax script. This thread just might have me write an IDE or something of the sort for Linux for the BASIC Stamps from scratch to replace bstamp...
  • FranklinFranklin Posts: 4,747
    edited 2010-08-20 17:02
    I will look forward to seeing what you come up with. Perhaps I'll fire up the Linux box if it's good.
  • Kevin WoodKevin Wood Posts: 1,266
    edited 2010-08-20 20:36
    @velociostrich - Nope, I didn't miss what you wrote. Perhaps Ubuntu 9.10 didn't work correctly, but I just wanted to emphasize that FTDI support is included in the kernel, and that no additional drivers were necessary. I don't know whether or not the BS1 serial adapter uses an FTDI chipset or not, and I couldn't find the info on the website, so it's hard to tell what support there might be for it in Linux.

    As for the IDE, I think it's probably a violation of the GPL to include non-GPLed code like the tokenizer library. If you really want to create an IDE, I suggest strting with Eclipse or NetBeans and creating the necessary plugins to round it out. You might also see about working with BradC to add Basic Stamp support to his Propeller tool, which supports Linux: http://propeller.wikispaces.com/Mac+and+Linux+native+development.
  • Peter KG6LSEPeter KG6LSE Posts: 1,383
    edited 2010-08-21 03:24
    Kevin Wood wrote: »
    @velociostrich -I don't know whether or not the BS1 serial adapter uses an FTDI chipset or not, .

    If your referring to the # 27111 . BS1 Serial adapter .

    Its just a Level adapter .its RS232 in TTL Out .

    If you want good Linux or mac Out of the box USB to serial support I recomend the USB-19-H from tripplight ( Keyspan) . I * think* it is FTDI based .
    I have yet to find a Distro it has not worked on including DSL.
  • velociostrichvelociostrich Posts: 40
    edited 2010-08-22 18:32
    After reading the PBASIC tokenizer library license, it seems that with programs such as bstamp, where the responsibility of compiling (and, therefore, also linking) the software is left to the user, the user would be required to accept that license as well? This would not be a problem if the license simply disallowed the reverse engineering of the library, but to have to mail or fax a signed license along with a copy of the licensee's driver's license seems rather absurd. Does this, then, mean that my use of bstamp (without having acquired a license) was illegal? I hesitate to spend what little time I have writing an IDE when I (and possibly any user of the software that I write) am required to agree to such a license. Furthermore, the fact that I must have agreed to the license to read the documentation accompanying the tokenizer library is one thing, but to have to agree to the license to use that information does not make sense; I cannot have used the information if I haven't read the document, and would then using that information, protected by the license, violate the GPL in some way?

    @Kevin Wood: I did begin to write something of an IDE in Java quite a while ago when I was learning the language, with the intention of disconnecting it from the tokenizer; it would merely run an external program (such as bstamp) to handle tokenization and uploading, but providing an interface with tools to help write PBASIC. Really the only thing I accomplished was to write a simple graphical interface that would allow the user to calculate SERIN/SEROUT baudrate values given the model BASIC Stamp and related variables.

    As for BST, is the source code actually available or not? I've looked at the site briefly, but didn't see it anywhere.
  • Kevin WoodKevin Wood Posts: 1,266
    edited 2010-08-22 19:28
    I don't know if BST is open or not. You would need to contact the author. His user name here is BradC, and he's usually in the Propeller forum.
  • chrisadamchrisadam Posts: 2
    edited 2010-08-26 03:10
    This virtual file system is implemented as a binary file and I have a problem with some of the functions as it needs to incorporate with Unix and I don't know how/where to start. The basic functions (i.e. manipulation) I had to perform are:

    1. Display a directory listing
    2. Renaming a file
    3. Removing a file
    4. Display the contents of each file.

    ________________________________________________

    Want to get-on Google's first page and loads of traffic to your website? Hire a SEO specialist from Ocean Groups seo specialist
Sign In or Register to comment.