Octoprint on Raspberry Pi performance issue

Talk about the web based OctoPrint controllers
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Octoprint on Raspberry Pi performance issue

Post by mhackney »

I've been using Octoprint on a raspberry pi off and on for several weeks now. I love the concept and overall host control layout, customizability, integrated video, etc but I am running into many situations where I can't use it due to performance issues. The problem typically rears its head when I print something with a complex infill like KISSlicer's "round" infill. Basically, the perimeters print fast and fine, then everything slows down to a painful crawl when the infill prints. It is jerky and that affects quality as well as takes forever. Has anyone experienced this? I'm connected to RAMBo at 230400 baud so the connection speed shouldn't be an issue. I do have a video camera (pi cam) connected to the pi but once the gcode is downloaded to the raspberry pi filesystem, that shouldn't affect performance should it? I posted on the Octoprint forum but no one has answered for several weeks.

Anyone else experience this?

cheers,
Michael

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

I forgot to mention that I've also disabled as much of the logging as possible as that is reported to affect performance.

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
bubbasnow
ULTIMATE 3D JEDI
Posts: 1061
Joined: Fri Aug 02, 2013 4:24 pm
Location: Dayton, WA

Re: Octoprint on Raspberry Pi performance issue

Post by bubbasnow »

change your kbaud to 57600 and try again
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

Will do but that is counter intuitive! Did you experience a similar problem?

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
bubbasnow
ULTIMATE 3D JEDI
Posts: 1061
Joined: Fri Aug 02, 2013 4:24 pm
Location: Dayton, WA

Re: Octoprint on Raspberry Pi performance issue

Post by bubbasnow »

yea i was getting intermittent issues, daft pointed it out a few months ago and ive been printing anything from any slicer without those types of issues.

also what version are you using? ive noticed that this latest main branch i need to increase the timeout or else i get forced lines.
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

I can't find the version but it is the most recent 1/7/2014 OctoPi release.

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
bubbasnow
ULTIMATE 3D JEDI
Posts: 1061
Joined: Fri Aug 02, 2013 4:24 pm
Location: Dayton, WA

Re: Octoprint on Raspberry Pi performance issue

Post by bubbasnow »

That version should be ok with the timeout setting, if you update you might get the forcing line issue.

mine is .8 version, check the file in /root/etc if you are not sure
User avatar
daftscience
Printmaster!
Posts: 203
Joined: Sun Jan 13, 2013 12:37 pm

Re: Octoprint on Raspberry Pi performance issue

Post by daftscience »

I couldn't run octoprint on my raspberry pi if I had a camera hooked up. if mjpg-streamer is running it will slow it down. Download htop and run that to see where you're resources are going.

My solution was to switch to the beaglebone black. i haven't had an issue since.
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

I was afraid that the video processing might be the culprit. I have a few things to try now - reduce the baud rate, disable video, etc - and see what happens.

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
User avatar
daftscience
Printmaster!
Posts: 203
Joined: Sun Jan 13, 2013 12:37 pm

Re: Octoprint on Raspberry Pi performance issue

Post by daftscience »

Or get the beaglebone black :)

But yeah, could be the camera and or resolution you're streaming at. I was trying to get 720p and had a much higher end webcam. My buddy on the other hand had no issue with his cheaper vga resolution cam.
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

Yup, the video camera is the culprit. I got the little pi camera with my pi and it supports a lot of different bit rates/formats. Not sure how to select which one it chooses for Octoprint though.

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

daftscience, what are you running for a video camera on your Beaglebone Black?

cheers,
Michael

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
User avatar
daftscience
Printmaster!
Posts: 203
Joined: Sun Jan 13, 2013 12:37 pm

Re: Octoprint on Raspberry Pi performance issue

Post by daftscience »

I'm using the logitech c615 and streaming 720 at 15fps. If you haven't, you could try lowering the FPS. There isn't really a need for that to be high at all, especially if your only using it for timelapse.
atoff
Printmaster!
Posts: 277
Joined: Sun Mar 30, 2014 5:24 pm

Re: Octoprint on Raspberry Pi performance issue

Post by atoff »

Of course I see this thread AFTER having purchased the RPI and Pi Camera just a couple of days ago. I was very underwhelmed by the video quality.
atoff
Printmaster!
Posts: 277
Joined: Sun Mar 30, 2014 5:24 pm

Re: Octoprint on Raspberry Pi performance issue

Post by atoff »

Well, I just ordered a Banana Pi. http://www.bananapi.org/ $54 total. Hopefully the right move... I'll probably sell off the RPI, I already have one, and don't need another laying around.

edit: Well, scratch that... the seller is actually OOS. Won't be available until about 30 days, so I'm just cancelling.
User avatar
gestalt73
Printmaster!
Posts: 339
Joined: Wed Aug 07, 2013 11:10 am
Location: Anaheim, CA

Re: Octoprint on Raspberry Pi performance issue

Post by gestalt73 »

I'm still experimenting with the RPi, I was having some issues with uptime, but it turns out that the most likely culprit was a failing sd card.

Until I verify that's straightened out, it's relegated to webcam duty.

Out of curiousity, has you tried enabling any of the overclocking modes?

Default is 700mhz, the raspi-config has settings for 700, 800 900, 950, 1000.

Mine is unstable at anything above 900Mhz, but bumping up the clocks a bit may help with your performance issues.
User avatar
gestalt73
Printmaster!
Posts: 339
Joined: Wed Aug 07, 2013 11:10 am
Location: Anaheim, CA

