Go to Post Smaller FRC bots...... This is what the Mayans were referring to.... My world is ending.... - CrazyHorse [more]
Home
Go Back   Chief Delphi > Technical > Programming > Python
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rating: Thread Rating: 2 votes, 5.00 average. Display Modes
Prev Previous Post   Next Post Next
  #2   Spotlight this post!  
Unread 03-11-2011, 00:16
Peter Johnson Peter Johnson is offline
WPILib Developer
FRC #0294 (Beach Cities Robotics)
Team Role: Mentor
 
Join Date: Jan 2010
Rookie Year: 2008
Location: Redondo Beach, CA
Posts: 247
Peter Johnson has much to be proud ofPeter Johnson has much to be proud ofPeter Johnson has much to be proud ofPeter Johnson has much to be proud ofPeter Johnson has much to be proud ofPeter Johnson has much to be proud ofPeter Johnson has much to be proud ofPeter Johnson has much to be proud of
Re: Python Compatibility

Quote:
Originally Posted by WillF View Post
So I'm looking at using Python in my team this next season and I have a couple of questions for those of you that used it (with success or failure). I am planning on using Ubuntu 11.04 as my development machine first off. Will this work? How does file transference work?
Yes, it will work. FTP is used to copy files to the robot, which of course is available on Unix (you can also use the provided upload script -- written in Python -- to do it for you). You'll need an equivalent to NetConsole for debugging purposes--"nc" (aka netcat) should work for this, but if not, it should be pretty easy to implement an equivalent in Python. Basically it's just sending/receiving UDP packets of text to port 6666.

Note the Python version installed on the robot is Python 3; while not strictly required, you may find it useful to have Python 3 installed on Ubuntu as well.

There's no equivalent to the driver station available for Unix yet. The protocol's been pretty completely reverse engineered--there's even a basic start to a driver station in the RobotPy repository (https://github.com/robotpy/robotpy/tree/2011/sim/dspy) but it just does basic enable/disable, no joystick support or the like. It should be a straightforward project to enhance this with something like pygame to add the necessary joystick support.

It's rather difficult to develop C++ robot code on Unix. I've heard it's possible but never done it myself--Wind River Workbench isn't available, and you'll need your own GCC cross-compiler hosted on Unix.
__________________
Author of cscore - WPILib CameraServer for 2017+
Author of ntcore - WPILib NetworkTables for 2016+
Creator of RobotPy - Python for FRC

2010 FRC World Champions (294, 67, 177)
2007 FTC World Champions (30, 74, 23)
2001 FRC National Champions (71, 294, 125, 365, 279)
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 06:25.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi