canopen-rust

A pure Rust CANopen stack built on top of can2040-rust — implementing the CiA 301 application layer for the RP2040.

Motivation

CANopen is the industry-standard higher-level protocol for CAN networks, widely used in industrial automation, robotics, and motor control. The Pizzaro robot needed a reliable CANopen stack to coordinate multiple RP2040 nodes — so I built one from scratch in Rust.

What it implements

The stack covers the core CiA 301 services:

  • NMT — Network management: node state machine, heartbeat, boot-up
  • SDO — Service data objects: configuration and parameter access
  • PDO — Process data objects: real-time data exchange between nodes
  • Object Dictionary — The canonical data model that all CANopen services operate on

Usage

As of July 2026, the crate has over 5,300 downloads on crates.io. It serves as the communication backbone for the Pizzaro robot, coordinating multiple RP2040 nodes over CAN bus in production.

Design

The stack is fully no_std and alloc-free where possible, with a modular design that lets you include only the services you need. Built on can2040-rust for the transport layer, it shares the same philosophy: zero C dependencies, idiomatic Rust APIs, and transparent operation.

Tech Stack

Language: Rust

Target: RP2040

Standard: CiA 301

Transport: can2040-rust

License: MIT / Apache 2.0