mirror of
https://github.com/alexandrebobkov/ESP-Nodes.git
synced 2025-11-18 17:07:42 +00:00
RC Robot Tutorial
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -22,9 +22,25 @@ x- and y- axis potentionometers (**GPIO0** and **GPIO1**).
|
||||
Controlling the Direction and Speed
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
The pairs of DC motors on the left side are wired to the dedicated PWM channels. This means that *ESP32-C3 Breadboard DevBoard* can control rotation speed and direction of DC motors in pairs only (i.e. left and right side).
|
||||
Consequently, only four PWM channels are sufficient for controlling the direction of the RC car.
|
||||
Based on this constraint, the RC car can only move front, back, and turn/rotate left and right. Any other movements are not possible (i.e. diagonal or sideways).
|
||||
To set any desired speed of BiteRider RC car, the *ESP32-C3 Breadboard Adapter DevBoard* uses PWM to control the rotation speed
|
||||
of DR motors. Similarly, to set the direction of the RC car, the rotation speed of corresponding DC motors is changed as required.
|
||||
|
||||
Due to the design and limited number of available GPIOs, the *ESP32-C3 Breadboard DevBoard* can control rotation speed and direction
|
||||
of DC motors in pairs only (i.e. left and right side). Consequently, this means that the four PWM channels used for controlling the
|
||||
direction of the RC car.
|
||||
|
||||
Based on this constraint, the RC car can only move front, back, and turn/rotate left and right. Any other movements are not
|
||||
possible (i.e. diagonal or sideways).
|
||||
|
||||
+--------------------------+-------------------------------+
|
||||
| PWM of DC Motors | Direction |
|
||||
+--------------------------+-------------------------------+
|
||||
| PWM (left) = PWM (right) | Straight (Forward or Reverse) |
|
||||
+--------------------------+-------------------------------+
|
||||
| PWM (left) > PWM (right) | Turn Left |
|
||||
+--------------------------+-------------------------------+
|
||||
| PWM (left) < PWM (right) | Turn Right |
|
||||
+--------------------------+-------------------------------+
|
||||
|
||||
.. admonition:: What is PWM?
|
||||
|
||||
|
||||
@@ -48,9 +48,29 @@ x- and y- axis potentionometers (<strong>GPIO0</strong> and <strong>GPIO1</stron
|
||||
</section>
|
||||
<section id="controlling-the-direction-and-speed">
|
||||
<h3><span class="section-number">2.1.2. </span>Controlling the Direction and Speed<a class="headerlink" href="#controlling-the-direction-and-speed" title="Link to this heading">¶</a></h3>
|
||||
<p>The pairs of DC motors on the left side are wired to the dedicated PWM channels. This means that <em>ESP32-C3 Breadboard DevBoard</em> can control rotation speed and direction of DC motors in pairs only (i.e. left and right side).
|
||||
Consequently, only four PWM channels are sufficient for controlling the direction of the RC car.
|
||||
Based on this constraint, the RC car can only move front, back, and turn/rotate left and right. Any other movements are not possible (i.e. diagonal or sideways).</p>
|
||||
<p>To set any desired speed of BiteRider RC car, the <em>ESP32-C3 Breadboard Adapter DevBoard</em> uses PWM to control the rotation speed
|
||||
of DR motors. Similarly, to set the direction of the RC car, the rotation speed of corresponding DC motors is changed as required.</p>
|
||||
<p>Due to the design and limited number of available GPIOs, the <em>ESP32-C3 Breadboard DevBoard</em> can control rotation speed and direction
|
||||
of DC motors in pairs only (i.e. left and right side). Consequently, this means that the four PWM channels used for controlling the
|
||||
direction of the RC car.</p>
|
||||
<p>Based on this constraint, the RC car can only move front, back, and turn/rotate left and right. Any other movements are not
|
||||
possible (i.e. diagonal or sideways).</p>
|
||||
<table class="docutils align-default">
|
||||
<tbody>
|
||||
<tr class="row-odd"><td><p>PWM of DC Motors</p></td>
|
||||
<td><p>Direction</p></td>
|
||||
</tr>
|
||||
<tr class="row-even"><td><p>PWM (left) = PWM (right)</p></td>
|
||||
<td><p>Straight (Forward or Reverse)</p></td>
|
||||
</tr>
|
||||
<tr class="row-odd"><td><p>PWM (left) > PWM (right)</p></td>
|
||||
<td><p>Turn Left</p></td>
|
||||
</tr>
|
||||
<tr class="row-even"><td><p>PWM (left) < PWM (right)</p></td>
|
||||
<td><p>Turn Right</p></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="admonition-what-is-pwm admonition">
|
||||
<p class="admonition-title">What is PWM?</p>
|
||||
<p><strong>PWM</strong> stands for Pulse Width Modulation. It is a technique used to simulate analog voltage levels using discrete digital signals. It works by
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,4 +1,4 @@
|
||||
# Sphinx build info version 1
|
||||
# This file records the configuration used when building these files. When it is not found, a full rebuild will be done.
|
||||
config: 1584acc0da0952bbe91b77f110c060a0
|
||||
config: 8b29499e4c17b20d084216bf1331defb
|
||||
tags: 62a1e7829a13fc7881b6498c52484ec0
|
||||
|
||||
@@ -337,14 +337,78 @@ x- and y- axis potentionometers (
|
||||
</a>
|
||||
</h4>
|
||||
<p>
|
||||
The pairs of DC motors on the left side are wired to the dedicated PWM channels. This means that
|
||||
To set any desired speed of BiteRider RC car, the
|
||||
<em>
|
||||
ESP32-C3 Breadboard Adapter DevBoard
|
||||
</em>
|
||||
uses PWM to control the rotation speed
|
||||
of DR motors. Similarly, to set the direction of the RC car, the rotation speed of corresponding DC motors is changed as required.
|
||||
</p>
|
||||
<p>
|
||||
Due to the design and limited number of available GPIOs, the
|
||||
<em>
|
||||
ESP32-C3 Breadboard DevBoard
|
||||
</em>
|
||||
can control rotation speed and direction of DC motors in pairs only (i.e. left and right side).
|
||||
Consequently, only four PWM channels are sufficient for controlling the direction of the RC car.
|
||||
Based on this constraint, the RC car can only move front, back, and turn/rotate left and right. Any other movements are not possible (i.e. diagonal or sideways).
|
||||
can control rotation speed and direction
|
||||
of DC motors in pairs only (i.e. left and right side). Consequently, this means that the four PWM channels used for controlling the
|
||||
direction of the RC car.
|
||||
</p>
|
||||
<p>
|
||||
Based on this constraint, the RC car can only move front, back, and turn/rotate left and right. Any other movements are not
|
||||
possible (i.e. diagonal or sideways).
|
||||
</p>
|
||||
<table class="docutils align-default">
|
||||
<tbody>
|
||||
<tr class="row-odd">
|
||||
<td>
|
||||
<p>
|
||||
PWM of DC Motors
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Direction
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="row-even">
|
||||
<td>
|
||||
<p>
|
||||
PWM (left) = PWM (right)
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Straight (Forward or Reverse)
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td>
|
||||
<p>
|
||||
PWM (left) > PWM (right)
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Turn Left
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="row-even">
|
||||
<td>
|
||||
<p>
|
||||
PWM (left) < PWM (right)
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p>
|
||||
Turn Right
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="admonition-what-is-pwm admonition">
|
||||
<p class="admonition-title">
|
||||
What is PWM?
|
||||
|
||||
Reference in New Issue
Block a user