241 Minimal MCU Board
241-minimal-mcu-board.mc describes a generic 3.3 V MCU board core. Its purpose is to show how a local MCU component, a supply rail, decoupling capacitors, reset support, and a small debug-style header fit together.
Functional blocks:
PWRcreates the local 3.3 V source and ground reference.GENERIC_MCUis a small local component with explicitVCC,GND,RESET_N,DBG_IO, andDBG_CLKpins.C_MCUis a 100 nF local decoupling capacitor andC_BULKis a 4.7 uF nearby bulk capacitor.R_RESETpulls the active-low reset net up toV3V3.J_DEBUGexposesV3V3,GND,RESET_N,DBG_IO, andDBG_CLKon a five-pin header.
Power flows from PWR.1 to V3V3, then to U_MCU.VCC, both capacitors, the reset pull-up, and header pin 1. PWR.2 creates GND, shared by the MCU, capacitors, and header pin 2. RESET_N, DBG_IO, and DBG_CLK are named board nets. RESET_N is pulled high by R_RESET, connected to U_MCU.RESET_N, and also exposed on the header; the two debug nets run from the MCU to the header without claiming a specific debug protocol.
This recipe composes patterns from earlier chapters rather than introducing a new board abstraction. The local component shape follows 03-define-components-and-interfaces/031-named-pins-component.mc; the pull-up pattern follows 21-digital-io-recipes/212-button-input.mc; the decoupling pattern follows 00-getting-started/003-decoupling-capacitor.mc and 04-functions-and-reuse/044-decoupling-library-method.mc; the header style follows 22-interface-recipes/221-uart-debug-header.mc.
Important omissions: this is not a specific commercial MCU reference design. It does not model oscillator requirements, boot straps, reset timing, regulator sequencing, programming protocol details, ESD protection, or all power pins that a real MCU package may need. The capacitor and resistor values are illustrative only.
Parse 241-minimal-mcu-board.mc:
eval "$(../mcc/scripts/mcc-slot.sh)"
MCC_SYSTEM_ROOT="$(cd .. && pwd)" "$MCC_BIN" --local parse 24-board-level-recipes/241-minimal-mcu-board.mc --lib mcode --pass1 --pass2Generate HTML for 241-minimal-mcu-board.mc:
eval "$(../mcc/scripts/mcc-slot.sh)"
MCC_SYSTEM_ROOT="$(cd .. && pwd)" "$MCC_BIN" --local parse 24-board-level-recipes/241-minimal-mcu-board.mc --lib mcode --viz -o 24-board-level-recipes/241-minimal-mcu-board.htmlSource
// Example: Minimal MCU Board
// Goal: Combine MCU power, decoupling, reset, and a small debug header.
// Library focus: DC, CAP.MLCC, RES, HDR.
component GENERIC_MCU
{
name = "Generic MCU"
pins = [
psnk [1,2] = [VCC, GND]
io 3 = RESET_N
io 4 = DBG_IO
io 5 = DBG_CLK
]
}
module main
{
io DBG_CLK
io DBG_IO
io GND
io RESET_N
io V3V3
DC.SRC PWR(3.3V, 200mA)
GENERIC_MCU U_MCU
CAP.MLCC C_MCU(100nF, 10V)
CAP.MLCC C_BULK(4.7uF, 10V)
RES R_RESET(10000R, 50V)
HDR.1X5 J_DEBUG
PWR.1 -> V3V3
PWR.2 -> GND
V3V3 -> U_MCU.VCC
U_MCU.GND -> GND
V3V3 -> C_MCU -> GND
V3V3 -> C_BULK -> GND
V3V3 -> R_RESET -> RESET_N
RESET_N -> U_MCU.RESET_N
V3V3 -> J_DEBUG.1
GND -> J_DEBUG.2
RESET_N -> J_DEBUG.3
U_MCU.DBG_IO -> DBG_IO
DBG_IO -> J_DEBUG.4
U_MCU.DBG_CLK -> DBG_CLK
DBG_CLK -> J_DEBUG.5
}