Re: Octoprint on Raspberry Pi performance issue

Post by gestalt73 »

Out of curiousity, have tried printing while running top in an ssh session to see system load?

I'm trying a second time, after reading up and selecting the "force checksum" option under settings -> features.

This is a larger complex print with alot of support material, and I noticed a definite stuttering earlier on in the print, but it seems to be fine now.

I'm looking at system load, and at most I'm seeing less than 20%.

I wonder..

If the stuttering that we're seeing isn't the rpi processor being overtaxed, but some type of serial over usb issue?

[img]http://i.imgur.com/AeG5XX0.png[/img]
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

I see the same thing with top but consider that the video is going over ethernet not USB. So theoretically it shouldn't interfere with the serial traffic.

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
User avatar
gestalt73
Printmaster!
Posts: 339
Joined: Wed Aug 07, 2013 11:10 am
Location: Anaheim, CA

Re: Octoprint on Raspberry Pi performance issue

Post by gestalt73 »

Yeah, I'd agree with that.

The stuttering that I saw on this model was within the first layers I think. It wasn't the whole layer, just specific features during the layer. That's with a print job running + octopi web ui + webcam.

In the same time, the octopi interface became unresponsive and laggy several times, in addition to the stuttering print. It was choking on something, but since then, now 10 hours into the print it's smooth sailing.

I'll check again when I run the second half of this print to see if top provides any clues if it happens again.

Maybe some type of interrupt weirdness?

My current best guess is that there's some type of serial over usb weirdness that results in corruption and *many* retries, which forcing the checksum seems to catch, even though it just masks the problem somewhat.

I wonder if that's the source of the "mystery disconnects" I was getting as well. some prints would complete, others would stop within a few layers, and the printer would disconnect from octoprint.
User avatar
mhackney
ULTIMATE 3D JEDI
Posts: 5391
Joined: Mon Mar 26, 2012 4:15 pm
Location: MA, USA
Contact:

Re: Octoprint on Raspberry Pi performance issue

Post by mhackney »

That is exactly the symptom I experienced. Interrupt issues makes sense and might be the culprit.

Sublime Layers - my blog on Musings and Experiments in 3D Printing Technology and Art

Start Here:
A Strategy for Successful (and Great) Prints

Strategies for Resolving Print Artifacts

The Eclectic Angler
brent
Printmaster!
Posts: 242
Joined: Fri Dec 06, 2013 10:24 pm
Location: Mass.

Re: Octoprint on Raspberry Pi performance issue

Post by brent »

As an alternative to buying a BBB, you can always overclock your Pi.
atoff
Printmaster!
Posts: 277
Joined: Sun Mar 30, 2014 5:24 pm

Re: Octoprint on Raspberry Pi performance issue

Post by atoff »

brent wrote:As an alternative to buying a BBB, you can always overclock your Pi.
I'm running Octoprint on an overclocked Pi... it's pitiful. I have to print from SD card because the prints are so slow. I'm talking hours longer than it should take, and the print quality becomes awful. I can't upload files to the SD card from Octoprint either, since it takes about 45 minutes to transfer over a 5mb file. I can't see the files on the SD card from Octoprint unless I've uploaded it from Octoprint, so it really becomes somewhat useless. I use it for the webcam feature and to keep an eye on temps. That's about all it's good for with the Pi.
bubbasnow
ULTIMATE 3D JEDI
Posts: 1061
Joined: Fri Aug 02, 2013 4:24 pm
Location: Dayton, WA

Re: Octoprint on Raspberry Pi performance issue

Post by bubbasnow »

atoff wrote:
brent wrote:As an alternative to buying a BBB, you can always overclock your Pi.
I'm running Octoprint on an overclocked Pi... it's pitiful. I have to print from SD card because the prints are so slow. I'm talking hours longer than it should take, and the print quality becomes awful. I can't upload files to the SD card from Octoprint either, since it takes about 45 minutes to transfer over a 5mb file. I can't see the files on the SD card from Octoprint unless I've uploaded it from Octoprint, so it really becomes somewhat useless. I use it for the webcam feature and to keep an eye on temps. That's about all it's good for with the Pi.

what version of the Pi do you have? Are you using a wifi dongle? how big of an SD card/speed are you using on the Pi? I have been running for months without issues.
atoff
Printmaster!
Posts: 277
Joined: Sun Mar 30, 2014 5:24 pm

Re: Octoprint on Raspberry Pi performance issue

Post by atoff »

Latest Rev B... and yes, with an Edimax wifi dongle. I've been suspecting it might be an issue with my SD card... It's an 8GB class 4. If you're not having any issues, it might be time for me to pick up a class 10 to see if that makes a difference. It absolutely crawls when printing through Octoprint, and after reading through the performance issues people were having, I figured it was probably just common.
bubbasnow
ULTIMATE 3D JEDI
Posts: 1061
Joined: Fri Aug 02, 2013 4:24 pm
Location: Dayton, WA

Re: Octoprint on Raspberry Pi performance issue

Post by bubbasnow »

atoff wrote:Latest Rev B... and yes, with an Edimax wifi dongle. I've been suspecting it might be an issue with my SD card... It's an 8GB class 4. If you're not having any issues, it might be time for me to pick up a class 10 to see if that makes a difference. It absolutely crawls when printing through Octoprint, and after reading through the performance issues people were having, I figured it was probably just common.
im running class 10, wired connection. so those are some differences in setup
Post Reply

Return to “OctoPrint”