Skip to main content

CAN Bridge

CAN bus is a serial communication protocol bus used for real-time applications, which can transmit signals over twisted pair cables and is one of the most widely used field buses in the world. The CAN protocol is used for communication between various different components in a car to replace expensive and cumbersome wiring harnesses. The robustness of this protocol has extended its use to other automation and industrial applications. The characteristics of the CAN protocol include complete serial data communication, providing real-time support, transmission rates up to 1Mb/s, and features such as 11-bit addressing and error detection. On 3D printers, CAN bus is used to reduce the number of wires connecting the print head to the main board; originally requiring dozens of wires, with CAN only four wires are needed, greatly reducing the number of wires and simplifying wiring. This chapter provides only a brief overview of using the CAN bridge.

Tool Board Connects to Main Board via CAN

  • Note that the tool board power line is not connected to the CAN port but to the 12V-24V power line.
  • Note that the 120Ω jumper must be connected.

Flashing Main Board Firmware

  • Ensure that the firmware burned on the D5 main board is the USB Bridge CAN Firmware Configuration

Searching for ID

Search USB Tutorial

Precautions Before Searching for Devices

  • Please connect to SSH before searching for the USB ID (Connect to SSH)
  • Note that you must log in to SSH via the network rather than via serial port
  • Ensure that the mainboard with the flashed USB firmware is properly connected and that the data cable connecting it to the host computer has data transfer capability

Search for Devices

  • Ensure that the host computer can access the internet normally and that the data cable connecting the peripheral device to the host computer has data transfer capability.
  • After connecting to the host computer via SSH, enter lsusb and press Enter. If the information circled in the following image appears, you can proceed to the next step.
    • If there is no feedback, this indicates a problem with the host computer's system, and we are unable to assist; you need to replace the system with one that is confirmed to be working or replace the host computer.
    • If the instruction lsusb is not found, you can execute the following command to install it:
      sudo apt-get install usbutils
  • 1d50:6177 is the device you will be using for this task. The suffix OpenMoko, Inc. stm32f407xx is somewhat indicative but should not be used as a basis for judgment.
    • Some host computers may display incomplete or no information due to system issues.
    • If the lsusb command displays the device but does not show 1d50:6177, try changing the data cable and connecting the mainboard to another USB port on the host computer.
  • If you have previously executed the above steps and successfully burned the Klipper firmware, and the mainboard is running normally, but you just want to update the Klipper firmware, refer directly to the Firmware Update section in the right-hand menu of this page.
Precautions

You must query the 1d50:6177 device before proceeding to the next step.

Search for USBID

ls /dev/serial/by-id/*
  • Enter the command below and press Enter. If everything is normal, a blue ID will appear. (The ID below is for reference only)
  • If no ID appears after entering the command below, but lsusb shows devices, please replace the host computer or change the host computer system
Precautions

If multiple IDs appear, select the appropriate ID based on your mainboard's MCU model.

Fill in the USB ID into the Configuration

  • Open the printer web interface, find printer.cfg under the configuration options in the left sidebar: fluidd is {...}, mainsail is Machine, click to enter.

  • Copy the blue ID and paste it into the serial: field under the [mcu] section in the printer.cfg configuration file. After saving and restarting, the mainboard should be connected. If Klipper prompts ADC out of range, this is a normal phenomenon; connect the heated bed and thermistor properly, configure the thermistor and output pins for the nozzle and heated bed, then save and restart.

dangerous

Note: All IDs mentioned in the document are examples. Each mainboard's ID is different, so modify and fill in according to the actual ID obtained.