I’ve been working on installing a Mellow FLY-UTOC-3 and the FLY-SHT42 Toolhead on a CoreXY printer and I have some things I would like to pass along that should make things easier for other people and I have some questions that I’m going to ask here and follow up with Mellow on their Facebook page.
The reason for this long post is because there are a number of pages regarding these products and none seem to be complete and there are some questions that need to be addressed.
At the end of this post, I have a number of questions, most of which are probably more appropriate for Mellow but I am having problems reading thermistors that I would like to be considered here.
You can see (and buy) the Mellow CAN bus boards from AliExpress here:
https://www.aliexpress.com/item/1005004048980837.html
My installation should be pretty standard; I’m connecting the UTOC board to a Raspberry Pi 4B (“rPi” below) using USB and then connecting the FLY-SHT42 to the UTOC using a custom cable which consists of the two CAN wires and 12/24V and Gnd. What is described here should be work with the FLY-SHT36 without modification.
I am using a FLY-UTOC-3 board but the FLY-UTOC-1 board should be identical, although I do have a question for the FLY-UTOC-3 board and where to put the terminating resistors (see the questions below).
Installation Steps:
-
Mount the FLY-UTOC board into the 3D printer. There doesn’t seem to be any need to build/load new firmware as what comes with the board seems to be fine (see the questions below)
a. Connect the FLY-UTOC to the rPi using USB
b. Wire 12V/24V and Gnd from your bulk AC/DC supply to the FLY-UTOC
c. Make up your CAN cable. I used the white connectors that come with the FLY-UTOC and FLY-SHT42 wiring “H” to “H”, “L” to “L”, “VCC” (+12/24V) to “VCC” and “GND” to “GND”. NOTE that the “H”/“L” wires should be twisted (for some reason, this is never mentioned in other set up instructions) -
Build and load Klipper (with CAN interface) onto the FLY-SHT board using DFU.
a. Insert the DFU jumper into the FLY-SHT board
b. Connect the FLY-SHT board to the rPi using USB
c. SSH into the rPi
d. Using SSH, execute the command:
make clean
e. Using SSH, execute the command “make menuconfig” and set up the following screen:
Press “Q” to quit and then “Y” to save the changes
f. Using SSH, execute the command:
make
g. Using SSH, load the Klipper firmware into the FLY-SHT board using the command:
sudo dfu-util -a 0 -d 0483:df11 --dfuse-address 0x08000000 -D ~/klipper/out/klipper.bin
h. Unplug the FLY-SHT board from the rPi
i. Remove the DFU jumper
- On the rPi, create the “can0” interface file with the command:
sudo nano /etc/network/interfaces.d/can0
and put the following into the file
auto can0
iface can0 can static
bitrate 500000
up ifconfig $IFACE txqueuelen 1024
Note that the “bitrate” and “up ifconfig” lines are indented from the “auto can0” and “iface can0…” statements.
When done, Ctrl-X to end and then “Y” to save - make sure you don’t change the file
-
Connect the FLY-SHT board to the UTOC board using the CAN cable.
-
With the 12/24V bulk supply on, test the connection using the following commands.
First, enable CAN bus and set the datarate:
sudo ip link set up can0 type can bitrate 500000
Next, query the devices on the CAN bus - you will need the “canbus_uuid” shown for setting up your printer.cfg to use the FLY-SHT board:
~/klippy-env/bin/python ~/klipper/scripts/canbus_query.py can0
Finally, test the CAN bus to see if communications is working:
ip -s link show can0
If everything is set up correctly, you should see something like:
- Update your printer.cfg file to communicate with the FLY-SHT board using CAN and the UTOC board. This requires an additional “mcu” statement like:
[mcu canFly]
#Mellow FLY SHT42
canbus_uuid: < uuid >
In the “mcu” statement above “< uuid >” is the UUID of the FLY-SHT board (“aac33b9bb830” for my board as can be seen in the terminal screen shot above).
- In the “extruder” section of printer.cfg (where you have put in your hot end thermistor) add the statement:
pullup_resistor: 2200
From here, you should be able to connect once your restart Klipper and get something like this information in the “MACHINE” tab in Mainsail:
- Now, you can configure your printer with the Toolhead board as required.
Questions:
-
Where do you place the terminating resistors on the FLY-UTOC-3 board when using the white connector? There seems to be two separate CAN bus drivers on the board and I’m not sure which is which. I guess I could just put them on both sets and not worry about it, but if somebody had an answer, that would be appreciated.
-
How do you check the version information on the UTOC board firmware? In the Mainsail screen shot above there is no UTOC version information - just that for the controller board and the FLY-SHT board. In the Mellow online reference (link below) it says that the UTOC version cannot be older than 2.9 but I have no idea how to check.
https://mellow.klipper.cn/#/advanced/can -
Where is the location for the best UTOC firmware and how is it built? I’ve found three different versions that are claimed to be the latest and tried them but I don’t see any difference in their operation.
-
What exactly is CanBOOT? It seems to facilitate FLY-SHT firmware updates but I’ve loaded the FLY-SHT boards with Klipper and that seems fine.
-
Looking at the schematic, there doesn’t seem to be an available input for the X-Axis endstop. I’m guessing I could do a fly wire from the RGB LED connector into an “ENDSTOP” pin, but I’m wondering if anybody has a better idea?
The FLY-SHT schematics are here:
https://github.com/Mellow-3D/Klipper-CAN-Toolboards/blob/main/FLY-SHT42/Hardware/Schematic_42CAN_2022-10-31.pdf -
My final question is for Kevin or Sineos: When I put a 100k B3950 thermistor on the FLY-SHT board at the “TEMP” connector (see the schematic above), the temperature is way off - when I expect 20C or so (and I can verify it using a DMM and checking the actual resistance) I get 4C.
I have warmed up the thermistor and I can see the temperature rise, but the base temperature seems to be calculated incorrectly. I’m using “Generic 3950” as my sensor type (and I have tried others with the same result). The pull up on the port is 2.2k with a 1k inline terminating resistor which doesn’t seem out of place, but the readings don’t match with what I expect.
Any comments?
If you’ve read through this, I hope it hasn’t been too much of a chore and hopefully the set up instructions will help somebody in the future.
I appreciate any comments to the content and answers to the questions.
2022.11.08 EDIT
I’ve made a couple of changes to this post in relation to answers I’ve received.
-
The can0 file to be loaded in the rPi has been changed to increase the “txquerylen” and remove the “pre-up” statements which are not required. This is based on statements on the Mellow 3D Discord group.
-
I’ve added the “pullup_resistor: 2200” statement in the printer.cfg specification to fix the issue where the thermistor read values were incorrect.
I’m still looking for an answer to my question about how to set the terminating resistors on the FLY-UTOC board.