Q: How to print over the wifi network? (mattercontrol+?+raspberry?)
-
I'd like to not have my (OSX) laptop stuffed in the corner of the garage USB tethered to the (Rostock Max v2) printer. I've got a raspberry pi, and the even cheaper C.H.I.P. computer. Both have built-in USB and WiFi. Question: How do I "proxy" to the printer over wifi? I'm fine not slicing on the raspberry or CHIP, I realize it takes a lot of ram. But I do like everything the MatterControl software gives me - temperature, software-based 7 point leveling, etc.
So - has anyone been able to cut the cord? I hear octoprint is nice, but then do I lose all the nice mattercontrol perks?
-
Hi Ben,
@unlimitedbacon and I have actually been working on a solution to this and working on integrating it into MatterControl(MC). We have a working prototype using a esp8266 with this firmware currently. I hope to finish integrating this function into MC at the end of this next week however it will not be shipped until Version 1.6 is released. If you want an experimental build when it is ready you can email us at support@matterhackers.com.
If you are so inclined you could also use com0com to create a virtual com port for MC to connect to that then connects to a program you write that patches it over to whatever you have connected to your printer (This is how I made a proof of concept before working on integrating it into MC)
As for OctoPrint I don't personally have experience with it but I am fairly certain it used it's own slicing engine. It may however be able to print directly from Gcode allowing you to slice on MC then use OctoPrint to communicate. (There is a checkbox to maintain the software level in the Gcode export)
-
Fantastic! I can wait until 1.6.
I'd also be very happy to use the Raspberry Pi or C.H.I.P. to do it, right now they are gathering dust. And the CHIP is less than the esp8266 (but more lead time), and has a nice USB port on it.
@mmoening said:
MatterControl
-
In addition to slicing on the pi with OctoPrint plus a Cura plug in, you can upload already sliced gcode over wifi and have OctoPrint manage the printing process. OctoPrint also has an API that allows posting a sliced gcode file directly from an app. I think slic3r has implemented this, and I think there is a 3rd party solution for Cura to do this, but it might not be current.
I like MatterControl better than Cura, it would be nice to be able to push a file directly from MatterControl without having to explicitly upload via a web browser.
-
Hey Ben,
I wanted to give you an update on how its going. That being said I have good news and bad news...
Good new, It is now feature complete(On the side of MatterControl)!
Bad news, It will not be in 1.6. To be more specific we need to hammer out how the connect will go on the side of the connector (be it a pi, chip or esp8266) and get some documentation on how to get that set up and ready to go.That being said if you would be willing to give it a test and get something set up on the pi or the chip send us an email at support@matterhackers.com and I'll get you a expiremental build for it as well as I can.
-
will it be possible to port this to the pi, so I can use this with my pi3 and touch screen, I do love matter control but I'm moving house and the printer and pc won't be close
-
We have actually been testing MC on the Pi with touchscreen. There are some kinks that still need to be worked out, but you are welcome to try it for yourself. There is a little more info on the wiki.
-
Good News Everyone!
This feature is now in MC experimental so you can give it a test!
Here is an example script to get a raspberry pi as your server
#!/bin/bash stty -F /dev/ttyACM0 cs8 115200 ignbrk -brkint -icrnl -imaxbel -opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke noflsh -ixon -crtscts nc -k -v -l 2323 > /dev/ttyACM0 < /dev/ttyACM0
-
How are the experiments going?
I've got the printer working fine under MatterControl, but I'm having difficulties with octoprint so I'd like to give this a try. Bit of a newbie on all counts though: I can make no sense of your script (though I do at least think I know what to do with it).
-
The networking function is now no longer experimental and was released in MatterControl 1.7. To enable it go to Settings > Printer > Features > and check Networked Printing. Then go to Settings > Printer > Connection and enter the IP Address and Port of the device you want to connect to.
Here is how @mmoenning's, script works. Essentially this whole script sets up your Pi to act as a relay between your printer's serial port and the network.
stty -F /dev/ttyACM0 cs8 115200 ignbrk -brkint -icrnl -imaxbel -opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke noflsh -ixon -crtscts
This line sets up the connection to the serial port. Most of the options here you don't have to worry about, however you might need to change
115200
if your printer uses a different baud rate (like 250000). You also might need to choose a different serial port device if you have more than one printer connected. For instance,/dev/ttyACM1
. Some printers also use a different style of device name, like/dev/ttyUSB0
.nc -k -v -l 2323 > /dev/ttyACM0 < /dev/ttyACM0
This line uses a program called netcat to setup a persistent TCP server on port
2323
. It then directs all communication to/from the server to the serial port.Once the server is running, set MatterControl to connect to the IP Address of your Pi and port 2323.
-
This post is deleted!
-
OK, yesterday I had it working, but today it is throwing loads of "Wrong checksum", "Format error" and "resend" messages and basically won't print...
-
Also getting a lot of stuff like "stty: /dev/ttyUSB0: Inappropriate ioctl for device" on the Pi. Sorry, that's going a bit off topic: should I take this problem elsewhere?
-
It's fine, I'm just not sure I can help you much more. That script is kind of a hack. I do know that if you try to use 250000 baud you sometimes get that ioctl error. This is because it is a "nonstandard" baud rate.
For what it's worth, we are currently developing a cheap WiFi module that you will be able to plug into your printer to put it on the network. Testing is going well, so these should go on sale Soon
. Right now the name for this device is going to be MatterControl Connect.
-
I'm inclined to stick with this and get it working rather than getting more hardware, but good luck with that project.
I'm running it at 115200 baud.
The "Inappropriate ioctl" problem appears to go away if I reboot the Pi (or I may have just got lucky). Comes back if I interrupt it and reissue the command, or it did last time anyway...
Just the problem with the "resend", "format error" and "wrong checksum"...
-
We'd have to look at a terminal log to see what is going on.
-
Would you like me to get one for you?
Are we assuming that the problem is not unique to me? Or would it be better if I start again with a fresh Pi to ensure everything is right at that end of it?
-
Since you mentioned that it was working at first, and then stopped, it seems like something must have changed. I agree it would be a good idea to try with a fresh Pi. If that doesn't work then we will need the terminal log to do any further troubleshooting.
-
Doesn't time fly?
I set up a Pi with a fresh install of Octoprint and I cannot get the damn thing to connect to the WiFi. :roll:
You may have guessed that it is not high on my priority list, but I don't know whether to persevere with the Octopi and get that to work, or to start afresh with a clean NOOBS, or to go back to the one that was nearly working. :?
-
Right new OS on the Pi.
When I run the script I get either:
stty: /dev/ttyACM0: No such file or directory
Or:
stty: /dev/ttyACM0: Inappropriate ioctl for device
Either way, it goes on to:
Listening on [0.0.0.0] (family 0, port 2323)
And then appears able to connect. MC appears to connect when told to, but is not getting any telemetry: temperatures at zero and not responsive to commands...
-
Sussed it. Printer is on ttyUSB0 not on ttyASM0
Still getting errors though:Attempting to connect to: 192.168.1.14 on port 2323
Connected to: 192.168.1.14 on port 2323
->Communication State: AttemptingToConnect
->N1 M110 N1*125
->N1 M110 N1*125
<-echo:Unknown command: "ÿû,ÿú,"
->Communication State: Connected
->N1 M110 N1*125
<-ok
<-echo:Unknown command: "S0"
<-ok
->N1 M110 N1*125
<-echo:Unknown command: ""
<-ok
->N2 M114*37
<-ok
<-X:0.00 Y:0.00 Z:0.00 E:0.00 Count X:0 Y:0 Z:0
<-ok
->N1 M110 N1*125
<-ok
->N2 M115*36
<-FIRMWARE_NAME:Marlin SkyNet3D-V2.3.2 (Github) SOURCE_CODE_URL:https://github.com/MarlinFirmware/Marlin PROTOCOL_VERSION:1.0 MACHINE_TYPE:SkyNet3D EXTRUDER_COUNT:1 UUID:cede2a2f-41a2-4748-9b12-c55c62f367ff
<-ok
->N3 M114*36
<-X:0.00 Y:0.00 Z:0.00 E:0.00 Count X:0 Y:0 Z:0
<-ok
->N4 M104 T0 S0*37
<-ok
->N5 M105*34
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N6 M105*33
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N7 M105*32
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N8 M105*47
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N9 M105*46
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N10 M105*22
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N11 M105*23
<-ok T:16.2 /0.0 B:16.4 /0.0 @:0 B@:0
->N12 M105*20
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N13 M105*21
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N14 M105*18
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N15 M105*19
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N16 M105*16
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N17 M105*17
<-Error:No Line Number with checksum, Last Line: 16
<-echo:Unknown command: "0"
<-ok
->N18 M105*30
<-echo:Unknown command: ""
<-ok
->N19 M105*31
<-Error:Line Number is not Last Line Number+1, Last Line: 16
<-Resend: 17
<-ok
->N17 M105*17
<-Error:No Line Number with checksum, Last Line: 16
<-echo:Unknown command: "0"
<-ok
->N18 M105*30
<-echo:Unknown command: ""
<-ok
->N19 M105*31
<-Error:Line Number is not Last Line Number+1, Last Line: 16
<-Resend: 17
<-ok
->N17 M105*17
->N17 M105*17
<-echo:Unknown command: ""
<-ok
->N18 M105*30
->N18 M105*30
<-echo:Unknown command: ""
<-ok
->N19 M105*31
<-Error:Line Number is not Last Line Number+1, Last Line: 16
<-Resend: 17
<-ok
->N17 M105*17
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N18 M105*30
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N19 M105*31
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N20 M105*21
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N21 M105*20
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N22 M105*23
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N23 M105*22
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N24 M105*17
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N25 M105*16
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N26 M105*19
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N27 M105*18
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N28 M105*29
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N29 M105*28
<-ok T:16.3 /0.0 B:16.4 /0.0 @:0 B@:0
->N30 M105*20
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N31 M105*21
<-ok T:16.2 /0.0 B:16.4 /0.0 @:0 B@:0
->N32 M105*22
<-ok T:16.4 /0.0 B:16.4 /0.0 @:0 B@:0
->N33 M105*23