Practicals Flashcards
What is an ESP32?
A System on Chip (SoC) Microcontroller with integrated Wi-Fi and Bluetooth
What are the capabilities of an ESP32?
Able to interface with other systems to provide Wi-Fi and Bluetooth functionality through its SPI, I2C or UART interfaces
Explain how a PWM signal from a microcontroller can be used to control the speed of a motor
- The width of digital pulses is adjusted to generated different average dc voltages
- These dc voltages are then passed through the motor with less voltage meaning slower speeds and vice versa
Explain how an encoder could be used to measure the speed of a motor
- Every second, record the new encoder count and store it
- Subtract the previous encoder count from the new encoder count
- Calculate RPM by multiplying encoder count by 60 then dividing by the pulses per rotation
- Reset the encoder count to 0
Explain how you could use a pair of motor encoders to travel in a straight line
- While moving, record the encoder counts
- If the left encoder count is greater than the right, decrease the left motor speed and increase the right motor speed and vice versa
What are the benefits of using an encoder instead of a delay to stop the car after a specified distance?
- The distance needed to be travelled will always be a constant based on the code
- If delay is used, the speed is now a factor variable which can be affected by voltage fluctuations to the motors
- An encoder gives better control over speed
How do you safely power an LED?
- By adding a resistor into the circuit
- Resistance value needed can be calculated by equation R = V / I , where V is Supply voltage - LED voltage
Describe the purpose of a pull-up resistor
To ensure that a pin always has a defined logical level under all conditions, stopping the input from being in an undefined state
What is a MOSFET?
A transistor where the gate voltage manipulates the conductivity between the source and drain regions
Explain the operation of the bi-directional voltage level shifter
To shift the voltage of a signal either up to 5V or down to 3.3V
What is the purpose of the ‘L298N’ motor driver chip?
To control the speed and direction of the two DC motors
What is the purpose of the ‘SPX29300T-L-5-0/TR’ regulator on the rear of the EEEBot mainboard?
To create and maintain a fixed 5V output voltage, despite changes to the input voltage or load condition
What is the purpose of the two fuses and MOSFET on the EEEBot mainboard?
For temperature protection to prevent the MOSFET from being damaged
On the EEEBot mainboard, why is 5V from the regulator preferable to using voltage pins from the ESP32?
- As a voltage regulator creates and maintains a fixed 5V output voltage, despite the changes to the input voltage or load condition
- Whereas the voltage using voltage pins could cause voltages on the EEEBot to fluctuate and may cause damages to the chip on the ESP32
Explain how I2C works and why it is needed
- Communication takes place between a master and one or more slave devices
- The serial computer bus requires two data lines, SDA and SCL