| | Does any RCX firmware allow a variable to survice shutdown? Justin Fisher
|
| | I'd like my robot to be able to store a variable, such that when I turn the RCX off, then back on again, with the start/stop button, the value of the variable is retained, not wiped. Is there a third-party firmware or something that allows you to (...) (19 years ago, 28-Jun-05, to lugnet.robotics)
|
| | |
| | | | Re: Does any RCX firmware allow a variable to survice shutdown? Steve Hassenplug
|
| | | | On Tue, June 28, 2005 6:38 am, Justin said: (...) I know this is possible with BrickOS. However, it may even be possible with the NQC. I've seen where people use the same value across different programs. You just need to make sure you store the (...) (19 years ago, 28-Jun-05, to lugnet.robotics)
|
| | | | |
| | | | | | Re: Does any RCX firmware allow a variable to survice shutdown? Justin Fisher
|
| | | | | Thanks for your help everyone. As predicted, it was simply that I was defining my variables in the program, and it hadn't occurred to me that they were already persistant and I was actually resetting them myself. Can there ever be a better answer (...) (19 years ago, 29-Jun-05, to lugnet.robotics)
|
| | | | | |
| | | | Re: Does any RCX firmware allow a variable to survice shutdown? Philippe Hurbain
|
| | | | (...) Have a look to David Schilling's great presentation: (URL) (19 years ago, 28-Jun-05, to lugnet.robotics)
|
| | | | |
| | | | Re: Does any RCX firmware allow a variable to survice shutdown? John Hansen
|
| | | | (...) Global variables in the standard LEGO firmware(s) are persistent (i.e., their values are not lost when you turn off the RCX). You describe turning the RCX off and on using the "start/stop" button. I am guessing that you mean the red button (...) (19 years ago, 29-Jun-05, to lugnet.robotics)
|
| | | | |
| | | | Re: Does any RCX firmware allow a variable to survice shutdown? John Hansen
|
| | | | (...) Here's a very simple NQC example using the standard LEGO firmware. #pragma noinit int a; task main() { a++; } This simple NQC program will increment global variable zero by one each time it is run. You can turn off the RCX and turn it back on (...) (19 years ago, 29-Jun-05, to lugnet.robotics)
|
| | | | |