ROBOTC.net forums
http://robotc.net/forums/

Saving data to files.
http://robotc.net/forums/viewtopic.php?f=69&t=13264
Page 1 of 1

Author:  NanoBytes [ Wed Jan 27, 2016 2:11 am ]
Post subject:  Saving data to files.

Our robot is required to run two times. One time to "learn" the map, and the next run will actually run on the map.

However I need to be able to save the pertinent information from the first run. How can I save data to a file in ROBOT C for the VEX IQ?

Author:  Tabor473 [ Fri Feb 05, 2016 2:14 pm ]
Post subject:  Re: Saving data to files.

Is there a reason you need to save the data to a file? Couldn't you just run the maze both times while in the same program? Everything like left turns and right turns just saved into an array while exploring and then read from array while solving?

Code:
task main()
{
   while(learning){
      explore();
   }
   while(notFinished){
      solve();
   }
}

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/