Go to Post Isn't that the name of the game... Roomba Rumble? - Mr. Van [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 19-04-2012, 19:39
joelg236 joelg236 is offline
4334 Retired Mentor & Alumni
AKA: Joel Gallant
no team
Team Role: Mentor
 
Join Date: Dec 2011
Rookie Year: 2012
Location: Calgary
Posts: 733
joelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond reputejoelg236 has a reputation beyond repute
PID Subsystem using direct PWM ouput

I am using a PID subsystem to control our arm. When I start the command to setToSetpoint(setpoint), the PID subsystem actually accesses the PWM port directly, and as I have already made an instance of that PWM port for teleop, I get a NullPointerException for a used PWM port. This stops our code, and is basically detrimental to all our PID controllers. Its worth noting that all of our motor objects are outside of the PID classes, mostly for organization. I am using custom methods to control those motors. These custom commands are perfectly functional, and are not the problem (We use them in teleop). How can I make it so that the PID subsystem does not "reach" into the other portions of the code, and just give the output. Thats it. Is there a workaround for this, or is this not common? I have had very little luck with PID control systems and I am getting fed up with how it has been implemented in the wpilibj libraries. Maybe making my own algorithm might work better.
__________________
All opinions are my own.
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 10:05.

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