
Designing the vehicle control unit for a solar powered car.
Overview
The Sunstang VCU 2026 is a custom vehicle control unit PCB developed in KiCad. It brings driver inputs, pedal interfaces, high-voltage enable logic, lighting control, safety interlocks, and vehicle state management into one low-voltage control system.
The board is built around the STM32 Nucleo-F302R8. Its central engineering challenge was not simply connecting signals to a microcontroller; it was creating a dependable boundary between sensitive 3.3V logic and the car's 12V electrical system. Every input and output had to be considered in terms of voltage level, failure behavior, connector access, and how it would be diagnosed once installed in the vehicle.

High-Level Diagram
Functional Responsibilities
1. Power & HV Control
- · LV switch interface
- · HV switch interface
- · Pre-charge button input
- · Pre-charge contactor feedback
- · Main contactor feedback
- · HV active indication
- · BMS interface signals
2. Driver Inputs
- · Accelerator pedal (ADC input)
- · Brake pedal (ADC/digital input)
- · Brake light trigger output
3. Mode Control
- · Ready mode switch
- · Charge mode switch
- · Mode select (SPDT)
- · Gear selector (SPST)
4. Lighting Control
- · Brake lights
- · Daytime running lights
- · Left turn signal
- · Right turn signal
- · Hazard lights
- · Rear signal outputs
5. Safety Inputs
- · HV active confirmation
- · Thermal shutdown
- · Pre-charge verification before main contactor closure
Turning vehicle requirements into a circuit
As part of the Driver Controls Team, my main task was to build the PCB for the vehicle control unit. Its main role is to know what the driver was requesting, whether the high-voltage system was ready, and which outputs could be enabled safely. I grouped those requirements into power and contactor control, driver inputs, mode selection, lighting, and safety feedback. That list became the architecture of the board.
This approach made each signal answer the same questions: where does it originate, what voltage can appear on it, what should the STM32 see, and what must happen if the signal is missing or invalid? Thinking in signal paths kept the design grounded in the actual vehicle instead of treating the PCB as an isolated electronics exercise.
Building the schematic in KiCad
We used KiCad because it is open source and easy to learn. There was also a legacy version of the old board that we were improving on top of. The hardest part was making sure all the parts and logic were correct and at the right values.

Placement before routing
There were a lot of iterations that were made before the final decision. It was important to think physically where everything was routed for the driver to easily understand as well.
Therefore, the component placement had to be treated as a system problem. Connectors had to match how the board would be wired and serviced. Interface components needed to remain close to the signals they protected or conditioned. The Nucleo headers needed enough space for assembly while still keeping related signal paths short and understandable.
I repeatedly moved functional groups until the board reflected the same flow as the schematic: vehicle connection, interface circuit, then controller. That reduced unnecessary crossings and made the final routing easier to inspect. It also left a more useful visual map for debugging because a physical area of the board corresponds to a specific vehicle function.

Routing for clarity and reliability
Routing was a balancing act between electrical priorities and readability. I routed power and higher-current output paths first, then sensitive analog pedal signals, and finally the remaining digital control lines. Keeping those categories visually distinct helped avoid long parallel runs between noisy outputs and measurement signals.
I also paid close attention to return paths, trace length, and the number of layer changes. A short-looking trace is not necessarily a good trace if its return current has to take a complicated path. Reviewing the board by functional loop, rather than one net at a time, made it easier to identify routing that could become fragile or difficult to diagnose.
The final pass was deliberately methodical: verify connector pin order against the harness, confirm net classes and clearances, run KiCad's electrical and design-rule checks, and inspect each circuit against the schematic. Only after those checks did the layout feel ready to move from a screen to a manufactured board.

A special thanks
I wanna give a special thank you to Xiuting Shi for teaching and mentoring me through the whole process. From explaining what a MOSFET is, to finalizing the design, thank you.