LAVA Forums Buy cool LAVA gear Forums RSS Feed

Welcome Guest ( Log In | Register )

> Related links

Visit our LabVIEW Wiki MINDSTORMS® NXT article


Tags
(This content has not been tagged yet)
 
Reply to this topic Start new topic
> PI controller for NXT, Just getting started
xavier30
post Jun 29 2007, 01:32 PM
Post #1


Active
*

Member
Posts: 11
Joined: 10-January 07
Member No.: 7476
Using LabVIEW Since:2003
LV:8.20 ,7.1 ,8.0
Norway Norway Switzerland


Hi, i just tried to make a small PI (soon to be PID) controller for integer numbers, since there are no floating point awailable in the NXT. As i understand from the documentation provided with the NXT toolkit, there is a built in PID controller in the output properties for the NXT? Have any of you tested out this controller in LabVIEW (fishing for examples here tongue.gif , since i often find this more explaining than the documentation itself, and im a bit lazy)

This is my own version of the PI controller for INT32, but im wondering if i should rather use U8 or something similar?
This controller multiplies the proportional gain and the integration time by the factor "Scale" so that you keep some of the desmal points which you otherwise would get from floating points. Then it scales down the output and saturates it to the proper limits of the actuator, and also prevents "windup" from the integer of the error.

Can some of you please give me some feedback of these blocs, and help me figure out if i did some calculating errors converting from double to integer?

(Bu the way, the scale defines the value you have to multiply KP, Ti and h with, Kp is the gain (opposite to PB which is 1/KP), Ti is the integral time relative to the scale and h is the step "length")

Cheers^^

X

This post has been edited by xavier30: Jun 30 2007, 09:02 AM
Attached File(s)
Attached File  PIreg.vi ( 275.23K ) Number of downloads: 325
Attached File  X_Y_Scaled.vi ( 8.72K ) Number of downloads: 247
 


Tags
(This content has not been tagged yet)
Go to the top of the page
+Quote Post
Ad
post Jun 29 2007, 01:32 PM
Post #















Tags
(This content has not been tagged yet)
Go to the top of the page
Quote Post
laca
post Jan 15 2008, 01:28 PM
Post #2


One hit wonder!


Member
Posts: 1
Joined: 15-January 08
Member No.: 10461
Using LabVIEW Since:2006
LV:8.5 ,. ,.
Nothing Selected Nothing Selected Nothing Selected


One good info new starter, Thanks.

--------------------


Tags
(This content has not been tagged yet)
Go to the top of the page
+Quote Post

Reply to this topicStart new topic

 




Time is now: 22nd November 2008 - 04:52 AM