Go to Post I'm not worried about the amount of Segways at a regoinal, I'd rather see them out in the real world than at a robotics competition. - Joe Matt [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 22-12-2015, 17:31
virtuald's Avatar
virtuald virtuald is offline
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,102
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
RoboRIO QEMU VM available

It took a bit more time to do this than I would have liked, but I'm happy to announce that I have some scripts that can be used to start a RoboRIO VM in QEMU on linux.

Now, you might ask, what is this useful for? Well.. probably not that much. However, anything that you're doing that depends on having an ARM userspace and doesn't rely on kernel/hardware features... this might be useful for you. Or not.

https://github.com/robotpy/roborio-vm

It's a bit rough right now, but seems to be functional. Try it out, let me know if you find it useful! If you find bugs, submit a pull request with your fixes.

PS: It sorta works with the 2015 image, but not particularly well. For best results, you'll need the 2016 image, which is currently only available to beta teams.
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
  #2   Spotlight this post!  
Unread 22-12-2015, 18:50
kylelanman's Avatar
kylelanman kylelanman is offline
Programming Mentor
AKA: Kyle
FRC #2481 (Roboteers)
Team Role: Mentor
 
Join Date: Feb 2008
Rookie Year: 2007
Location: Tremont Il
Posts: 191
kylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to allkylelanman is a name known to all
Re: RoboRIO QEMU VM available

Quote:
Originally Posted by virtuald View Post
...doesn't rely on kernel/hardware features...
Would this work for CI? Can robot code run as is in your the VM with out modification? I'm asking because I don't know if WPI is written such that it will gracefully handle missing hardware.

ex 1: Does instantiating a Talon and calling set(1) cause any problems?

If this works and all the network communications function properly (SmartDashboard, DriveStation, etc) this could be an invaluable development and testing tool.
__________________
"May the coms be with you"

Is this a "programming error" or a "programmer error"?

  #3   Spotlight this post!  
Unread 22-12-2015, 18:54
virtuald's Avatar
virtuald virtuald is offline
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,102
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
Re: RoboRIO QEMU VM available

I haven't tried it yet -- but I predict it almost certainly will fail for that use case, as there is no FPGA access and I'm sure nobody has tried it. Driver station communications might work.

For CI, you are better off using mocks, or a modified version of the simulated WPILib (similar to what RobotPy does).
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
  #4   Spotlight this post!  
Unread 24-12-2015, 20:00
simon-andrews's Avatar
simon-andrews simon-andrews is offline
Registered User
FRC #4761 (Robockets)
Team Role: Programmer
 
Join Date: Feb 2015
Rookie Year: 2015
Location: Reading, MA
Posts: 16
simon-andrews is an unknown quantity at this point
Re: RoboRIO QEMU VM available

Do you know if it would be legally possible to host images online so that the copy from Windows step can be skipped?
  #5   Spotlight this post!  
Unread 24-12-2015, 20:57
virtuald's Avatar
virtuald virtuald is offline
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,102
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
Re: RoboRIO QEMU VM available

They used to distribute the images with the C++ updates in a zipfile, but alas no more... but I haven't read the license agreement that carefully. I suspect the only one allowed to distribute the binaries are NI/FIRST.

I very briefly looked at writing a script that would extract the file from the NI update zipfile, but I believe it would require something to parse through the msi to find the right UUID in the cab file... probably not too hard, but I didn't feel like doing it. If you create a script to do that, I'll gladly host it in the repo.
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
Closed Thread


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 03:11.

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