summaryrefslogtreecommitdiff
path: root/digital/avr/modules/motor/control_system/control_system.txt
diff options
context:
space:
mode:
authorNicolas Schodet2011-10-08 11:56:10 +0200
committerNicolas Schodet2012-03-06 23:16:05 +0100
commit928dc853e088849580aac368401999ea596644bb (patch)
tree7970d54f08a9e802f54c7dbbde4f91987ea5982e /digital/avr/modules/motor/control_system/control_system.txt
parent7a1417eb3cecd3b5f5b8a5c1a73e5a89d19de2d4 (diff)
digital/avr/modules/motor: add motor control system
Diffstat (limited to 'digital/avr/modules/motor/control_system/control_system.txt')
-rw-r--r--digital/avr/modules/motor/control_system/control_system.txt33
1 files changed, 33 insertions, 0 deletions
diff --git a/digital/avr/modules/motor/control_system/control_system.txt b/digital/avr/modules/motor/control_system/control_system.txt
new file mode 100644
index 00000000..e45db230
--- /dev/null
+++ b/digital/avr/modules/motor/control_system/control_system.txt
@@ -0,0 +1,33 @@
+=============================
+ motor/control_system module
+=============================
+:Author: Nicolas Schodet
+
+Introduction
+============
+
+This module will bind together several layers of motor control modules. It
+aims at helping sequencing them in the right order to meets real time
+constrains and state changes sequence required order.
+
+Usage
+=====
+
+You should use one of `control_system_single_t` for a single motor system, or
+`control_system_polar_t` for a dual motor differential robot configuration.
+The encoder and output structures should be initialised and their pointers be
+set before the `control_system_*_init` is called.
+
+The `control_system_*_update_prepare` function should be called right before
+you wait for the next cycle, but after you made changes to consigns. Once the
+next cycle start, as fast as possible, you should first update encoders, then
+call the `control_system_*_update` function, and finally update outputs.
+
+This is important that consigns (and control state) are not changed between
+update preparation and update, because the update function is also responsible
+to reset some internal variables when state is changed.
+
+API
+===
+
+.. include:: control_system.exd