Shop OBEX P1 Docs P2 Docs Learn Events
Need some help on understanding the RUN command — Parallax Forums

Need some help on understanding the RUN command

GUY GARDNERGUY GARDNER Posts: 6
edited 2006-08-15 16:46 in BASIC Stamp
If I have a program in slot 0 which executes with the run command a program residing in slot 1, where does control pass back to in slot 0 after the program in slot 1 has completed? If I do a RUN 0 command from slot 1 where does the program in slot 0 take off and operate from??

Thanks in advance for your help...

G. Gardner - gomango9127@hotmail.com

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2006-08-09 04:14
    When you do the RUN command, the program in the designated slot begins at the beginning. Usually, you use a shared variable to pass a code that indicates where you should continue. This is not like a GOSUB/RETURN where the details of how and where to resume are taken care of. You have to do it yourself. If you divide up your program into large functions, where slot 1 does one of 3 or 4 complex things and is done with them, then slot 0 just waits for some keypad input or button push or something similar and decides which slot can process it, you've probably got the functionality divided up well. It's easy then to go back and forth between slots and start at the right place.
  • GUY GARDNERGUY GARDNER Posts: 6
    edited 2006-08-09 13:45
    Thanks for your input. I'll give it a try

    Guy Gardner

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Guy M. Gardner
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-08-09 21:39
    Guy,

    ·· You could also try reading the following Nuts & Volts Article...It covers Multi-Bank Programming.

    http://www.parallax.com/dl/docs/cols/nv/vol3/col/nv87.pdf

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • GUY GARDNERGUY GARDNER Posts: 6
    edited 2006-08-15 05:51
    Chris:

    Is there a temperature sensor like the DS1620 that is simple, and goes into the 350 deg F range?

    Haven't found your info on the Solder Pot example yet.

    Guy

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Guy M. Gardner
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-08-15 14:51
    Guy,

    ·· I thought I e-mailed you some information on that.· What did you need to know?· We don't have a published schematic or source code on it currently.· I would need to see about getting the schematic written up, etc.· But it's fairly simple, so I could simply the connections for you.

    ·· I used a Super Carrier Board and a BS2px24.· The only reason I used a BS2px24 was because I used a Rotary Encoder to adjust the Set Temperature and I wanted to ensure I had the speed to read it while updating the display, etc.· I used our Thermocouple interface (DS2760) and the display was actually an SLED4 from RENTRON.

    ·· The actual output driver for the Solder Pot is a 50A Crydom SSR, which only gets a little warm when it is turning the pot on.· I don't know where we got the probe we are using, but it is made for the job (K-Type) and has a tip designed to go through a stainless steel collet into the pot.

    ·· The unit was designed so that the Set Temperature couldn't be changed unless you were also holding down a button, which requires 2 hands, thus preventing accidental changing of the temperature.· Pressing the button switches the display from the current temperature to the set temperature.· Each time the button is released the Set temp is updated in an EEPROM location which is read at startup so it always remembers the last setting.· I hope this helps.· Take care.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-08-15 16:46
    BTW, this thread has veered off topic...Please see the original thread for information on termperature control and measurement.

    http://forums.parallax.com/showthread.php?p=600190

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
Sign In or Register to comment.