Save global variables at Arduino flash | Arduino Compatible Compiler for LabVIEW Discussions | Forum

Avatar
Please consider registering
guest
sp_LogInOut Log In sp_Registration Register
Register | Lost password?
Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
sp_Feed Topic RSS sp_TopicIcon
Save global variables at Arduino flash
February 9, 2020
7:21 am
Avatar
Muzikansky
Member
Members
Forum Posts: 9
Member Since:
December 11, 2019
sp_UserOfflineSmall Offline

Hi

I am using PID algorithm to control temperature by Arduino Uno. To achieve best performance I am changing original PID parameters (there are P, I and D global variables) by host computer serial communication. How can I save (by host computer serial command) updated P, I and D global variables at Arduino flash? 

February 11, 2020
12:46 am
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

You can use the Arduino EEPROM.  Take a look at the EEPROM Read Write.vi shipping example.

February 11, 2020
7:51 am
Avatar
Muzikansky
Member
Members
Forum Posts: 9
Member Since:
December 11, 2019
sp_UserOfflineSmall Offline

I saw EEPROM Read Write.vi example. This example saves data at specific address. How can I define software global parameters with some specific address?

February 11, 2020
7:35 pm
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

If you need to save the values to non-volatile memory, then you would have to use EEPROM.  If you just want to save in volatile memory, you can just use LabVIEW global or local variables, which will use RAM on the Arduino.  There is also an example for reading and writing data to program memory (Flash) but writing can only be done at compile time.

Forum Timezone: UTC 0
Most Users Ever Online: 100
Currently Online:
33
Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
miche91: 33
scottj: 28
scadao: 23
Member Stats:
Guest Posters: 5
Members: 202
Moderators: 0
Admins: 3
Forum Stats:
Groups: 1
Forums: 2
Topics: 266
Posts: 1222
Newest Members:
pujacontrol
Administrators: geadmin: 22, filipealtoe: 96, Steffan: 356