This commit is contained in:
2025-07-05 23:17:31 -04:00
parent fbc130e0b1
commit cb1b7d1446
7 changed files with 23 additions and 11 deletions

View File

@@ -27,9 +27,12 @@ Based on this constraint, the RC car can only move front, back, and turn/rotate
.. admonition:: What is PWM?
PWM (Pulse Width Modulation) is a technique used to simulate analog voltage levels using digital signals. It works by rapidly switching a
digital pin between HIGH (on) and LOW (off) states at a fixed frequency. The duty cycle—the percentage of time the signal is HIGH in one
cycledetermines the effective voltage delivered to a device.
**PWM** (Pulse Width Modulation) is a technique used to simulate analog voltage levels using ddiscrete igital signals. It works by rapidly switching a
digital pin between HIGH (on) and LOW (off) states at a fixed frequency (often, at base frequency of 5 kHz). The duty cycle—the percentage of time the signal is HIGH in one
cycle determines the effective voltage delivered to a device.
A higher duty cycle increases the motor speed, and a lower duty cycle decreases the motor speed. This allows for fine-grained speed control
without needing analog voltage regulators.
A pair of PWM channels are required for defining rotation speed and direction of the DC motors on each side.
In particular, **GPIO6** and **GPIO5** provide PWM to the left- and right- side DC motors to rotate in a **clockwise** direction.

View File

@@ -52,9 +52,11 @@ Consequently, only four PWM channels are sufficient for controlling the directio
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>
<div class="admonition-what-is-pwm admonition">
<p class="admonition-title">What is PWM?</p>
<p>PWM (Pulse Width Modulation) is a technique used to simulate analog voltage levels using digital signals. It works by rapidly switching a
digital pin between HIGH (on) and LOW (off) states at a fixed frequency. The duty cycle—the percentage of time the signal is HIGH in one
cycledetermines the effective voltage delivered to a device.</p>
<p><strong>PWM</strong> (Pulse Width Modulation) is a technique used to simulate analog voltage levels using ddiscrete igital signals. It works by rapidly switching a
digital pin between HIGH (on) and LOW (off) states at a fixed frequency (often, at base frequency of 5 kHz). The duty cycle—the percentage of time the signal is HIGH in one
cycle determines the effective voltage delivered to a device.</p>
<p>A higher duty cycle increases the motor speed, and a lower duty cycle decreases the motor speed. This allows for fine-grained speed control
without needing analog voltage regulators.</p>
</div>
<p>A pair of PWM channels are required for defining rotation speed and direction of the DC motors on each side.
In particular, <strong>GPIO6</strong> and <strong>GPIO5</strong> provide PWM to the left- and right- side DC motors to rotate in a <strong>clockwise</strong> direction.

File diff suppressed because one or more lines are too long

View File

@@ -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: bef41d84121e5e50ab7da6d5c687e1c6
config: 4cc9ee0f9f77e14cf8c7713a4bf8af68
tags: 62a1e7829a13fc7881b6498c52484ec0

View File

@@ -330,9 +330,16 @@ Based on this constraint, the RC car can only move front, back, and turn/rotate
What is PWM?
</p>
<p>
PWM (Pulse Width Modulation) is a technique used to simulate analog voltage levels using digital signals. It works by rapidly switching a
digital pin between HIGH (on) and LOW (off) states at a fixed frequency. The duty cycle&mdash;the percentage of time the signal is HIGH in one
cycle&mdash;determines the effective voltage delivered to a device.
<strong>
PWM
</strong>
(Pulse Width Modulation) is a technique used to simulate analog voltage levels using ddiscrete igital signals. It works by rapidly switching a
digital pin between HIGH (on) and LOW (off) states at a fixed frequency (often, at base frequency of 5 kHz). The duty cycle&mdash;the percentage of time the signal is HIGH in one
cycle determines the effective voltage delivered to a device.
</p>
<p>
A higher duty cycle increases the motor speed, and a lower duty cycle decreases the motor speed. This allows for fine-grained speed control
without needing analog voltage regulators.
</p>
</div>
<p>