![]() |
Re: RELAY!!
Quote:
|
Re: RELAY!!
Thanks for the correction Joe. After reading through the WPILib code again, I see how this is being done and agree with what you said about the resources. I also see what you mean about my code example. With the realays and digitial i/o on the same slot, it doesn't make any difference to specify the slot number in this case. I went back and put my original post in a spoiler tag to prevent confusion yet still have my bad analysis still available to learn from.
So, back to the analysis of the original error. The error clearly states that a resource is being allocated that was already allocated. I saw that Alan just posted a good suggestion that I was going to suggest next. My other suggestion (somewhat related) was to make sure there were no other places in the code that create relays, speed controllers, or analog/digital inputs on channels that were already in use for that resource type. |
Re: RELAY!!
Quote:
You might want to look into using one of these two implementations of RobotDrive. RobotDrive::RobotDrive(SpeedController *leftMotor, SpeedController *rightMotor, float sensitivity); RobotDrive::RobotDrive(SpeedController &leftMotor, SpeedController &rightMotor, float sensitivity); |
Re: RELAY!!
Quote:
|
| All times are GMT -5. The time now is 14:26. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi