]> rtime.felk.cvut.cz Git - ert_linux_web.git/blobdiff - rpi-pmsm-control/index.html
Update another link to DCE server which has been renamed to control.fel.cvut.cz
[ert_linux_web.git] / rpi-pmsm-control / index.html
index 509ef393132d0b7e3ad057e31367a3ec964fd6fd..82a193d0d53a1ff4065fb839268ad36c1216b9fb 100644 (file)
@@ -13,7 +13,7 @@
 <div id="main_content" style="max-width: 60em;">
 
 <p>
-[[!rpi_pmsm_motor_control-graphs1.png size="300x" align=right alt="Simulink connected to RPi running PMSM control model"]]
+[[!img rpi_pmsm_motor_control-graphs1.png size="300x" align=right alt="Simulink connected to RPi running PMSM control model"]]
 <a href="http://en.wikipedia.org/wiki/Raspberry_Pi">Raspberry Pi</a> is often
 used for education and many hobbyists tasks but it is not equipped with hardware
 peripherals required for a quite complex vector electric motor control task.
@@ -39,9 +39,11 @@ u<sub>B</sub>, u<sub>C</sub>) only differences count, i.e. one can be
 fixed to zero. A sum of the three currents (i<sub>A</sub>, i<sub>B</sub>,
 i<sub>C</sub>) has to be zero by the Kirchhoff's current law. As a consequence,
 only two independent quantities/scalars are needed to describe the currents
-or Voltages which are in the fact vector in the 2D space. The polar coordinates
+or Voltages which are in the fact vector in the 2D space.The polar coordinates
 system can be used but a rectangular system of alpha, beta components is equivalent
-and easier for transformations computation. This transformation of the three phase
+and easier for transformations computation.
+[[!img pxmc-pmsm-block.png size="500x" align=right alt="Basic PMSM control setup diagram from PXMC library documentation"]]
+This transformation of the three phase
 system to the two orthogonal components vector is named according to its
 inventor Clark transformation. The waveforms in this 2D system are sine
 and cosine for steady speed state. Because realization of a controller
@@ -53,12 +55,66 @@ introduced by Robert H. Park and the transformation is named according to him.
 The control in the D-Q coordinates is (almost) independent of actual rotor
 position and (in simplified outlook) separates reactive current (i<sub>D</sub>)
 from the active current (i<sub>Q</sub>) resulting in torque affecting rotor
-movement.
+movement. The simplified diagram of PMSM motor control ins included for ilustration
+(source <a href="http://www.pxmc.org/">PXMC</a> library documentation).
 </p>
-[[!img pxmc-pmsm-block.png size="300x" align=right alt="Basic PMSM control setup diagram from PXMC library documentation"]]
+
+<h2 id="hardware">Hardware</h2>
+<p>
+The RPi (and its BCM2835 SoC) is equipped with only single accessible
+PWM output and no peripherals suitable for incremental rotary encoder
+(IRC) signal processing are found on the board. Analog to digital
+converters are missing as well. The two extension boards with required
+peripherals and power stage have been designed and produced at <a href="http://www.pikron.com/" target="_blank">PiKRON</a> company.
+The first one includes Field Programmable Gate Array (<a href="https://en.wikipedia.org/wiki/Field-programmable_gate_array" target="_blank">FPGA</a>) <a href="http://www.microsemi.com/products/fpga-soc/fpga/igloo-e" target="_blank">IGLOO AGL125-VQ100</a> produced by Microsemi company. The design of logic programmed into FPGA has been implemented by Martin Prudek in a frame of his <a href="https://dspace.cvut.cz/bitstream/handle/10467/62036/F3-BP-2015-Prudek-Martin-Bp_2015_prudek_martin.pdf" target="_blank">bachelor theses</a>. The FPGA design includes:
+</p>
+<ul>
+  <li>SPI interface which connect peripherals to RPi board
+  </li>
+  <li>32-bit qudrate encoder (IRC) position counter based on design of Marek Peca's (<a href="https://rtime.felk.cvut.cz/gitweb/fpga/quadcount.git" target="_blank"> quadcount</a>)
+  </li>
+  <li>three PWM outputs with half-bridge enable enable signals
+  </li>
+  <li>finite state automata for acquiring current measuremts from analog to digital converter and filtering/decimation of multiple fast reads for slower RPi processing
+  </li>
+</ul>
+
+<h2 id="links">Links</h2>
+<dl>
+  <dt>Processor Systems, GNU/Linux and Control Applications, LinuxDays, 2016</dt>
+    <dd>
+    <dd>Available <a href="https://www.linuxdays.cz/2016/video/Pavel_Pisa-Procesorove_systemy_a_nejen_GNU_Linux_v_ridicich_aplikacich.pdf" target="_blank">online in PDF format</a><br>
+    The second part of the presentation is focused on PMSM motors control lab example.
+    </dd>
+  <dt>Bachelor thesis of Martin Prudek: Brushless motor control with Raspberry Pi board and Linux, 2015</dt>
+    <dd>Available <a href="https://dspace.cvut.cz/bitstream/handle/10467/62036/F3-BP-2015-Prudek-Martin-Bp_2015_prudek_martin.pdf" target="_blank">online in PDF format</a>
+    <br>The FPGA design of peripherals for the RPi expansion board <a href="https://rtime.felk.cvut.cz/gitweb/fpga/rpi-motor-control.git" target="_blank">https://rtime.felk.cvut.cz/gitweb/fpga/rpi-motor-control.git</a>
+    </dd>
+  <dt>PMSM Control Simulink Model including PRi Hardware and SPI Communication Blocks</dt>
+    <dd><a href="https://github.com/ppisa/rpi-rt-control" target="_blank">https://github.com/ppisa/rpi-rt-control</a>
+    <br>The model and bclocks C sources are included in subdirectory "simulink",
+        model name "rpi_pmsm_motor_control.slx".
+    </dd>
+  <dt>Fully preemptive kernel sources for RPi (kernel-3.12.28-rt40+)</dt>
+    <dd><a href="https://github.com/ppisa/linux-rpi/tree/rpi-3.18.y-aufs-rt-ppisa" target="_blank">https://github.com/ppisa/linux-rpi</a>
+    <br>GitHub repository with branch rpi-3.18.y-aufs-rt-ppisa containing Linux kernel sources
+    with Steven Rostedt's stable preempt_rt (patch-3.18.16-rt13) and with Junjiro R. Okajima's aufs3.18.x 20160215
+    patches applied.
+    </dd>
+  <dt>Simulink Embedded Coder target for Linux</dt>
+    <dd><a href="http://rtime.felk.cvut.cz/gitweb/ert_linux.git" target="_blank">http://rtime.felk.cvut.cz/gitweb/ert_linux.git</a>
+    <br>Repository with core templates for Linux hosted, Linux cross architecture targetted
+    Simulink code generation templates and configuration.
+    </dd>
+  <dt>Auxiliary utilities for Raspberry Pi</dt>
+    <dd><a href="https://github.com/ppisa/rpi-utils" target="_blank">https://github.com/ppisa/rpi-utils</a>
+    <br>The repository includes RAM based root overlay support to protect SDcard against wearing and tearing
+    and keep root filesystem intact when experiments are download and run on system or even crash it.
+    </dd>
+</dl>
 
 </div>
 
 </body>
 
-</html>
\ No newline at end of file
+</html>