Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   C/C++ (http://www.chiefdelphi.com/forums/forumdisplay.php?f=183)
-   -   Eclipse WPILib Problem C++ (http://www.chiefdelphi.com/forums/showthread.php?t=134513)

ShadathChow 02-13-2015 03:55 PM

Eclipse WPILib Problem C++
 
Hey everyone,
Our team is having a problem with connecting WPILib to Eclipse. The problem is that where we have errors is in the code that we didn't write. Our main problems are in VictorSP, Digital Input, and Joystick. Joystick won't connect, no matter what we do. For VictorSP, we have errors that say "must implement pure virtual method SpeedController::Set". In Digital Input, we have errors that say "must implement pure virtual method InterruptableSensorBase".

Does anyone know what to do?

Thanks,
ShadathChow

bob.wolff68 02-13-2015 04:30 PM

Re: Eclipse WPILib Problem C++
 
This sounds a bit odd to me. The only thing coming to mind at the moment is that I have seen strange errors (maybe not THIS strange though) with new projects until executing a right-click on the project (left pane) and select Index->Rebuild.

Possibly you need an update of the WPI plugin? If you went through the screensteps very carefully, you will have set your preferences to auto update. Maybe check to see if that's still 'set' right? Preferences... Updates->AutoUpdate and check the checkbox for allowing automatic updates. You can also manually check for updates via Help->Check for updates.

Let us know what you find!

ShadathChow 02-13-2015 04:38 PM

Re: Eclipse WPILib Problem C++
 
Quote:

Originally Posted by bob.wolff68 (Post 1443507)
This sounds a bit odd to me. The only thing coming to mind at the moment is that I have seen strange errors (maybe not THIS strange though) with new projects until executing a right-click on the project (left pane) and select Index->Rebuild.

Possibly you need an update of the WPI plugin? If you went through the screensteps very carefully, you will have set your preferences to auto update. Maybe check to see if that's still 'set' right? Preferences... Updates->AutoUpdate and check the checkbox for allowing automatic updates. You can also manually check for updates via Help->Check for updates.

Let us know what you find!

Unfortunately, we've tried this, to no avail. Thanks for your help, though!

BrianAtlanta 02-13-2015 04:53 PM

Re: Eclipse WPILib Problem C++
 
This isn't likely not be related, but thought I would mention this C++ driver station update just in case.

http://www.usfirst.org/sites/default...Bundle0210.pdf

ay2b 02-13-2015 06:16 PM

Re: Eclipse WPILib Problem C++
 
Note that I am attempting to answer this question having not looked at the WPILib in several years...

The error you are describing sounds like you are trying to instantiate an interface rather than a fully implemented class. Posting a code snipit might help diagnose the exact problem. Do you have a line in your code like:
Code:

SpeedController sc = new SpeedController();
or
Code:

SpeedController sc = new IVictorSP();
If so, try replacing it with something like:
Code:

SpeedController sc = new VictorSP();
Basically what seems to be happening is that there exists a class "SpeedController" that has a method "Set" that is not implemented (it is pure virtual), making this class be an interface. Other classes, such as Victor, Tallon, etc, will derive from the SpeedController class and must implement the Set() method. The error you are reporting makes it sound like you are trying to instantiate one of the parent classes/interfaces, rather than the child class that actually has the implementation.

Check your documentation and make sure you are instantiating the correct class.

ozrien 02-13-2015 06:21 PM

Re: Eclipse WPILib Problem C++
 
Do you at least see an FRCUserProgram binary under the Binaries tree node in the Project explorer? If so then your code is building ok, in which case the IDE parser is likely showing stale info. In which case this should fix it....
http://www.chiefdelphi.com/forums/sh...63&postcount=5

ShadathChow 02-13-2015 08:04 PM

Re: Eclipse WPILib Problem C++
 
Quote:

Originally Posted by ozrien (Post 1443583)
Do you at least see an FRCUserProgram binary under the Binaries tree node in the Project explorer? If so then your code is building ok, in which case the IDE parser is likely showing stale info. In which case this should fix it....
http://www.chiefdelphi.com/forums/sh...63&postcount=5

Quote:

Then in the project explorer, under binaries delete your FRCUserProgram. This step is necessary just for checking that the project does build.
We are getting stuck at this part. Where would we find the binaries to find the FRCUserProgram?

ozrien 02-13-2015 08:23 PM

Re: Eclipse WPILib Problem C++
 
http://wpilib.screenstepslive.com/s/...to-the-roborio

Look at the eclipse screenshots. There is a tree node called "Binaries" in the project explorer. It's above "Includes", which is above "Debug", etc...


All times are GMT -5. The time now is 10:07 AM.

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