Flash Memory Storage

8 years 2 months ago #29530990 by Abaglin
Flash Memory Storage was created by Abaglin
Hi there,

I have bean working with the HBL2360 for a couple of weeks now. I have built a in house AGV but for some reason it the motor controller is not saving of the code to the flash memory that is built into the motor controller.

I sending the code to the device and I thought that it would automatically save to the flash memory after that. Is there something else that I need to do after sending the code to the device?

Thanks.

Please Log in or Create an account to join the conversation.

8 years 2 months ago #29530991 by TechSupport
Replied by TechSupport on topic Flash Memory Storage
Having a hard time deciphering what you are saying.

Are you trying to store new configurations into controller, or are you trying to save data such as values that your set up gets like amps and what not to the eeprom?

Please Log in or Create an account to join the conversation.

8 years 2 months ago #29530992 by Abaglin
Replied by Abaglin on topic Flash Memory Storage
I was trying to save the script to the flash memory, so that script that the motor controller is operating off of will be pulled back up into the roborun program when you reattach a computer to the motor controller. Otherwise I have to pull up a previously stored script and the information may not be up to date. Especially if using a different computer to trouble shoot an issue or whatever situation may arise.

Hopefully that makes a bit more since.

Please Log in or Create an account to join the conversation.

8 years 2 months ago #29530993 by TechSupport
Replied by TechSupport on topic Flash Memory Storage
The script can be downloaded into the controller via the script tab of the utility. There is a button that says "Download to controller" or "To Device". This is how the script gets put into the flash memory. You can only store one script at a time.

You cannot extract what is in the controller in terms of scripts, so you have to leave the Roborun open with the current script in there, or you will have to open a pre-saved script.

Please Log in or Create an account to join the conversation.

8 years 2 months ago #29530994 by LROBBINS
Replied by LROBBINS on topic Flash Memory Storage
What's stored in the controller is not your MicroBasic script, but the machine code derived from it. Even if you could upload it back to the PC it wouldn't do you much good.

What I have found moderately useful for keeping track of versions (if I am disciplined enough to always do this) is to include a line like:

PRINT ("Roboteq_node_13")

at the top of the script so that by opening from the console I can see which program is in the controller. If I've downloaded a script to try out, rather than change the version number I add a comment:

PRINT ("Roboteq_node_13: NO ContactorCloseTime")


I think it would be handy if MicroBasic had macros like C's as I've used in this Arduino C++ variant:

Serial.println(__FILE__ " - " __DATE__ " " __TIME__);

. This automatically sends the file name and the date and time of last download to the serial monitor. Even with that, however, if you've made a change to the program without saving it, you'll see a date/time different from what's in your stored file, but that changed code is lost and gone forever.

Ciao,
Lenny
The following user(s) said Thank You: Peter_Walton

Please Log in or Create an account to join the conversation.

Moderators: tonysantoni
Time to create page: 0.057 seconds