Subject:
|
Re: YAL, Yet Another LegWay
|
Newsgroups:
|
lugnet.robotics
|
Date:
|
Mon, 9 Feb 2004 20:55:11 GMT
|
Viewed:
|
2906 times
|
| |
| |
In lugnet.robotics, Philippe Hurbain wrote:
|
YAL: Yet Another LegWay
Here are some details of my implementation, using two regular light sensor to
monitor YAL inclination.
The code is a simple PID algorithm
implemented in BrickOS, direct translation of
|
Hey Philo,
I was just looking over your code, and I think if you change this line:
pid = (Kd * errdiff + Kp * err + Ki * errint) /3000l;
to something like this:
pid = (Kd * errdiff + Kp * err + Ki * errint) /3000l + ForwardOffset;
then when you change ForwardOffset (via remote control code) the robot will
start to go forward (or backward, if its negative).
The ForwardOffset could be between -255 and 255 (Im sure you dont want it
quite that big)
Steve
|
|
Message has 1 Reply: | | Re[2]: YAL, Yet Another LegWay
|
| Hello Steve, Monday, February 9, 2004, 8:55:11 PM, you wrote: (...) SH> Hey Philo, SH> I was just looking over your code, and I think if you change this line: SH> pid = (Kd * err_diff + Kp * err + Ki * err_int) /3000l; SH> to something like this: (...) (21 years ago, 9-Feb-04, to lugnet.robotics)
|
Message is in Reply To:
14 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
Active threads in Robotics
|
|
|
|