Cannot connect to serial port with direct breakout cable to Einsy Rambo


#1

What is the problem? Have connected Raspberry Pi to Einsy Rambo via port J19 and GPIO pins, and Octopi does not autodetect printer. Pi is seeing my network (wireless).

What did you already try to solve it? Have confirmed pinout and cable integrity (checked continuity of each lead, and checked connection to sockets). With several (many) attempts to add serial ports, I was finally able to get it to 'see' /dev/ttyAMA0, but it failed to connect to that. Further attempts to add serial ports (/dev/ttyS0) have gone unnoticed by system, despite saving and rebooting both Octopi and system.

Additional information about your setup OctoPrint v1.3.8, OctoPi v0.15.1, Custom-Built printer with Einsy Rambo board, RepRap Discount Smart Controller, Pi 3B, Marlin firmware, output on terminal tab (see below);

Connecting to: /dev/ttyAMA0
Changing monitoring state from "Offline" to "Opening serial port"
Connected to: Serial<id=0x744a6950, open=True>(port='/dev/ttyAMA0', baudrate=115200, bytesize=8, parity='N', stopbits=1, timeout=10.0, xonxoff=False, rtscts=False, dsrdtr=False), starting monitor
Starting baud rate detection
Changing monitoring state from "Opening serial port" to "Detecting baudrate"
Unexpected error while reading serial port, please consult octoprint.log for details: IOError: '[Errno 25] Inappropriate ioctl for device' @ comm.py:_readline:2417
Changing monitoring state from "Detecting baudrate" to "Offline (Error: IOError: '[Errno 25] Inappropriate ioctl for device' @ comm.py:_readline:2417)"
Connection closed, closing down monitor
Changing monitoring state from "Offline" to "Detecting serial port"
Serial port list: ['/dev/ttyAMA0']
Connecting to: /dev/ttyAMA0
Changing monitoring state from "Detecting serial port" to "Opening serial port"
Connected to: Serial<id=0x6eeec250, open=True>(port='/dev/ttyAMA0', baudrate=115200, bytesize=8, parity='N', stopbits=1, timeout=10.0, xonxoff=False, rtscts=False, dsrdtr=False), starting monitor
Starting baud rate detection
Changing monitoring state from "Opening serial port" to "Detecting baudrate"
Unexpected error while reading serial port, please consult octoprint.log for details: IOError: '[Errno 25] Inappropriate ioctl for device' @ comm.py:_readline:2417
Changing monitoring state from "Detecting baudrate" to "Offline (Error: IOError: '[Errno 25] Inappropriate ioctl for device' @ comm.py:_readline:2417)"
Connection closed, closing down monitor
Changing monitoring state from "Offline" to "Detecting serial port"
Serial port list: ['/dev/ttyAMA0']
Connecting to: /dev/ttyAMA0
Changing monitoring state from "Detecting serial port" to "Opening serial port"
Connected to: Serial<id=0x6eeec250, open=True>(port='/dev/ttyAMA0', baudrate=115200, bytesize=8, parity='N', stopbits=1, timeout=10.0, xonxoff=False, rtscts=False, dsrdtr=False), starting monitor
Starting baud rate detection
Changing monitoring state from "Opening serial port" to "Detecting baudrate"
Unexpected error while reading serial port, please consult octoprint.log for details: IOError: '[Errno 25] Inappropriate ioctl for device' @ comm.py:_readline:2417
Changing monitoring state from "Detecting baudrate" to "Offline (Error: IOError: '[Errno 25] Inappropriate ioctl for device' @ comm.py:_readline:2417)"
Connection closed, closing down monitor

#2

Starting at step V. on the Prusa instructions makes me think there is something special related to prusa firmware that sets pinouts, but there are extra steps after that may relate.


#3

Thanks! I'm new to the Pi users, but what I have been learning is that it should not be assumed that the Zero and the 3B will connect similarly across the board. Also, I have a 'custom' configuration that is not a Prusa (though it has some similar hardware).

Perhaps you gave me the 'Keys to the Kingdom'. I am too new at the Pi to know...


#4

Adding additional serial ports to look for in OctoPrint will not have them magically show up on your system. OctoPrint will only ever offer you to connect to serial ports it a) know to look for and b) that are actually there.

Have you done steps XI and XII of the Prusa instructions?

As a side note, despite Prusa propagating to use the Zero W with OctoPrint on their machines, I'd strongly recommend against it. The WiFi interface on that machine bogs down the CPU on traffic (e.g. uploading files, viewing a webcam stream) which depending on what you printing can severely impact your printing quality.


#5

Um, I have not followed any of Prusa's instructions, because I do not have a Prusa machine, nor am I using their firmware. I am also perplexed by references to the Pi Zero W, which I also do not have.

Is there a specific step-by-step guide for configuring the connection from a Raspberry Pi 3B to an Einsy Rambo board?


#6

Regardless of whether you have a Prusa machine or not (and sorry, I somewhat overread this, I only read "Einsy" and assumed) you need to remove the Pi's own serial line from its GPIO pins which is on there by default and on 0W and 3/3+ also switch the GPIO serial interface from software emulation to hardware (swapping it with what the built-in bluetooth is connected to). That's those two steps I referred to above. If you don't do the first one, OctoPrint will try to connect to the port the Pi already has its serial console running on instead of your printer. If you leave out the second one, the serial interface will be as slow as a snail.

Finally at least on the MK3's firmware (I don't know about your's) you also need to enable the Einsy's GPIO serial via the menu on the controller.

So, long story short, have you disabled the Pi's own serial console and have you also reconfigured the GPIO serial port? It's not clear from your description if you have.


#7

Thanks for revisiting the issue and clarifying. I have just gotten back to my pc, and will start looking at my firmware (Marlin). Not sure how to go about switching the serial interface on the Pi. The only lines going to the Pi GPIO are the six pins from the J-19 header on the Rambo using the 'breakout cable.


#8

That's explained in the linked guide. Ignore that it's saying something about Prusa MK3, steps XI and XII are what you want to look at.