Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

95 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

P2-vs-RPi-RobotDog-FNK0050

Project Status Platform Maintainer License

One of the things I really enjoy doing is finding robotic platforms with a collection of servos and actuators and sensors that look like they'd be fun to control and might be a good challenge for me to expand my skills in programming the P2. When I find these platforms, I look at how they're set up and how compatible they might be. In this case, this was driven by a Raspberry Pi, so I know the interface is going to be pretty easy to adopt when it comes to taking out the Raspberry Pi and replacing it with a P2.

This project is exactly that: the record of me doing this work of replacing a Pi with a P2 and then building the code around it. I built this so you can follow along and play and even use the code if you wish for experiments on your own.

-Stephen

Freenove FNK0050 Robot Dog with the Parallax P2 Edge Module mounted where the Raspberry Pi used to sit

The FNK0050 Robot Dog with the Parallax P2 Edge Module mounted in place of the Raspberry Pi — the "P2 EDGE" module and chip are visible on top.

Porting the Freenove Robot Dog Kit (FNK0050) from its stock Raspberry Pi controller to a Parallax Propeller 2 (P2). The P2 — on an Edge Module + breakout board carried by a custom adapter plate — drops into the spot where the Pi normally sits and mates to the connection board's 40-pin header.

The goal: drive the same robot hardware (13 servos, IMU, battery ADC, ultrasonic sensor, buzzer, and WS2812 LEDs) from P2 firmware instead of the Pi's Python stack.

This build uses connection board PCB v1.0 — so the WS2812 LED data line is on GPIO18 (the rpi_ws281x path), not the SPI0/GPIO10 path used by PCB v2.0.

Why the P2?

The Freenove design puts almost everything on I²C behind driver chips (PCA9685 servo controller, ADS7830 battery ADC, MPU6050 IMU), so most of the port is "implement an I²C master on the P2." Only three peripherals use discrete GPIO — the buzzer, the HC-SR04 ultrasonic sensor, and the WS2812 LED strip — and each maps naturally onto a P2 smart pin. See the wiring map for the full breakdown.

Repository layout

Path Contents
DOCs/ Project documentation — pin usage, the P2 migration wiring map, mounting hardware CAD, and supporting images/sources.
src/ P2 firmware (Spin2 / PASM2) — work in progress.
REF/ Upstream Freenove FNK0050 Raspberry Pi code, kept locally for porting reference. Git-ignored — not part of this repo's deliverables.

Documentation

Start here when planning or executing the hardware swap:

  • DOCs/P2-platform/ — the physical-platform hub: the build walk-through (model/print the adapter plate, assemble the P2 board onto it, mount it on the robot), the wiring map (power architecture, the 3.3 V provenance gotcha, the header→P2 map, and the 3.3 V-vs-5 V hazards — the P2 is not 5 V tolerant), and the adapter-plate CAD (DXF + 3MF).
  • DOCs/RPI_GPIO_USAGE.md — the stock Pi pin/bus usage, reverse-engineered from the Freenove server source (no schematic exists). Device inventory, I²C addresses, servo channel map, and which signals ride raw GPIO.

Hardware reference

  • Kit: Freenove Robot Dog Kit for Raspberry Pi (FNK0050) — https://docs.freenove.com/projects/fnk0050/en/latest/
  • Controller (new): Parallax Propeller 2 Edge Module + breakout board.
  • Power: 2× 18650 Li-ion (2S), externally charged; the connection board's regulator delivers 5 V to the controller. See the wiring map for details.

Status

Early-stage. Documentation and mechanical/electrical planning are in place; the P2 firmware in src/ is under development.

Possible future directions

These are candidate directions for after the current port is fully bench-certified — the remaining items are not committed or in progress, and the current firmware does not depend on any of them. Each is an input that posts into the existing cog-0 command mailboxes, so the motion engine needs no change. Full detail — hardware candidates, interfaces, and P2-integration notes — is in DOCs/FUTURE-DIRECTIONS.md.

  • Speech recognition (✅ implemented in build 0.3.0) — spoken commands ("sit", "shake", …) via a DFRobot DF2301Q offline recognizer on a 2nd I²C bus, feeding the cog-0 command mailboxes. The dog is named Peabody (wake phrase "Hello Peabody"); see the release notes and DOCs/subsystems/VoiceSensor/.
  • Pan/tilt head + vision AI camera (longer-term) — replace the tilt-only head with a pan/tilt mount + an I²C AI camera that reports what it sees (follow / look-at / find).
  • P2 native audio output (longer-term) — real barks / speech via the P2's smart-pin DAC/PWM, beyond today's buzzer.
  • Bluetooth remote commanding (longer-term) — a wireless link (SPI / I²C) driving the same mailbox command set; the first real "comms cog 0".

License

MIT License - See LICENSE for details. © 2026 Iron Sheep Productions, LLC.

Note: the upstream Freenove reference material under REF/ (git-ignored) is released by Freenove under CC BY-NC-SA 3.0 and is not covered by this repository's license.


Part of the Iron Sheep Productions Propeller 2 Projects Collection


Releases

Contributors

Languages