The Pincushion
SJSU Robotics
SJSU Robotics
My first assignment as a member of the SJSU Robotics Club was to design a PCB that would act as a controller for the drill of Alicanto, a robot designed for the URC competition in Utah. The stepper motor to be used was a Nema 40 V stepper motor, and the given specifications were to use SparkFun's MicroMod and a DRV8825 stepper motor driver. Through consistent iteration and review processes, the board was refined into the shown device (left) (and christened The Pincushion due to the number of grounding vias for surface-mount components). The board was essentially a specialized carrier for the MicroMod's modular ecosystem.
The power situation on the board was such that I had to manage 40V power for the motor and its driver, 5V power in from an external buck converter, 3.3V from the MicroMod itself (VCC), 3.3V output from the DRV8825, and USB power in. 40V was kept separate from other power and no high-speed signals were routed around or under the polygon. Traces for USB Vin and 5V power from the buck were reasonably thick, as were traces to decoupling capacitors. There was a power plane in the stackup, providing VCC to pins across the board that required it. The DRV's 3.3V was kept separate from VCC and only used for the chip's local reference.
This DRV_3V3 reference was only used to pull up the chip's own pins (eg sleep, reset) and as a high reference for setting the decay mode and clamping current with shunt resistors. Though the DRV is capable of handling higher current than the 0.4 A my team lead gave me as my target, I kept to specifications and calculated the necessary voltage divider to trigger the shunt resistors at approximately 0.4 A. Due to the stackup only having one GND plane, effort was made to cross signals at right angles when layer changes were necessary to avoid interference.
USB D+/D- and CAN bus were routed differentially with matched lengths over solid reference planes, and unused GPIOs and I2C pins were broken out into terminal blocks in case the team needed access to those later. A terminal resister was added to the CAN bus as well, but marked as DNP in both the schematic and the silkscreen so it would be an option but not required. All pads that had the option are in the hand-solder size for ease of assembly, and the board's dimensions and mounting hole locations are spaced at multiples of 5mm for the mechanical team's convenience.
Stackup: Signal - GND - Power - Signal
View schematic and layer-by-layer PCB below
Full Schematic, including design notes, updates, and VREF calculations
Top Layer (Signal - Red)
Second Layer (GND - Green)
Third Layer (VCC - Orange)
Bottom Layer (Signal - Blue)
*Since the completion of this design, I have learned a great deal more about PCB layout. Upon further reflection, the distance the USB differential pairs travels is far greater than it should be, and though it isn't detrimental for the relatively slow speed of USB-2, it would be improved upon had I done another rev. Further, signals were routed very close together for long stretches of distance, which for higher-speed signals would introduce crosstalk, but for this particular use case it did not have noticeable negative consequences.
**The use of netclasses in my schematic would have made it more readable, and the naming of voltage rails using labels rather than power flags did make the ERC complain a bit.
I intend to take these lessons into consideration as I pursue future projects. If you would like to connect professionally or otherwise, please refer to my contact information at the bottom of the home page→.