ZloUSB

ZloUSB is an HID keyboard emulator for keystroke injection and script automation inspired by the USB Rubber Ducky and the MalDuino. I created this as a project to teach myself PCB schematic design and layout with Altium.

Key Features & Specifications

CategoryDetails
MicrocontrollerRaspberry Pi RP2040
Flash Memory16 MB (128 Mbit) Winbond W25Q128JVSIQ SPI Flash
ConnectivityDual USB-A and USB-C (USB 2.0 Full-Speed @ 12 Mbit/s)
User Controls3 tactile buttons: \(\overline{\text{USBB}}\) (firmware upload), \(\text{RST}\) (manual reset), and \(\text{INJ/}\overline{\text{UPL}}\) (Injection / Script Upload)
Diagnostics2 status/debugging LEDs
PCB Form Factor4-layer ultra-compact USB stick layout, 40.0 mm x 20.0 mm

Hardware Design & Engineering Constraints

The primary constraints for this build were miniaturization and low-cost fabrication and assembly:

  • To leverage the cost-effective single-sided automated assembly of JLCPCB, the component selection was tightly filtered around JLCPCB’s Basic / Preferred Components library to avoid extra fees.
  • Since budget constraints restricted SMT assembly to a single side, components required on the bottom layer were upscaled to larger footprints to enable manual post-assembly soldering.
  • The USB-A and USB-C connectors had to share the power line and the USB 2.0 D+/D- differential pair, whilst achieving identical trace lengths and \(90\,\Omega\) differential impedance.

Schematics

USB Interface & Power

USB Schematic

RP2040 Core

Core Schematic

3D Renders

Top ViewBottom View
Top 3D ViewBottom 3D View

PCB Layout

LayerDescriptionImage
L1 (Top)Signal - USB, RP2040, LEDs, buttonsTop Layer
L2 (GND)GroundGround Layer
L3 (PWR)Power - 3V3, 5V VBUSPower Layer
L4 (Bottom)Signal - flash memory, voltage regulatorBottom Layer Mirrored

Bottom Layer

Top and Bottom Layer