Skip to main content

Communication Protocols

The Modular Mechanica system uses several communication protocols to ensure seamless integration between components.

MMS-Link is the primary backbone protocol that connects all components in the system.

Physical Connection

MMS-Link uses an RJ45 connector with 8 pins:

PinFunction
1CAN2 Low
2CAN2 High
3Ground
4CAN1 Low
5CAN1 High
612V Standby
7USB D-
8USB D+

Communication Buses

The system supports multiple communication buses:

  1. CAN Buses - Two independent CAN buses (CAN1 + CAN2) for main communication
  2. USB Bus - For debugging, programming, and data transfer
  3. 12V Standby - Auxiliary power supply
  4. Ground - Common reference point

Topology

The MMS-Link protocol follows this topology:

Moducard Cards ↔ Backplane ↔ Adapter ↔ MMS Modules

Chainbus Protocol

Chainbus is the communication protocol between MMS modules and their hat modules.

Physical Connection

Chainbus uses a DIN41612 connector with 3 rows × 16 pins:

ROW A (16 pins):

  • Raw GPIO lines (Altmode1–Altmode16)

ROW B (8 pins):

  • Address lines (8× addr0–addr7)
  • Digital bus: I2C (SDA, SCL), SPI (CS, SCK, MOSI, MISO), UART (RX, TX)

ROW C (4 pins):

  • Power supply: GND, +5V, BRD_VIN, +12V stdby

Communication Modes

Chainbus Mode

  • Uses ROW B + ROW C
  • Standard communication with addressable hat modules
  • Supports I2C, SPI, UART protocols

Altmode

  • Uses all three rows (A + B + C)
  • Full GPIO access for advanced applications
  • Used primarily for VESC and Betaflight integration

Addressing System

The addressing system works through position-based selection:

  1. Address Lines: Each hat has one address line
  2. Chain Propagation: Addresses are passed through the chain with position-based addressing
  3. Selection Process: MMS activates addrN to select hat at position N

Example Communication Flow

  1. Step 1: MMS sets addr1 = active

    • Hat at position 0 sees addr1 (not addr0) – doesn't react
    • Hat at position 1 sees addr1 as addr0 – activates
  2. Step 2: MMS sends data via I2C/SPI/UART

    • All hats connected to same data lines
    • Only active hat receives and processes the data
  3. Step 3: MMS changes address to different value

    • New hat at different position becomes active
    • Previous hat is disconnected from communication

Protocol Comparison: Moducard vs MMS

FeatureModucardMMS
Communication MediumBackplane and MMS-LinkChainbus and MMS-Link
Main FunctionsCPU, PSU, microcontrollersPeripheral modules (sensors, drivers)
Primary ProtocolCAN busesChainbus protocol
Physical ConnectionDIN41612 connectorsDIN41612 and RJ45
Role in System"Brain""Nerves" and "Muscles"

Integration Between Systems

The two systems work together through the MMS-Link protocol:

  1. Moducard cards communicate with MMS modules via MMS-Link
  2. MMS modules connect to cards using CAN buses
  3. Communication flows through the backplane to the central unit
  4. Data exchange between systems is seamless and transparent

This architecture allows for:

  • Easy debugging and prototyping from external computers
  • Full system visibility as ROS topics
  • Ability to control robots from anywhere in the world via WiFi
  • Transparent system operation with no hidden complexity