I am a high school level robotics instructor, and I also teach summer programs. I wanted to share my programming curriculum with you all to see if it will meet the needs of my students, or possibly go over their heads. Since the core of robotics is feedback control, that is the focus of my curriculum. I wanted to know if you all could take a quick look through my code and activities and see if anything can be improved upon. Also, if you haven’t yet learned about proportional control and you have access to a cortex and some parts, DM me for pictures of the setup they use and I will supply you with it.
NOTE: Before I start with this curriculum, I have my students complete most of a python tutorial online like this one https://www.sololearn.com/Play/Python#
I believe that limit switches and proportional feedback controllers are simple enough for a first year robotics students, and even students who are new to programming all together. Before scripting autonomous code based on timing, or advanced joystick control schemes, I think that getting a student to have a motor move a gear attached to a sensor towards its value is actually a pretty low hurdle. Now I am not saying jump right into to multiple PID+C structures, but starting with a ping pong controller (bouncing at full speed between limit switches) and then slowly moving through preset value proportional control (PC), joystick-controlled PC, and scripted PC to teach the basics of autonomous systems before moving through the derivative, integral, and constant parts of advanced (for high schoolers) control theory.
Now in my time trying to teach control theory to students, the greatest prohibitive factor is the language. PID is meaningless to most students, and doesn’t easily describe what each letter does. Therefore I have renamed each.
P - Spring
D - Brakes
I - Windup
C- Constant (yeah this one is actually good)
I start by teaching “Spring control”, and after they master that, add in brakes, and then finally windup.
Here are the programs I have them install, demonstrate, mess with, and then answer questions on.
Bouncing Triggers This introduces how motors are set from variables, and how changing those variables changes the behavior of a motor driving small gear, driving a large gear, moving a standoff in an arc between two limit switches.
Then they attach a potentiometer to the large gear (I would do an optical encoder if they were cheaper)
Simple proportional control This one features the use of a basic function and introduces the Spring (proportional control)
Spring with Scripting This introduces arrays and functions with parameters.
Spring and Brakes (PD) This introduces the “derivative” and will include the idea of local vs global variables. This is the program I am least secure with since it requires passing variables a lot, instead of just relying on a structure, but it will be a while before I take things to that level.
Let me know if you can see some obvious improvements to this code or the supporting activities/questions, or if you learn something from it. Remember that it is for students with only a month of exposure to python, so if there is a more simple way to introduce these concepts, let me know. Thanks, and happy computing.