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.
