Go to Post Including the Kinect in the kit a parts is actually an evil plan. The programers are going to spend all their time playing with the Kinect. In competition the robot is just to sit there because it will not have a program. :ahh: - FrankJ [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 10-11-2014, 23:56
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
Beta testers: Is anyone creating a HAL implementation for the cRIO?

Seems like it should be reasonably easy to do. Just wondering if anyone is going to do it.
__________________
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 11-11-2014, 00:28
jhersh jhersh is offline
National Instruments
AKA: Joe Hershberger
FRC #2468 (Appreciate)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 1997
Location: Austin, TX
Posts: 1,006
jhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond repute
Re: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Quote:
Originally Posted by virtuald View Post
Seems like it should be reasonably easy to do. Just wondering if anyone is going to do it.
WPI decided not to do this and not to support the cRIO at all. It was more of a move for the future if I understand correctly, but it's certaily a babystep. There are still plenty of implementation details that leak through the HAL API. Perhaps when a completely different hardware target is ported the API will become more generic.
  #3   Spotlight this post!  
Unread 11-11-2014, 23:28
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: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Ok, so WPI isn't doing it -- which makes sense.

Anyone else doing it yet? I'm sure someone will do one at some point.
__________________
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 12-11-2014, 03:35
SoftwareBug2.0's Avatar
SoftwareBug2.0 SoftwareBug2.0 is offline
Registered User
AKA: Eric
FRC #1425 (Error Code Xero)
Team Role: Mentor
 
Join Date: Aug 2004
Rookie Year: 2004
Location: Tigard, Oregon
Posts: 487
SoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant futureSoftwareBug2.0 has a brilliant future
Re: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Our team basically had this last year and is porting it to the roboRIO but the roboRIO version isn't in a usable state yet.
  #5   Spotlight this post!  
Unread 12-11-2014, 10:55
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: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Quote:
Originally Posted by SoftwareBug2.0 View Post
Our team basically had this last year and is porting it to the roboRIO but the roboRIO version isn't in a usable state yet.
Well, close, but not quite what I want. This year, the python wpilib will be 100% python, using ctypes to interact with the HAL library. So, to make it work for the cRio, it seems like the best way would be to implement an API compatible HAL. There are a lot of cRios out there, and I suspect for most teams they'd be useful to use for testing.
__________________
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
  #6   Spotlight this post!  
Unread 12-11-2014, 11:43
Cel Skeggs Cel Skeggs is offline
Robot Software Manager Alumnus
AKA: Previously known as Colby
FRC #1540 (The Flaming Chickens)
Team Role: Alumni
 
Join Date: Feb 2013
Rookie Year: 2009
Location: Portland, Oregon, USA
Posts: 107
Cel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of light
Re: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Quote:
Originally Posted by virtuald View Post
Well, close, but not quite what I want. This year, the python wpilib will be 100% python, using ctypes to interact with the HAL library. So, to make it work for the cRio, it seems like the best way would be to implement an API compatible HAL. There are a lot of cRios out there, and I suspect for most teams they'd be useful to use for testing.
Maybe you could implement the abstraction at a higher level? It seems like you should be able to detect which platform the code is running on, and then dispatch to one of two implementations.

Instead of detecting the platform, you could also just download the correct version of your libraries to each platform. (That's what we've done with our framework to make it completely work on both platforms.)
__________________
Software manager alumnus. Developer of the CCRE, a powerful robot code framework based on dataflow and composibility.
Refer to as she/her/hers. Years of FRC: 2012, 2013, 2014, 2015, 2016. FLL for a few years beforehand.
Team 1540: The Flaming Chickens | Portland, Oregon | Twitter | Facebook
  #7   Spotlight this post!  
Unread 12-11-2014, 22:02
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: Beta testers: Is anyone creating a HAL implementation for the cRIO?

I suspect that writing an abstraction over the hardware abstraction layer is a bad idea.

The goal of the python WPILib project is to be a python implementation of WPILib, so that it is 100% (ish) compatible, as opposed to a framework extending WPILib such as CCRE. Given that the HAL is supposed to be the hardware independent piece, I think that makes the most sense to use as our bottom edge.

If one cannot port the HAL to the cRio, perhaps it should be made more abstract
__________________
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
  #8   Spotlight this post!  
Unread 13-11-2014, 02:28
Cel Skeggs Cel Skeggs is offline
Robot Software Manager Alumnus
AKA: Previously known as Colby
FRC #1540 (The Flaming Chickens)
Team Role: Alumni
 
Join Date: Feb 2013
Rookie Year: 2009
Location: Portland, Oregon, USA
Posts: 107
Cel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of light
Re: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Quote:
Originally Posted by virtuald View Post
I suspect that writing an abstraction over the hardware abstraction layer is a bad idea.
There already IS an abstraction layer over the hardware abstraction layer.

It's called WPILib.

More seriously, the point is that someone's going to have to implement some abstraction for the cRIO either way - the question is at which level, and the HAL might or might not be the best level.

Quote:
Originally Posted by virtuald View Post
The goal of the python WPILib project is to be a python implementation of WPILib, so that it is 100% (ish) compatible, as opposed to a framework extending WPILib such as CCRE.
That doesn't disallow you from the first suggestion, which was to detect dynamically which platform you're on and choose the proper implementation. You can do that with still offering the same WPILib-like interface.

Quote:
Originally Posted by virtuald View Post
Given that the HAL is supposed to be the hardware independent piece, I think that makes the most sense to use as our bottom edge.

If one cannot port the HAL to the cRio, perhaps it should be made more abstract
The HAL may work as a layer at which to do the abstraction. However, doing so will require a significant amount of null code for things like the PDP, PCM, Power API, builtin accelerometer, analog outputs, etc. Besides that, there appear to be a large number of platform-specific calls. (These may, however, be very similar to the cRIO calls. The bird's-eye-view of the HAL looks surprisingly similar to the cRIO's FPGA interface.)

While I would agree that it should be made abstract enough to cover both platforms, I doubt that the WPILib team would see this to be important enough to spend time on, as they have a large enough backlog of more relevant tasks.

Still - this is your project. I suspect you could ask the WPILib team for the parts of the HAL code that they're okay with making public (or access them directly after talking to them) and then start the project of supporting the cRIO with it yourself. If you stick it on GitHub or somewhere similar, you might be able to get other teams to help out.
__________________
Software manager alumnus. Developer of the CCRE, a powerful robot code framework based on dataflow and composibility.
Refer to as she/her/hers. Years of FRC: 2012, 2013, 2014, 2015, 2016. FLL for a few years beforehand.
Team 1540: The Flaming Chickens | Portland, Oregon | Twitter | Facebook
  #9   Spotlight this post!  
Unread 14-11-2014, 09:55
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: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Quote:
Originally Posted by Colby Skeggs View Post
There already IS an abstraction layer over the hardware abstraction layer.

It's called WPILib.
Fair enough. Don't need yet another abstraction for my purposes then.

Quote:
The HAL may work as a layer at which to do the abstraction. However, doing so will require a significant amount of null code for things like the PDP, PCM, Power API, builtin accelerometer, analog outputs, etc. Besides that, there appear to be a large number of platform-specific calls. (These may, however, be very similar to the cRIO calls. The bird's-eye-view of the HAL looks surprisingly similar to the cRIO's FPGA interface.)
Yep. Given that they both use the underlying NI chipobject stuff as their interface to the hardware, it's not that surprising that it's similar -- which is why I think it would be easy for anyone wanting to create a HAL to do so. I suspect that the initial implementation of HAL involved cut/paste all the ChipObject stuff from the existing WPILib implementation into the HAL code.

Quote:
Still - this is your project. I suspect you could ask the WPILib team for the parts of the HAL code that they're okay with making public (or access them directly after talking to them) and then start the project of supporting the cRIO with it yourself. If you stick it on GitHub or somewhere similar, you might be able to get other teams to help out.
The source for HAL is all included in the WPILib source, so that part is covered. I might do a HAL implementation at some point if someone else doesn't do it first. I also have a large backlog, which is why I was hoping someone else had already done it.
__________________
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
  #10   Spotlight this post!  
Unread 15-11-2014, 01:04
Cel Skeggs Cel Skeggs is offline
Robot Software Manager Alumnus
AKA: Previously known as Colby
FRC #1540 (The Flaming Chickens)
Team Role: Alumni
 
Join Date: Feb 2013
Rookie Year: 2009
Location: Portland, Oregon, USA
Posts: 107
Cel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of lightCel Skeggs is a glorious beacon of light
Re: Beta testers: Is anyone creating a HAL implementation for the cRIO?

Quote:
Originally Posted by virtuald View Post
Fair enough. Don't need yet another abstraction for my purposes then.
True - but that also means that you can have multiple implementations behind WPILib. We're actually doing that in the main source code for WPILib, with the actual code and the simulation code. It's cut into three projects - common, simulation, and real, and both the real and simulation project implement some of the classes separately.
Quote:
Originally Posted by virtuald View Post
Yep. Given that they both use the underlying NI chipobject stuff as their interface to the hardware, it's not that surprising that it's similar -- which is why I think it would be easy for anyone wanting to create a HAL to do so. I suspect that the initial implementation of HAL involved cut/paste all the ChipObject stuff from the existing WPILib implementation into the HAL code.
Fair enough.
Quote:
Originally Posted by virtuald View Post
The source for HAL is all included in the WPILib source, so that part is covered. I might do a HAL implementation at some point if someone else doesn't do it first. I also have a large backlog, which is why I was hoping someone else had already done it.
Well, I don't think they want the WPILib source code public yet - which is the issue, unless you plan to keep you work private for a while.

I'd also consider helping, but I also have a large backlog of pending work.
__________________
Software manager alumnus. Developer of the CCRE, a powerful robot code framework based on dataflow and composibility.
Refer to as she/her/hers. Years of FRC: 2012, 2013, 2014, 2015, 2016. FLL for a few years beforehand.
Team 1540: The Flaming Chickens | Portland, Oregon | Twitter | Facebook
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:02.

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