This zip file contains a Line following program based on the PID controller concept, plus a Calibration program that should run before running the other program.
Line following PID download
For more information about PID controllers, please visit: www.inpharmix.com
Welcome to NXT-progs! Here you will find programs for NXT-G created by me and other NXT-progs contributers. Free downloads of these programs are available in the posts; just click the links. Please give feedback for the programs you download. For any questions, contact me at rrffcre@gmail.com. Enjoy!
Pages
Usage Policy
These programs are designed for recreational and educational use by non-competitive individuals only. The use of these programs in competitive events (e.g. FLL) is prohibited. NXT-progs is not responsible for the misuse of these programs.
This program will need to be tuned for each robot.
ReplyDeleteHow to slow down the bot please?
DeleteThe variable you will need to tweak is "Tp" which stands for "target power". Setting that to a lower number will cause the PID output to hover around a lower power setting.
DeleteWhat are typical Gain value ranges?
ReplyDeleteIt really just depends on your lighting. I would recommend looking at the values from the sensor at the lightest point and darkest point and divide the difference by 200 to get the gain for kp. The other two have to be done by trial and error.
Delete