Design PI current controllers in the frequency domain for AC electric machine drives. Features stability analysis, Bode plots, and embedded C-code generation. Supports EESM, IPMSM, and Induction Motors.
Launch App »
A practical engineering calculator covering motor control, power electronics, embedded firmware, thermal analysis, and EV propulsion. Includes PMSM/IPMSM/EESM torque models, SVPWM, PI controller design, Buck/Boost converters, thermal rise, and road load calculations.
Launch App »
A hands-on introduction to GPIO output and digital signals. Wire up an LED, write a Python script, and control it directly from the Pi's GPIO pins, the classic starting point for hardware programming.
Beginner
GitHub Repo »
Use Pulse Width Modulation to smoothly control LED brightness from software. A practical demonstration of how PWM bridges the gap between digital outputs and analog-like control, which is the basis for motor drives and power converters.
Beginner-Intermediate
GitHub Repo »
Read real DC/AC current using an ACS712 hall-effect sensor and the ADS1263 32-bit ADC HAT over SPI. Covers differential measurement, SPI communication, and converting raw ADC counts to engineering units.
Intermediate
GitHub Repo »
A complete closed-loop PI current controller running on the Pi. The D4184 MOSFET switches a resistive load while the ACS712 feeds current feedback, a real-world demonstration of the same control loop used in industrial power electronics.
Intermediate-Advanced
GitHub Repo »
A finite-horizon constrained Model Predictive Controller on the same MOSFET and ACS712 hardware as project 04. Identifies the plant model online from a step test, precomputes the optimal gain matrix, and runs a full constrained optimization at ~480 Hz with no manual tuning required.
Advanced
GitHub Repo »
Receives the F28388D controlCARD ADC stream over a direct point-to-point Ethernet link and renders it as a live oscilloscope. ADCINA0 is sampled at 10 kHz on the controlCARD and shipped in 50-sample UDP packets at 200 packets/s, holding zero loss over multi-minute windows. The Pi runs a threaded UDP listener feeding a bounded ring buffer, exposed through two consumers: a CLI sniffer for bring-up diagnostics, and a Streamlit + Plotly dashboard with live KPIs (current, mean, min, max, RMS, packet rate, loss %, link uptime), pause toggle, and CSV export. The binary packet parser is the single source of truth, hand-aligned byte for byte against the firmware sender.
Advanced
GitHub Repo »
Pi-side command and visualization host for the F28388D synchronous-frame current controller on a BOOSTXL-3PhGaNInv 48 V GaN inverter. Over a direct point-to-point Ethernet link, the Pi sends binary command packets at 200 Hz carrying Idref, Iqref, electrical-frequency reference, plant parameters (Rs, Ls, target loop bandwidth) and enable/reset flags, while the controlCARD streams 5 kHz telemetry back on a second UDP port. A four-panel Streamlit + Plotly dashboard renders Id/Iq reference versus measurement, the three phase currents, and DC-bus voltage with electrical angle at 100 ms refresh, alongside a live status decoder for enable, overcurrent, over/under voltage and Ethernet-watchdog flags. The IMC-tuned Kp/Ki preview is recomputed in the browser before any new gain set is committed to the firmware, and CRC-16-CCITT validates every command and telemetry packet against the firmware-side wire definition.
Advanced
GitHub Repo »
Hardware bring-up verification for the TMDSCNCD28388D controlCARD. Blinks the onboard D1 LED at 1 Hz via GPIO31, confirming the clock tree, GPIO subsystem, and JTAG debug connection are all working before any application firmware is deployed.
Beginner
GitHub Repo »
Generates three-phase Space Vector PWM at 20 kHz on the BOOSTXL-3PHGANINV inverter board using ePWM1/2/3 with dead-time insertion. The ADC fires synchronously at the PWM carrier peak to sample at the minimum current ripple point, while a dedicated CLA task reads the result in parallel with the main CPU. Sector, duty cycles, and ADC data stream to UART at 10 Hz.
Intermediate–Advanced
GitHub Repo »
A 20 kHz PI current controller running entirely on the F28388D CLA coprocessor, leaving the main C28x CPU free for reference generation and UART telemetry. Gains are designed from bandwidth targets (ωc = 2π×1000 rad/s) and discretised in incremental form, giving natural anti-windup with no extra logic. The CLA task finishes in under 2 µs, triggered by the ADC conversion complete interrupt, and writes the new duty cycle to shared message RAM for the ePWM ISR. A companion Python script reads 10 Hz serial telemetry and plots the measured Bode response against the theoretical open-loop curve.
Advanced
GitHub Repo »
Hardware overcurrent protection for a GaN inverter leg using the F28388D CMPSS and ePWM Trip Zones. The comparator checks phase current against ±8 A thresholds entirely in hardware, tripping ePWM1 outputs to zero in under 100 ns with no CPU involvement. A 32-sample digital filter blanking window rejects switching transient noise. Both CBC and OST trip modes are supported, a Trip Zone ISR logs fault events in a 16-entry circular buffer, and 10 Hz UART telemetry streams current and fault data at 115200 baud. A software fault injection test runs automatically on startup to verify the protection path end to end.
Advanced
GitHub Repo »
Dual-core firmware that turns the F28388D into an Ethernet-attached scope front-end. The C28x CPU1 samples ADCINA0 at 10 kHz (ePWM1 SOCA triggering ADC-A SOC0), converts each result to volts, and publishes into a 128-deep float ring in shared MSGRAM. The Cortex-M4 Connectivity Manager runs lwIP NO_SYS on the on-chip Ethernet MAC at static IP 192.168.10.10, polls the ring on a 1 ms SysTick, and packs 50 samples per UDP datagram at 200 packets/s. CPU1 boots the CM core via Device_bootCM in the strict flash order required by the F2838x dual-core protocol. Verified end to end against a Raspberry Pi receiver with zero packet loss over multi-minute windows.
Advanced
GitHub Repo »
Field-oriented current controller for a three-phase RL load, driven by the BOOSTXL-3PhGaNInv 48 V GaN inverter and commanded over Ethernet by a Raspberry Pi 4. The C28x CPU1 runs a 20 kHz Clarke → Park → two decoupled PI loops → inverse Park → min/max common-mode-injection SVPWM pipeline inside the ADCA1 EOC ISR, with IMC pole-zero gains (Kp = 2π·fbw·Ls, Ki = 2π·fbw·Rs), back-calculation anti-windup, and feed-forward cross-axis decoupling. INA240 phase-current sense and DC-bus voltage are sampled at the ePWM carrier valley, an auto-calibrated zero-current offset is subtracted, and a hardware safety layer (overcurrent, over/under voltage, Ethernet watchdog) forces the CMPA triplet to 50% and arms an ePWM Trip Zone one-shot on any fault. The Cortex-M4 core runs lwIP NO_SYS on the on-chip EMAC at static IP 192.168.10.10, terminating two UDP sockets (command on 5001, telemetry on 5002) and bridging them to CPU1 through two unidirectional MSGRAM mailboxes. Wire packets are CRC-16-CCITT protected and little-endian aligned so the C28x 16-bit char side and the M4 8-bit char side see the same layout. The ISR pipeline closes in ~4.5 µs of the 50 µs switching period, leaving more than 9× CPU headroom.
Advanced
GitHub Repo »
Crystal-clear animation showing how SVPWM builds its 7-segment inverter switching pattern from a rotating voltage reference vector.
0:59
Watch » GitHub »
Visual walkthrough of the Clarke (αβ) and Park (dq) transforms that sit at the heart of field-oriented motor control.
0:58
Watch » GitHub »
Animation showing how d-axis and q-axis current decoupling works in PMSM field-oriented control and why it is essential for independent torque and flux regulation.
Watch » GitHub »
Simulation showing how a PLL-based observer tracks the back-EMF angle in a PMSM as speed approaches zero, highlighting phase error and loss of lock near standstill.
Watch » GitHub »
A new 800 V traction inverter from Fraunhofer IZM packs 500 kW of three-phase output into a single liter of volume, with peak efficiency above 99%. The trick is embedding twelve SiC MOSFETs directly into the PCB for each half-bridge, which collapses commutation-loop inductance to roughly 1 nH and lets the switches slew at 65 V/ns. The result is about five times the power density of current production traction inverters, and 2.5 times the previous research benchmark. Built for Mitsubishi Heavy Industries, the unit will be shown publicly at PCIM Europe in Nuremberg on June 9 to 11, 2026.
May 2026
Read More »
A landmark review in the IEEE Open Journal of Industry Applications maps how machine learning, from deep neural networks to reinforcement learning, is transforming speed and torque control, fault detection, and thermal monitoring in electric machine drives. The survey covers PMSM, induction, and switched-reluctance machines, and is now a go-to reference for engineers working at the intersection of AI and power electronics.
May 2026
Read Paper »
Silicon carbide is quietly changing what is possible in EV drivetrains. Fourth-generation SiC MOSFETs push inverter efficiency past 99% and cut heat generation by half compared to standard silicon. The practical outcome is 400 km of range added in under five minutes, making 800V architecture the benchmark for serious EV platforms in 2026.
Apr 2026
Read More »
For years, solid-state batteries were always just around the corner. That is starting to change. Mercedes-Benz has integrated a lithium-metal solid-state cell into a real vehicle platform, Rimac demonstrated a pack charging from 10 to 80% in six and a half minutes, and production targets for 2026 are no longer just ambitions on a roadmap. With energy densities reaching 375 Wh/kg, the gap between today's lithium-ion and solid-state is closing fast.
Mar 2026
Read More »
A 2026 Nature Scientific Reports study proposes a Multi-Device Interleaved DC-DC Bidirectional Converter with a novel TIFDNFD-SFOA controller for simultaneous speed and voltage regulation of BLDC motor drives, which fills a critical gap in EV drive efficiency that most existing studies overlook.
Jan 2026
Read Paper »
A 2026 peer-reviewed study benchmarks FOC, DTC, model predictive control, and AI-enhanced frameworks for PMSM, IM, and BLDC traction drives, evaluating efficiency, dynamic response, and scalability for next-generation EVs.
Dec 2025
Read Paper »Control Software Engineer specializing in electric machine drives, inverter systems, and automotive control software.
Plan22 is where I share engineering tools, Python simulations, and hands-on hardware projects built at the intersection of control theory, power electronics, and EV systems.
For inquiries or collaboration, drop me a line or fill out the form below:
info@plan22.net