View Single Post
  #7   Spotlight this post!  
Unread 07-06-2010, 22:38
StevenB StevenB is offline
is having FRC withdrawal symptoms.
AKA: Steven Bell
no team
Team Role: College Student
 
Join Date: May 2005
Rookie Year: 2005
Location: Stanford, CA
Posts: 416
StevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond reputeStevenB has a reputation beyond repute
Re: Using A Scripting Language To Script Robot Behaviour

Quote:
Originally Posted by Tom Line View Post
Why would you want to take a robot that could be programmed in C and C++, two of the most widely-known programming languages there are, and add another layer of complexity along with the potential of another set of errors?
Try asking that to the developers of Python, Ruby, MATLAB, PHP, Tcl, Perl, JavaScript, and Lisp. Why? Because its faster and easier to develop code in a scripting language. I would love to ssh into the robot, open a python shell, and start hacking away. I don't have to recompile and download my code each time, I don't have to mess around with a C/C++ debugger, and I can even experiment with things interactively.
Don't get me wrong, I like C/C++, and Java too. I grew up with them, programmed more than a few robots with them, and learned a ton. I'm using both in my current job. GDB and other debugging tools are great, but they can't beat MATLAB for ease of debugging. There's something about the ease of scripting languages that makes programming fun. Controlling a LEGO Mindstorms robot with Python is a blast; I can only imagine the fun we could have in FRC.

All that said, I'm not sure if the CRIO is ripe for scripting. The thing that makes Python (and PHP and MATLAB) so easy is that there are tons of libraries available only an command away. A language written from scratch wouldn't have the power that these do. Porting an existing interpreter is an even larger amount of work, and for the near term, using C/C++ is a lot easier. As others have said, it's possible to write a good code base so that the C++ you have to work with is more like scripting.
__________________
Need a physics refresher? Want to know if that motor is big enough for your arm? A FIRST Encounter with Physics

2005-2007: Student | Team #1519, Mechanical Mayhem | Milford, NH
2008-2011: Mentor | Team #2359, RoboLobos | Edmond, OK
2014-??: Mentor | Looking for a team...