# Get Started The SANPO integrated robot controller is designed for robots, robot dogs, and robotic arms. It integrates USB and SPI data inputs, CAN/RS485 motor interfaces, and sensor interfaces. ## Introduction - The board integrates 2 STM32F4 modules. Each module controls 2 CAN and 2 RS485 channels, for a total of 4 CAN / 4 RS485. - USB and SPI are supported as host control inputs, alongside IIC, ADC, and UART sensor expansion. - 5V/3.3V power outputs are provided for Raspberry Pi, Nvidia Jetson, and similar hosts. - Compatible with the MIT Cheetash SPINE hardware design standard. ![Board architecture](../../images/taobao-github-architect-1.1.png) ## Hardware ### Overall interface layout - The diagram below gives a full hardware interface overview of the controller board. - It includes host control interfaces (USB/SPI), motor communication interfaces (CAN/RS485), sensor expansion interfaces (IIC/ADC/UART), and power output pins (5V/3.3V). - Check this diagram first to identify pin locations and interface groups before wiring. ![Board interface diagram](../../images/taobao-github-architect-1.2-2.png) ### USB connection (PC/host) - With USB as the control input, you can verify motor communication using debugging tools on a PC. - USB supports both CAN and RS485, suitable for quick validation. ![USB wiring](../../images/taobao-github-usb-2.1.1.png) ### SPI connection (Host controller examples) - For SPI control, CS1 maps to STM32F4(1) and CS2 maps to STM32F4(2). - Jetson Nano and Raspberry Pi are example hosts only. Other controllers use the same SPI wiring as long as SPI pin mapping is consistent. #### 1. Jetson Nano wiring ![SPI wiring for Jetson Nano](../../images/taobao-github-spi-jetson-2.2.1.png) #### 2. Raspberry Pi wiring ![SPI wiring for Raspberry Pi](../../images/taobao-github-spi-pi-2.2.2.png) ## Software Recommended tools: - SANPO motor tool (multiple motor types): Sanpo Studio Motor Tools - Xiaomi motor tool (USB to CAN): [Xiaomi CyberGear Tool](../../tools/CyberGear.zip). Note: avoid Chinese characters in the install path. - Unitree motor tool (USB to RS485): [Unitree GOM8010 Tool](../../tools/UnitreeMotor.zip) ## Build Your Program Protocol definitions and examples: - [USB to CAN](usb_can) - [USB to RS485](usb_rs485) - [SPI to CAN](spi_can) - [SPI to RS485](spi_rs485) - [Offline Auto Execution](batch_programming.md) ## Advanced For custom firmware and protocol development, start from the official firmware: - Official firmware (for customization): [STM32CubeIDE project](https://gitcode.com/sanpo/robot/tree/v4/firmware/STM32CubeIDE) - MIT Cheetash SPINE firmware (for study): [MBED STUDIO project](https://gitcode.com/sanpo/robot/tree/v4/firmware/mit_cheetash_spine) For firmware updates, see [Firmware Update](firmware_update): - Connect STLINK to the SWD interface of each STM32F407. - Flash the latest firmware using STM32CubeProgrammer. - Each STM32F407 must be flashed separately.