Thread: Code Simulator
View Single Post
  #5   Spotlight this post!  
Unread 30-05-2005, 23:10
JJG13's Avatar
JJG13 JJG13 is offline
Yoda
AKA: Joshua Graffman
None #0180 (SPAM)
Team Role: Alumni
 
Join Date: Dec 2002
Rookie Year: 2003
Location: Martin County, Florida
Posts: 105
JJG13 has a spectacular aura aboutJJG13 has a spectacular aura aboutJJG13 has a spectacular aura about
Re: Code Simulator

Having a robot code simulator is an interesting idea.

My thoughts:

We use the C language and there are C compilers for PCs. So theoretically you could compile the code for a robot on a PC with minimal changes. I already do something like this. I cut and paste code on my computer to test to see if it works as I expect it to before I try it out on the robot. The problem is that even if the logic is right the numbers are wrong. For instance, if I want to rotate right 20 degrees I can check my code on my computer and see that the pwms for the right drive motors are decreasing while the left ones are increasing but I cannot tell if I'm going too far or too fast or even if there is enough power going to the motors to for the robot to move at all. What I would need in a simulator would be to calculate the physics of the situation. This would probably be harder than making a C interpreter.

However, if you do make a simulator, share it, because I would use it.
__________________
Behold the power of SPAM.