Go to Post If people played without PDA's back when FIRST had this addiction to nigh-impossible-to-calculate-in-your-head multipliers, then we can play without PDA's now. - Ian Curtis [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

 
 
 
Thread Tools Rating: Thread Rating: 2 votes, 5.00 average. Display Modes
Prev Previous Post   Next Post Next
  #4   Spotlight this post!  
Unread 26-01-2015, 17:00
ozrien's Avatar
ozrien ozrien is offline
Omar Zrien
AKA: Omar
no team
Team Role: Mentor
 
Join Date: Sep 2006
Rookie Year: 2003
Location: Sterling Heights, MI
Posts: 522
ozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond repute
Re: Programming US Digital Encoder

You're sensor is not single-direction (not a tachometer). So you want to select Quad-encoder. That's part of the problem.

So you're initial closedloopErr is +270 ( target - currentPos), such that currentPos is about '0'. 270 times a pgain of '1' will yield '270'. That's about 26% positive throttle (1023 is full, see Duty-Cycle Section 17.5 in software reference manual). So I think that's ok.

Also I see that you reversed the sensor. I'm guessing you followed the procedure in section 7.4 (or similar) to ensure that positive throttle makes "Sensor Position" move in the positive direction.

Just curious how did you hookup the encoder to the motor mechanically. I mean what's the gear ratio between the two?
 


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 01:40.

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