|
Re: Delay10KTCYx in C18
I had similar code for when I was doing MPLabs. I had a fancy one that would let you have multiple threads and time a few things at the same time.
Ahhhh the days of rolling your own components, the sweet smell of 1's and 0's .
Anyway today the RobotC compiler does all of that for you. It also has tasks that you can spawn off to do specific functions and not wait in the main line.
Marks 'case' code is a good example of how we would put state machines together and have them do the heavy lifting of what the robot code needed to do. A little work with Google will get you some good tutorials on state machines.
But it looks like you are on the right track of getting your robot to move.
__________________
Foster - VEX Delaware - 17 teams -- Chief Roboteer STEMRobotics.org
2010 - Mentor of the Year - VEX Clean Sweep World Championship
2006-2016, a decade of doing VEX, time really flies while having fun
Downingtown Area Robotics Web site and VEXMen Team Site come see what we can do for you.
|