Society of Robots - Robot Forum

Software => Software => Topic started by: Hasan999 on January 02, 2010, 07:07:57 PM

Title: Storing values in Axon Microcontroller?
Post by: Hasan999 on January 02, 2010, 07:07:57 PM
In order to calibrate my servo's positions, I need RoboRealm software AND (in order to get the exact "end" positions, like 700 is for centre, i require) HyperTerminal software...

The Problem: I cannot use both softwares at a time, because only 1 Software can use the same COM PORT at a time !

I have modified the Servo_Controller.c, so that when I press the button, Servo1 variable will store the first servo's position, and the next button pressed will store the next servo's position in Servo2 , and so on...

Now, I just want to know, what should I program to store values in variables, SUCH THAT they should remain even after I turn OFF the Microcontroller. (so that I can rprintf the stored values in the next run, while running only HyperTerminal)

Thanks..
Title: Re: Storing values in Axon Microcontroller?
Post by: z.s.tar.gz on January 02, 2010, 08:12:08 PM
The axon is based on an avr chip, so it most likely has some sort of eeprom which doesn't erase with loss of power.
Exactly how you would use it, I don't know as I don't own an axon.
Title: Re: Storing values in Axon Microcontroller?
Post by: z.s.tar.gz on January 03, 2010, 07:02:23 PM
As it turns out, the axon is based on the atmega640 which has 4kb of eeprom. (same for the axon 2)
Title: Re: Storing values in Axon Microcontroller?
Post by: Razor Concepts on January 03, 2010, 07:09:51 PM
EEPROM reading/writing:
http://winavr.scienceprog.com/avr-gcc-tutorial/tip-on-storing-initial-values-in-eeprom.html (http://winavr.scienceprog.com/avr-gcc-tutorial/tip-on-storing-initial-values-in-eeprom.html)
http://www.societyofrobots.com/member_tutorials/node/309 (http://www.societyofrobots.com/member_tutorials/node/309)
Title: Re: Storing values in Axon Microcontroller?
Post by: Admin on January 05, 2010, 01:06:44 AM
Quote
I need RoboRealm software AND (in order to get the exact "end" positions, like 700 is for centre, i require) HyperTerminal software...

The Problem: I cannot use both softwares at a time, because only 1 Software can use the same COM PORT at a time !
If you get a second USB to serial adapter, you can use a different UART for each. I do this all the time for my stuff.