Shop OBEX P1 Docs P2 Docs Learn Events
PC Recognizing Stamp Module — Parallax Forums

PC Recognizing Stamp Module

txaggietxaggie Posts: 26
edited 2011-03-10 08:35 in BASIC Stamp
Hello all!

I have searched this forum over and over and can't seem to find an answer to this. When you download a program to the stamp, the editor "self-discovers" which com port it is on and which stamp module it is. I currently have my software I wrote and my BS2px prototype project working great(although the com port is hard-coded). There are others out there that are interested in my project as well. I'd like to give them the schematics, BOM and software as freeware, but would like to code in an auto setup in the software for whichever stamp they choose to use. Basically, I want the software to auto-scan the ports checking for the stamp module they have (Like when you click on identify in the stamp editor), then when found, automatically download the compatible code (correct compiler directives) via stampw command line spawned in an internal thread (If it is their first run or there is a firmware update). I know I can create a multi-file project for the advanced BS2 modules, but they can also use the BS2 module, which doesn't allow that as I understand it. Also, I don't want the stamp code overloaded with a bunch of conditional #DEFINE statements. In the end, I want all this to be internal to the software, so non-savvy users can just plug and play, and not have to worry about the Stamp Editor or need to learn how to program the stamp. The port scanning is easy, but what I really want to know, is how the editor retrieves the module info while scanning?

Any ideas? Thanks,
Scott

Comments

  • PJAllenPJAllen Banned Posts: 5,065
    edited 2011-03-10 04:38
    "I don't want the stamp code overloaded with a bunch of conditional #DEFINE statements."
    That stuff doesn't take up memory, if that's your concern.
  • txaggietxaggie Posts: 26
    edited 2011-03-10 06:33
    Thanks for the reply PJ. No, I am just thinking about code maintenance and if someone that is somewhat familiar with stamp, I can give them the source file with comments that pertains to their specific module (ADC interfaced with I2C vs serial for instance). But, really, all that is just me thinking ahead. I just want to know how I can identify if there is a stamp module during a port scan, without using stampw.exe /identify. Maybe it's proprietary?

    Thanks,
    Scott
  • Mike GreenMike Green Posts: 23,101
    edited 2011-03-10 07:02
    You can get a copy of the compiler / downloader as a library here for Windows, Linux, or the MacOS (see Tokenizer at the bottom of the page). Included in the archive you download is some documentation including that for the Stamp downloading protocol. The identification codes for most of the Stamps are included. The BS2px is not because the documentation hasn't been updated since it was released, but you can write a program that will display what's returned and use that.
  • txaggietxaggie Posts: 26
    edited 2011-03-10 08:35
    Thank you Mike! The programing protocol for the reset and identify sequence was exactly what I what looking for!!!

    Thank you!,
    Scott
Sign In or Register to comment.