Shop OBEX P1 Docs P2 Docs Learn Events
2 BSII Together? — Parallax Forums

2 BSII Together?

ArchiverArchiver Posts: 46,084
edited 2000-10-01 22:54 in General Discussion
Good Day All:

I have finally run out of program space in my BSII
project (A few A/D units recording data viewed via
dial-up modem). Question: I do have an additional
BSII... How do I access stored RAM bytes from another
BSII? I thought I would divide up my program and have
BSII #1 do the recording work and BSII #2 handle the
communications etc. I have studied the manuals but my
understanding is limited to say the least....!

Thanks,
Andy

__________________________________________________
Do You Yahoo!?
Yahoo! Photos - 35mm Quality Prints, Now Get 15 Free!
http://photos.yahoo.com/

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2000-10-01 15:44
    My suggestion would be to use a serial data link between the two BS2's. Have
    the data recorder bs2 format a data string and send it to the communications
    bs2. the communications bs2 would the parse the data string and use it
    accordingly.

    brian



    Original Message
    From: "andy shor" <ashor2000@y...>
    To: <basicstamps@egroups.com>
    Sent: Sunday, October 01, 2000 9:10 AM
    Subject: [noparse][[/noparse]basicstamps] 2 BSII Together?


    > Good Day All:
    >
    > I have finally run out of program space in my BSII
    > project (A few A/D units recording data viewed via
    > dial-up modem). Question: I do have an additional
    > BSII... How do I access stored RAM bytes from another
    > BSII? I thought I would divide up my program and have
    > BSII #1 do the recording work and BSII #2 handle the
    > communications etc. I have studied the manuals but my
    > understanding is limited to say the least....!
    >
    > Thanks,
    > Andy
    >
    > __________________________________________________
    > Do You Yahoo!?
    > Yahoo! Photos - 35mm Quality Prints, Now Get 15 Free!
    > http://photos.yahoo.com/
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-01 15:57
    At 10/1/2000 -0700 07:10 AM, you wrote:
    >Good Day All:
    >
    >I have finally run out of program space in my BSII
    >project (A few A/D units recording data viewed via
    >dial-up modem). Question: I do have an additional
    >BSII... How do I access stored RAM bytes from another
    >BSII?

    You don't, or not directly. Your choices are as follows:

    1. Use an external EEPROM or Flash memory to store data

    2. Connect the two BS-2's together to share information

    In the Stamp Manual [noparse][[/noparse] www.parallaxinc.com ]
    Documentation Section

    Read about -

    a. Serin/Serout

    1. Variables and Modifiers
    2. Baudmodes (including the insets) [noparse][[/noparse]I-19]
    3. Parity, Timeouts and String Handling

    b. Wiring the Stamp-to-Stamp interface [noparse][[/noparse]I-20]

    c. Flow Control (as required)

    d. Open Baud Modes (Page 320)

    And that should start you out on the right foot.


    > I thought I would divide up my program and have
    >BSII #1 do the recording work and BSII #2 handle the
    >communications etc. I have studied the manuals but my
    >understanding is limited to say the least....!

    The BS-2SX runs faster than the BS-2 and permit 8 x 2K program space.
    One one "partition" can be active at a given time (no multi-tasking), but
    variables can be shared between sections (see BS-2SX in Documentation section).

    Additional "getting started" links:

    Tracy Allen, EME Systems [noparse][[/noparse] www.emesys.com ] Basic Stamp Section

    Prof. Peter Anderson, Morgan State U, [noparse][[/noparse] www.phanderson.com ]

    Al Williams, AWC Electronics,
    [noparse][[/noparse] http://www.al-williams.com/awce/asp2.htm ] Proto Board
    also [noparse][[/noparse] http://www.al-williams.com/awce/car1.htm ] Carrier Board
    and [noparse][[/noparse] http://www.al-williams.com/wd5gnr/stampfaq.htm ] Stamp FAQ

    >Thanks,

    Sure, hope that gets you started.

    >Andy

    regards,

    Bruce Bates


    >__________________________________________________
    >Do You Yahoo!?
    >Yahoo! Photos - 35mm Quality Prints, Now Get 15 Free!
    >http://photos.yahoo.com/
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-01 18:44
    Keep in mind that by using the eeprom you are limited to 1million writes. I
    dont know what type of data you are storing and how often it is updated but
    each memory location in eeprom can only be written 1million times. You might
    want to look at using an external serial ram chip.

    MH

    Original Message
    From: "andy shor" <ashor2000@y...>
    To: <basicstamps@egroups.com>
    Sent: Sunday, October 01, 2000 10:10 AM
    Subject: [noparse][[/noparse]basicstamps] 2 BSII Together?


    > Good Day All:
    >
    > I have finally run out of program space in my BSII
    > project (A few A/D units recording data viewed via
    > dial-up modem). Question: I do have an additional
    > BSII... How do I access stored RAM bytes from another
    > BSII? I thought I would divide up my program and have
    > BSII #1 do the recording work and BSII #2 handle the
    > communications etc. I have studied the manuals but my
    > understanding is limited to say the least....!
    >
    > Thanks,
    > Andy
    >
    > __________________________________________________
    > Do You Yahoo!?
    > Yahoo! Photos - 35mm Quality Prints, Now Get 15 Free!
    > http://photos.yahoo.com/
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-01 21:29
    Good Day:
    Thanks to all for the information. I think I better
    just get a BS2sx to keep things simpler. (I just won't
    tell my wife...). I downloaded the IIsx info and it
    seems even using that will involve a fair amount of
    programming changes.

    I'm a bit confused about the difference between the 32
    Byte RAM and the Scratch Pad RAM. I can do VAR
    statements in both but Scratch Pad statements can be
    seen by all 8 programs? Can I just use Scratch Pad for
    everything?

    Thanks,
    Andy

    __________________________________________________
    Do You Yahoo!?
    Yahoo! Photos - 35mm Quality Prints, Now Get 15 Free!
    http://photos.yahoo.com/
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-01 21:53
    >I have finally run out of program space in my BSII
    >project (A few A/D units recording data viewed via
    >dial-up modem). Question: I do have an additional
    >BSII... How do I access stored RAM bytes from another
    >BSII? I thought I would divide up my program and have
    >BSII #1 do the recording work and BSII #2 handle the
    >communications etc. I have studied the manuals but my
    >understanding is limited to say the least....!

    Hi Andy,

    I've posted some material on master/slave flow control between two BS2s at:

    http://www.emesystems.com/BS2misc.htm#MasterSlave

    Also, as Bruce pointed out, you could substitute a BS2sx for BS2. That way
    you would have 8 times as much memory for your program and for data
    recording. Okay, you already have a second BS2 that you could throw at the
    project, but the tradeoff is that you would have to kluge the circuit,
    versus purchase a BS2SX and plug it into the existing circuit. Actually,
    you might be better off with a BS2e instead of a BS2sx. The BS2e has the
    additional memory, but with less power supply current and more
    compatability with the BS2 with respect to timing.

    Not to be ignored is the possibility of writing more efficient code for the
    BS2--but it is already optimized, right!!!

    -- Tracy Allen
    electronically monitored ecosystems
    http://www.emesystems.com
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-01 22:49
    >Thanks to all for the information. I think I better
    >just get a BS2sx to keep things simpler. (I just won't
    >tell my wife...). I downloaded the IIsx info and it
    >seems even using that will involve a fair amount of
    >programming changes.
    >
    > I'm a bit confused about the difference between the 32
    > Byte RAM and the Scratch Pad RAM. I can do VAR
    > statements in both but Scratch Pad statements can be
    > seen by all 8 programs? Can I just use Scratch Pad for
    > everything?

    Hi Andy,

    Also look into the BS2e on the Parallax site, for lower current consuption
    (if you don't need the higher speed of the BS2sx), and for more
    compatability with the BS2 with regards to timing.

    Both the main RAM and the scratchpad RAM in the 'sx or 'e is shared and can
    be seen by all 8 banks.

    The VAR statement works only for the main RAM. The main RAM is really 26
    bytes, because 6 bytes of the 32 are used for the ins, outs and dirs
    control of the Stamp pins. Variables in main RAM can be used in in
    assignment statements like like <x=y+in1>, and as parameters in the
    commands like <pulsout ppin,x>.

    The 63 bytes in the scratchpad can only be accessed with put and get.
    Those bytes cannot be used directly in commands without going through a
    main RAM variable:
    ' example shows use of scratchram
    status_p con 8 ' points to status byte in scratchram
    status var byte ' a variable in main ram
    put status_p,73 ' stores a byte in scratch
    loop:
    get status_p,status ' get a scratchbyte
    debug bin8 status,cr ' show status
    status=inH ' update status=high inputs
    put status_p,status ' save it
    pause 1000
    goto loop

    -- Tracy Allen
    electronically monitored ecosystems
    http://www.emesystems.com/BS2SX.htm <--- more info about the BS2SX and
    BS2e
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-01 22:54
    Hi:
    Parallax is apparently out of stock of the BSIIe which
    is why I thought of the sx. My code is no way as
    efficient as it should be but it is the best I can do
    at this time. I work by looking at other programs and
    snipping parts to make up what I need. I'm slowly
    learning and the manual is starting to make more
    sense!

    Andy



    > Not to be ignored is the possibility of writing more
    > efficient code for the
    > BS2--but it is already optimized, right!!!
    >
    > -- Tracy Allen
    > electronically monitored ecosystems
    > http://www.emesystems.com
    >
    >
    >


    __________________________________________________
    Do You Yahoo!?
    Yahoo! Photos - 35mm Quality Prints, Now Get 15 Free!
    http://photos.yahoo.com/
Sign In or Register to comment.