Shop OBEX P1 Docs P2 Docs Learn Events
Support — Parallax Forums

Support

DAINCDAINC Posts: 14
edited 2007-06-23 09:16 in General Discussion
·I begin research some Kits of·SX Microcontroller (MC)·and All Basic stamp Kits of Parallax that·I purchase them.
·But I don't know anything:
· 1.·Can Basic Stamp V2.2· Load opcode to SX28ac/ss.·Is it·like PCW C·compiler IDE for File.src , .asm. How do you use to·Basic stamp for SX MC? Examples?
·2. What·are C compiler·and ASM compiler to·File.HEX··for load to·SX MC ?
·3. SX/B ? .src to .Hex?

Comments

  • JonnyMacJonnyMac Posts: 9,215
    edited 2007-06-14 19:31
    1. No, the BASIC Stamp IDE cannot be used to program the SX28; the BASIC Stamp IDE produces PBASIC byte codes that are downloaded to the Stamp for execution by the Stamp's interpreter. You need the SX-Key IDE to program the SX chip.

    2. I'm not sure I understand the question, but if you have the .SRC output from a C compiler you can open it in the SX-Key IDE and assemble it, then save the output to a .HEX file (use Run\Device\Save Hex).

    3. Compile your SX/B program, open the .SRC file, the use Run\Device\Save Hex.
  • BeanBean Posts: 8,129
    edited 2007-06-14 19:52
    I'm not fully understanding either, do you have a programmer that requires .HEX files ?


    1) The basic stamp IDE is NOT a compiler, so it does not generate .src or .asm files. As Jon stated it generates byte codes that are only understood by the basic stamp modules.

    2) If you are using the SX-Key or SX-Blitz there is no need to convert files to .HEX for programming. If you are using some other programmer, then maybe you will.

    3) SX/B is a compiler. It does generate a very readable .SRC file that you can convert to a .HEX file if you need that.

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    “The United States is a nation of laws -· poorly written and randomly enforced.” - Frank Zappa

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    www.hittconsulting.com
    ·
  • DAINCDAINC Posts: 14
    edited 2007-06-17 17:41
    Thanks everyone!
    I will download SX/B for research SX MC!
  • DAINCDAINC Posts: 14
    edited 2007-06-18 16:03
    Hello everybody!
    I write prog. and run SX-key, but ERROR 75, 229.
    SX-key don't have help for ERROR index (number of ERROR).
    People could help me!!!!!!
    Thanks everybody!!!!!!!!!!
  • PJAllenPJAllen Banned Posts: 5,065
    edited 2007-06-18 16:30
    You should upload your program (as an attachment.)
  • DAINCDAINC Posts: 14
    edited 2007-06-18 22:41
    '

    DEVICE SX28, OSC4MHZ, TURBO, STACKX, OPTIONX
    FREQ 4_000_000


    '
    ' IO Pins
    '

    LED VAR RB.0


    '
    ' Variables
    '

    result VAR Byte
    cmpValue VAR result.0


    Watch_List:
    WATCH cmpValue, 1, UBIN


    ' =========================================================================
    PROGRAM Start
    ' =========================================================================


    '
    ' Program Code
    '

    Start:
    CMP_B = 0 ' enable comparator
    TRIS_B = %11111110 ' RB.0 is output

    Main:
    CMP_B = result ' exchange result with CMP
    GOTO Main




    I used SX MC 28AC, crystal 50MHz! And other prog is too!
  • JonnyMacJonnyMac Posts: 9,215
    edited 2007-06-18 22:59
    Are you attempting to run the program in Debug mode so you can see the results of the WATCH directive? If yes, you must remove the resonator and change the DEVICE setting of OSC4MHZ (internal) to OSCXT2 (external) so that the SX-Key can drive the chip; this is necessary so that Debug information can be sent back to the IDE from the SX.

    Note, too, that the latest version of SX/B (1.51.03) includes a command called COMPARE that will simplify that program -- have a look in the Help file
  • DAINCDAINC Posts: 14
    edited 2007-06-19 02:10
    I don't undestand why it is too!!!!!
    Communication pass Com1 is good!
    People have SX-key 3.2 HELP for ERROR then sent for me!
    Thanks!
  • BeanBean Posts: 8,129
    edited 2007-06-19 02:19
    Remove the resonator when programming.

    Your code is using the internal 4MHz so you don't need the 50MHz resonator.


    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    “The United States is a nation of laws -· poorly written and randomly enforced.” - Frank Zappa

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    www.hittconsulting.com
    ·
  • DAINCDAINC Posts: 14
    edited 2007-06-19 02:29
    I think communication ERROR!But I don't repair it!!!!!!
  • DAINCDAINC Posts: 14
    edited 2007-06-19 02:52
    I use Simbread Board with Stamp stick 2SX put to Socket of Simbread Board.Documents for use it is overview! People could sent to me complete picture of that products. Thanks everybody!
  • JonnyMacJonnyMac Posts: 9,215
    edited 2007-06-19 02:57
    According to this page:

    http://www.dontronics.com/stampstick2.html

    ... that board has a BS2sx interpreter in it, and I'm rather doubting that you have a means to reprogram it with the SX-Key IDE. You can in fact use the BASIC Stamp IDE, but you can only program it in PBASIC. That board is not a raw SX chip; it is a form of BASIC Stamp.
  • DAINCDAINC Posts: 14
    edited 2007-06-23 09:16
    Thanks Everybody!
    I drived it!
Sign In or Register to comment.