1/96
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
|---|
No study sessions yet.
What is the key difference between an Interrupt Service Routine (ISR) and an Interrupt Handler in the context of this course?
An ISR is the very short code that runs immediately upon an interrupt, while the Interrupt Handler is the main loop function that responds to a flag set by the ISR.
The actor design pattern, as implemented in the course, uses file-static _____ to act as mailboxes for inter-task communication.
FIFOs
In the actor design pattern, what is the role of the `_run()` function for a task?
It checks its queue for work, processes one item if available, and returns true if work was done, false otherwise.
What is a significant limitation of the `if-else if` scheduler used in the actor model, especially as the number of tasks increases?
It is not very scalable or robust, becoming unwieldy with many tasks and enforcing a strict priority order.
What core capability does an RTOS scheduler have that the simple `if-else if` scheduler lacks, allowing it to handle long-running tasks without blocking lower-priority ones?
Preemption, the ability to pause a task, switch to another, and then return to the original task where it left off.
What is the primary design goal of a Real-Time Operating System (RTOS) compared to a typical desktop OS?
An RTOS aims to complete specific tasks within a specific time period predictably, whereas a desktop OS aims to complete all tasks collectively as quickly as possible.
What is FreeRTOS?
A popular, free, open-source, lightweight Real-Time Operating System (RTOS) for microcontrollers and embedded systems.
Which file is required by FreeRTOS and contains all the settings for the RTOS as `#defines`?
FreeRTOSConfig.h
What is the term for the RTOS mechanism where the scheduler periodically rotates through different tasks, creating the appearance of simultaneous execution?
Time Slicing
What hardware timer on an MCU determines how often the RTOS scheduler switches tasks?
The System Tick Timer (SysTick timer).
In FreeRTOS, what must every task have for storing local variables when the task is switched out by the scheduler?
Its own stack.
What is the term for the current running function and its associated variable/register values that are saved to a task's stack during a context switch?
Context
What FreeRTOS function is called to create a new task?
xTaskCreate()
After creating all necessary tasks, which FreeRTOS function must be called to start the RTOS scheduler?
vTaskStartScheduler()
In FreeRTOS, what is the state of a task that is waiting for a signal or data to continue execution?
Blocked
A key benefit of RTOS is that a task in the Blocked state uses how much CPU power?
It uses no CPU power.
What is it called when a newly unblocked task has a higher priority than the currently running task, causing the RTOS to switch to the new task immediately?
Preemption
What FreeRTOS communication primitive is used to send signals between tasks, indicating it is okay to proceed?
Semaphores
What FreeRTOS primitive allows only one task or interrupt to access a shared resource at a time, preventing race conditions?
Mutex (Mutual Exclusion)
A section of code that cannot be interrupted by the scheduler or other interrupts can be marked as a _____, enclosed by `taskENTER_CRITICAL()` and `taskEXIT_CRITICAL()`.
Critical Section
When converting an actor-based project to FreeRTOS, what are the FIFOs typically replaced with?
FreeRTOS queues.
In a FreeRTOS-aware HAL, what mechanism would you use to protect a shared peripheral like a stdio UART from being accessed by two tasks simultaneously?
A mutex.
What is a 'binary semaphore' in FreeRTOS and how does it differ from a mutex?
It's like a single-element queue that starts empty for signaling, but unlike a mutex, it does not support priority inheritance.
In a Data Flow Diagram (DFD) for an embedded system, what do rounded rectangles typically represent?
Actions or tasks that process data.
In a Data Flow Diagram (DFD) for an embedded system, what do square-cornered rectangles typically represent?
Objects, such as queues, that store data.
In the context of state machine diagrams, what are the three components of a transition label?
TRIGGER [CONDITION] / ACTIONS
What is the purpose of an 'exponential backoff' algorithm in a communications protocol?
To wait a random, exponentially increasing amount of time before retransmitting after a failure, reducing network collisions.
What is the primary purpose of a design process, involving tools like DFDs and state machine diagrams, before starting to code?
To create a 'map' or plan for what you should be doing, which helps manage complexity and reduce errors.
In embedded systems, tasks are often _____, meaning their response to an event changes depending on their current condition.
State Machines
Why is it important to select a resistor from an E-series (e.g., E12, E24) instead of just any calculated value?
Resistors are only manufactured at these standard E-series values, which are based on tolerance.
A resistor's ability to dissipate heat without being damaged is specified by its _____ rating.
power
In the non-ideal model of a capacitor, what does ESL stand for?
Equivalent Series Inductance.
In the non-ideal model of a capacitor, what does ESR stand for?
Equivalent Series Resistance.
What is the practical effect of a capacitor's Equivalent Series Inductance (ESL) at high frequencies?
It causes the capacitor to behave like an inductor, reducing its effectiveness as a capacitor.
Which type of capacitor, aluminum electrolytic or ceramic, typically has higher capacitance values and is used for 'bulk' storage?
Aluminum electrolytic.
Which type of capacitor, aluminum electrolytic or ceramic, has lower ESL and is better suited for high-frequency 'decoupling' applications?
Ceramic
Why must decoupling capacitors be placed physically close to the IC pins they are serving?
To minimize the parasitic inductance of the PCB traces, ensuring they can supply quick bursts of current effectively.
Which type of diode is specifically designed to be used in reverse bias to provide a stable reference voltage?
Zener diode.
Which type of diode is preferred for applications requiring fast switching and a low forward voltage drop?
Schottky diode.
When a MOSFET is used as a closed switch, it acts like a tiny resistor with a resistance value of _____.
RDS(on)
The gate voltage required to just begin turning on a MOSFET is called the Gate Threshold Voltage, or _____.
VGS(th)
When a BJT is used as a closed switch, it is operated in its _____ region.
Saturation
What is a 'Darlington Pair' configuration used for with BJTs?
It uses two BJTs together to achieve a much higher current gain, allowing a small base current to switch a large collector current.
What is the primary disadvantage of using a 'low-side switch' to power a component like a Raspberry Pi?
The voltage drop across the switch (RDS(on)) raises the component's ground potential above the circuit's true ground, which can cause communication issues.
To control a high-side P-channel MOSFET switch with a lower voltage MCU pin (e.g., 3.3V control for a 5V circuit), what additional component is typically used as a driver?
A low-side N-channel MOSFET or NPN BJT.
What is the 'dropout voltage' of a linear regulator?
It is the minimum required voltage difference between the input and output for the regulator to maintain its specified output voltage.
How does a Low-Dropout (LDO) regulator achieve a much lower dropout voltage compared to a traditional linear regulator?
It uses a P-channel MOSFET (or PNP BJT) as a high-side pass element, which does not require a large gate-source voltage drop to turn on.
What is the main advantage of using differential signaling for data lines like USB's D+ and D-?
It provides noise immunity, as interference affects both lines equally and can be cancelled out by taking the voltage difference.
What is the specified differential characteristic impedance for USB 2.0 data lines?
90Ω
In the RP2040 hardware design guide, what value of series termination resistors are required on the USB_DP and USB_DM lines?
27Ω
When designing a PCB for high-speed signals like USB, what physical parameters of the traces determine their impedance?
The trace width, the spacing between traces, and the distance to the reference ground plane.
In KiCad, what feature is used to group the D+ and D- nets of a USB connection so they can be routed together with specific width and spacing rules?
A Net Class.
On a USB-C receptacle used for a USB 2.0 device, what components must be connected to the CC1 and CC2 pins?
Each pin must be connected to its own 5.1kΩ resistor to ground.
What is the primary function of the internal voltage regulator on the RP2040 microcontroller?
It generates the 1.1V for the digital core from the 3.3V I/O supply.
According to the RP2040 hardware design guide, what value decoupling capacitors must be placed close to the VREG_IN and VREG_OUT pins of the internal regulator?
1μF
The RP2040 microcontroller requires what type of external flash memory to store and execute program code?
Quad SPI (QSPI) flash memory.
On the RP2040, what is the function of pulling the QSPI_SS pin low during the boot sequence?
It forces the RP2040 into BOOTSEL mode, where it appears as a USB mass storage device for programming.
What is the recommended external crystal frequency for the RP2040 to ensure stable operation of peripherals like USB?
12MHz
What is the three-step general process for designing a PCB, regardless of the software used?
1. Schematic Capture, 2. Footprint Selection, 3. PCB Layout.
In KiCad, what tool is used to check for common schematic mistakes, such as an input power pin not being driven?
The Electrical Rules Checker (ERC).
What is the purpose of the 'PWR_FLAG' symbol in a KiCad schematic?
It explicitly tells the Electrical Rules Checker (ERC) that a specific net is a source of power.
In the RP2040 minimal design example, why is a 2-layer board less ideal for impedance control compared to a 4-layer board?
The greater distance to the ground plane on a 2-layer board requires much wider traces, which takes up more space and may not achieve the target impedance perfectly.
When designing a VGA output using a resistor DAC, the resistors are weighted to give different significance to each bit, typically in a ratio of _____.
1:2:4:8:16
What is the purpose of adding a ground plane to a 4-layer PCB design?
It improves power supply decoupling and provides low-impedance return paths for signals, reducing noise and electromagnetic emissions.
In the context of the Adafruit Feather RP2040's power path, what component prevents the USB VBUS from back-powering the battery?
A Schottky diode (D4) or the body diode of the P-channel MOSFET (Q3).
Term: Layered Design
An application design approach that uses progressively easier-to-use software modules built on top of each other to abstract hardware details.
What is a major benefit of modular design in embedded systems?
It massively reduces bugs and allows for code reuse by isolating modules from each other.
Term: Symmetric Multiprocessing (SMP)
An OS feature where the scheduler can start and stop tasks on multiple identical cores without special application code.
What happens if you reverse bias an aluminum electrolytic capacitor?
Internal chemistry produces gasses, which can lead to a 'pressure cooker' explosion.
In the KiCad calculator, what type of transmission line is used for two parallel traces on an outer layer over a ground plane?
Coupled Microstrip Line.
For a crystal to oscillate at its specified frequency, it requires a certain _____, which is achieved by placing capacitors on each side of it to ground.
load capacitance
What is the difference between a Cortex-M0+ and a Cortex-M7 MCU core?
The Cortex-M7 has more instructions (opcodes) for specialized tasks, such as digital signal processing, compared to the M0+
What are Open-Drain or Open-Collector outputs primarily used for, and what extra components do they require?
They are used to allow multiple devices to share a single line (bus). They connect the output to GND or leave it floating. Because they cannot actively pull the line high, they require pull-up resistors to VDD to set the logical high level (as seen in I2C and LiPo chargers)
What is the key feature of a Tri-State output?
A Tri-State output can connect to VDD, GND, or enter a disconnected, High Impedance (High-Z) state, effectively functioning as an input when disconnected
What is the function of a Push-Pull output, and can it provide a logic HIGH?
A Push-Pull output can connect its pin to either VDD (logical high, sourcing current) or GND (logical low, sinking current)
Which communication protocol does NOT support multiple peripherals connected to the same bus (wires)?
UART (Universal Asynchronous Reception and Transmission), which is a simple one-to-one connection requiring two wires (TX/RX)
In Power Path design (using battery OR USB), how does a P-Channel MOSFET provide a low-loss connection when the battery is the sole power source?
When the battery is first attached, the MOSFET's internal body diode allows current flow, causing the source voltage to rise,,. This rise creates a negative VGS (since the gate is held at 0 V), which quickly drives the MOSFET past VGS(ON) to fully close the switch, resulting in current flowing through its low RDS(ON) with near-zero voltage drop
What is required if a system uses a Li-Ion battery but lacks a Battery Management IC?
The system must use a protected battery, which has built-in Integrated Circuits (ICs) to prevent over-charge, under-charge, and over-current faults,.
What are the key voltage limits for a single Li-Ion cell?
You must NEVER CHARGE MORE THAN 4.2 V and NEVER DISCHARGE BELOW 3.0 V.
What is the critical charging scheme required for Li-Ion batteries?
Li-Ion batteries must be charged using a two-stage process: constant current followed by constant voltage
What determines the output voltage of a switching power supply (DC-DC converter)?
The output voltage (VOUT) is controlled by the switch's duty cycle (D), which dictates the ratio of time the switch is closed versus open
How do LDO (Low Dropout) regulators solve the high dropout problem?
LDOs use a high-side switch (like a P-Channel MOSFET) as the pass element. This switch style allows the regulator to achieve a very low dropout (e.g., 0.2V), leading to high efficiency (up to 94% for a 3.3V output)
Why do traditional linear regulators have a high dropout voltage?
Traditional linear regulators often rely on a pass element (like an NPN transistor or N-channel MOSFET) whose control voltage is limited by Vbatt. This means that Vout must always be less than Vin−VGS(on) (where VGS(on) is typically high, around 2 V), limiting efficiency when Vin and Vout are close,.
Define Dropout Voltage.
Dropout voltage is the minimum difference between the input voltage (Vin) and the desired output voltage (Vout) required for a voltage regulator to maintain regulation,.
Why is a two-transistor (BJT driving PMOS) driver circuit required when using a 3.3V microcontroller pin to control a 5V high-side switch?
A simple P-Channel MOSFET switch cannot be reliably turned completely OFF by a 3.3V control signal when operating from a 5V supply, because the Gate Threshold Voltage (VGS(th)) specification indicates that VGS = 3.3V−5V=−1.7V might not be positive enough (less negative) to fully open the switch,,,. The BJT solves this by pulling the PMOS gate completely to ground (0V) to ensure VGS=−5V, which guarantees the switch is closed
What is the critical reason for choosing High-Side Switching (connecting the switch to the positive power rail)?
High-side switching is necessary when the load component (like a Raspberry Pi) needs to be attached directly to ground (0 V) to ensure proper communication and function,,.
What is a Darlington Pair and when is it necessary?
A Darlington Pair consists of two BJTs connected in sequence to act as an internal amplifier, making the overall switch require much less base current (e.g., IB>IC/100 to IC/1000). This is necessary when a microcontroller cannot supply the large IB required to saturate a single BJT for a given collector current
How does a designer confirm a BJT switch is fully ON (saturated)?
The Base Current (IB) must be greater than the Collector Current (IC) divided by 10 (typically): IB>IC/10
How does a designer confirm a MOSFET switch is fully ON (closed)?
The Gate-Source Voltage (VGS) must be greater than the turn-on voltage (VGS(ON)),,. When closed, the drain to source acts like a small resistor, RDS(ON)
What type of diode is used to create a reference voltage?
Zener diodes are used in reverse bias where they get "stuck" at their breakdown voltage (VZ), providing a fixed, predictable voltage reference
What type of diode is chosen when low forward voltage drops are required?
Schottky diodes are chosen because they have a smaller forward voltage drop (typically ~0.4 V) and are useful for fast switching and efficient power applications
Where must decoupling capacitors be placed on a PCB?
They must be placed immediately next to the pin that requires it
What property is crucial for a decoupling capacitor used to filter out very high frequencies?
It must have a low equivalent series inductance (ESL)
Why is a capacitor's value often not static (e.g., noted as "1 uF")?
The capacitance value changes with frequency and temperature
What are the key trade-offs between Ceramic and Aluminum Electrolytic capacitors?
Aluminum electrolytic capacitors typically have larger capacitance values, but also exhibit higher ESL (Equivalent Series Inductor) and ESR (Equivalent Series Resistor),,,. Ceramic capacitors have lower values but much lower ESL and ESR
Why would a designer choose a higher E-series resistor (e.g., E24)?
A higher E-series is chosen when the system specifically requires values resistors to achieve design performance
What are E-Series values and why are they used for resistors?
E-series values are standardized resistor, capacitor, and inductor values defined logarithmically to ensure that the percentage error is guaranteed to be within a specific tolerance, balancing tolerance and cost