# Specific 3D Printers, Scanners, & Hardware > RepRap Format Printer Forum > MakerFarm Forum >  Using a Raspberry Pi + Octopi to manage your printer

## dacb

It didn't take me long to get tired of uploading files to the SD card via sneaker net.  Moreover, I really wanted to be able to control the printer more easily than the LCD/knob interface and some control options were not available via the LCD/knob. Finally, I really wanted to be a be able to check out prints when I wasn't in the same physical location as the printer and to be able to record prints so that when something goes wrong, I have a way to get some visualization around the time of the problem.

I happen to have a Raspberry Pi B from another project that was severely underutilized.  The current models come in two flavors: B & B+.  I would recommend the B+ for someone who might be purchasing one new for this project.  It has more USB ports so it is possible to plug in a WiFi USB dongle, the Arduino/RAMPS, and a USB web cam (more on all that later).  The Pi is cheap, ubiquitous and there is a lot of support for it on the web.  There are alternatives such as the newly introduced Intel Galileo, but again, there are so many Pis out there that support is great and the community is vibrant.

The above needs and the fact that I happen to have a Pi led me to try out a few different solutions, including Repetier-Server (RS), Printrun (pronterface), and Octoprint in the form of OctoPi.

For RS & Printrun, I used a fresh install of Raspbian on a 32GB SD card setup with Apple Pi Baker.  I used to prep SD cards for the Pi with dd, etc. but tools like APB are just easier.  UNetbootin also works well and seems to work on Windows and Linux, too.  *To setup Printrun*, check out a site like this one.  Printrun's pronterface works as it does everywhere. Unfortunately, it ran like a dog on the Pi.  To use it, I had to ssh -Y into the Pi and display the interface using X-windows.  If that sounds like greek to you, probably should skip Printrun. *To setup RS*, download the Pi tarball from their site and follow the directions.  In my hands, however, RS never really worked properly.  It would disconnect or not connect at all.  The web interface (in my opinion) was ugly and the functionality not intuitive. 

*To setup OctoPi*, on the other hand, all I had to do was download the SD card image, load on to SD card with APB and plug it all in.  It came preconfigured with the web server all setup and the web cam service ready to go once a cam was plugged in.

For RS, Printrun and OctoPi, before plugging the Pi into my printer, I had to enable the WiFi dongle.  I was too lazy to plug my Pi into an HDMI monitor and find a USB keyboard so I just plugged the Pi into my router via ethernet, found the DHCP assigned IP and configured the WiFi, and did it via ssh (see below).  You could just as easily do it with an HDMI monitor/TV & USB keyboard - just leave out the ssh commands below.



```
# first, ssh in and setup passwords and root ssh
ssh pi@192.168.X.Y
password: raspberry

# setup pi password (change from raspberry)
passwd
# setup root password for root ssh
sudo passwd

# configure the installation
sudo raspi-config
# Select: 1. Expand File System (Fill SD card)
sudo reboot
```

Once the Pi rebooted, I was able to ssh in as root and setup the WiFi client:



```
# ssh in as root
ssh root@192.168.X.Y

# always useful to have vim!
sudo apt-get install vim
Y

# now populate the SSID information for the Pi's WIFI client:
cat << EOF >> /etc/wpa_supplicant/wpa_supplicant.conf

network={
    ssid="yourSSID"
    psk="your_passwd”
    key_mgmt=WPA-PSK
}
EOF

sudo reboot

```

I also took a moment to have my router assign the Pi's WiFi MAC address a single IP via DHCP.  I do this so that I will always know the address of the Pi on the network.  I also forced the router to assign the octopi hostname to the Pi.  You may or not be able to do this with your router.

As I mentioned, I'm using a web cam.  I happened to have had an old (maybe 8 years?) web cam: Logitech QuickCam Pro 9000.  I didn't expect it to work given its age and the possibility of no drivers for the Pi, but it fired right up.  I am also exposing a port on my router that will redirect to the web cam on the Pi so that I can watch the printer when I'm away from home.  The OctoPi distribution ships with a preconfigured mjpg-streamer that just works.  It does, however, expose a web interface that allows the camera settings to be modified.  I didn't like this so made the default page that mjpg-streamer serves a simple stream on white background page (see below).  In addition, I also copied back the stream.html that OctoPi wants to find for the embedded stream:



```
ssh pi@octopi
cd mjpg-streamer
mv www www.back
mkdir www
cp www.back/stream_simple.html www/index.html
cp www.back/stream.html www/stream.html
sudo /sbin/shutdown -r now

```



Finally, I wanted to update to the latest OctoPi (at this time 0.10.0) which has some new features.  Here are some directions and my commands:



```
ssh pi@octopi
cd ~/OctoPrint
git pull
~/oprint/bin/python setup.py install
sudo service octoprint restart
```

Now, go to http://octopi (or whatever IP you used) and you will see the basic OctoPi interface.  On the first connect, it will ask you to setup a username/password and to turn on security. I did this to keep my kids from canceling prints so I can make more star wars stuff.  Then you will need to select the FTDI serial port and set the baud (250000).  Click save settings and then connect.

When I installed Cura it broke everything. It requires a gcc upgrade that causes OS updates to compile but fail to run correctly, bricking the SD. Why should I slice on the Pi anyway?

The web interface works with every device I've thrown at it, including an iPad, iPhone, Windows Phone, Chrome, Firefox, Safari, IE.  The mjpg-streamer works on all of the browsers except the Windows Phone.

I'm sure I've missed stuff here so I will edit this page to add anything - it is basically just a dump of my notes from a Google Doc.  Please ask questions because it will help make this more useful.  If people want, I can throw up some screenshots.

Edit: It is also nice to be able to add firmware remotely: see post #14

----------


## dacb

You can get a Pi from a lot of places, including Amazon, Element14, Ebay...  I'd probably buy a B+ for a new install because it has more USB ports so you can plug in a web cam, the Arduino and a WiPi without a need for an external powered hub. *One option* is to buy a Pi kit that includes a power supply, formatted SD card, the Pi itself and maybe a case.  Don't bother with a case (you will be printing one soon, right?).  I didn't go this route, so here is more info on my particular config.

I power my Raspberry Pi with a 2A charger for USB devices.  There are 'special' power supplies for the Pi, but usually these boil down to a relabeled higher output USB charger.

For a WiFi dongle, I use the WiPi from Element14, but there are a lot of compatible dongles.

You will also need an SD card.  I used a 32GB card so that there is plenty of space for Gcode and the MJPG movies of the prints that are created.

Finally, I used a web cam I had hanging around.  A list of compatible web cams is here.

----------


## printbus

Thanks for compiling the useful info.  It'll give me something to experiment with as the winter weather sets in...

----------


## dacb

Here is an example video from a print: https://drive.google.com/file/d/0B74...it?usp=sharing

It took a frame at every Z-change.  I think I like doing it at 10 second intervals better.  The options in OctoPi for image capture into time-lapse movies are _on Z-change_ or _timed_.

It looks like my LED lights in the extruder carriage fell down during the print!  

This is a print of this skull shrunk down to ~25% IIRC.

----------


## gmay3

dacb, this is awesome! Thanks for all the great info, I feel safe buying a raspberry pi knowing that you have this expertise if something goes wrong! Consider my raspberry pi ordered.

That's cool that you can use a USB webcam because I have a supported one lying around already! Do you think there is any reason to buy and use the raspberry pi dedicated camera instead?

I'm gonna slam dunk that alley-oop you tossed me about your LED's falling in to your print with this!  :Big Grin: 
http://www.thingiverse.com/thing:438960

----------


## Zulfe

Great guide! I was already looking into setting up OctoPi and creating a guide, but you've accomplished more than I would have, especially with the static IP and forwarded ports to use the webcam from anywhere. I can't wait to set this up!

Thanks for the guide, can't wait to see what else you post.

----------


## AbuMaia

I just use two zip ties to keep my lights from falling off. Luckily the i3v X carriage backplate has two unused holes at the bottom which I used for this purpose.

----------


## dacb

> dacb, this is awesome! Thanks for all the great info, I feel safe buying a raspberry pi knowing that you have this expertise if something goes wrong! Consider my raspberry pi ordered.
> 
> That's cool that you can use a USB webcam because I have a supported one lying around already! Do you think there is any reason to buy and use the raspberry pi dedicated camera instead?
> 
> I'm gonna slam dunk that alley-oop you tossed me about your LED's falling in to your print with this! 
> http://www.thingiverse.com/thing:438960


Glad it is useful!  No reason to buy anything extra.  Use what you've got!

I like your light fixture.  I've thought about it a lot.  I am running an auto bed leveling setup which looks like it would interfere with one side...  :Confused: 




> I just use two zip ties to keep my lights from falling off. Luckily the i3v X carriage backplate has two unused holes at the bottom which I used for this purpose.


You know, I've never noticed those holes before!  They could be useful for mounting all kinds of stuff!

----------


## gmay3

Got my Raspberry Pi B+, power supply, and USB Wi-Fi Module yesterday! I plan on trying out all of this today, maybe even while printing an enclosure  :Big Grin: 

Here's what I ordered, just for reference. I'll report back on how well everything works and will post any issues I have along the way! (Not mentioned below is a Micro SD card and a Logitech C615 HD Webcam that I had on hand)

*Raspberry Pi B+*
http://www.amazon.com/gp/product/B00...?ie=UTF8&psc=1

*2A Micro-USB Power Supply*
http://www.amazon.com/gp/product/B00...?ie=UTF8&psc=1

*USB Wi-Fi Module*
http://www.amazon.com/gp/product/B00...?ie=UTF8&psc=1

----------


## dacb

Outstanding!

----------


## gmay3

Firstly, thanks very much to dacb for this great guide! 

All the hardware I've listed in my previous post worked great and needed no drivers at all!

 After about an hour of work I got it working! I still have a little tweaking to do (I'll elaborate in the last paragraph) but I was able to slice from my computer, send the gcode file to my printer, set and view real time graphical heating temperatures of the hotend and bed, move the axes around remotely, and watch the high quality video feed from my browser! SO COOL! The interface that you interact with from your browser is super polished, which was a very nice surprise. The only thing I couldn't do from my computer was level the bed manually :P

One other great thing that was in the OctoPi preferences was that I could easily switch the direction of all my x axis movement commands, this is something that has annoyed me with pronterface (which I probably could have fixed with some effort). For some reason I had to reverse the connection on my x motor cable during the build to get it to home correctly so my x movement commands in pronterface have always been reversed.

I need to work on setting up the static router settings for the Pi and set up the remote VPN stuff, though this wasn't super important to me. I'm not going to run my printer without being home, it's just not reliable enough! Also, for some reason, my first print seemed to have a similar gcode error that other folks have had before where the print stayed adhered to the bed but the gcode seemed to shift during print in the wrong directions. Looking at the STL through slic3r it looked fine. I recently changed computers so I think something went wrong with slic3r's settings. I don't think this has anything to do with OctoPi but haven't solved the problem yet.

*UPDATE

*The gcode error I though I was having had nothing to to with OctoPi.

After a couple hours of trying to figure out what the problem with my print was, I discovered that the belt pulley on my y bed had loosened over time. One of the set screws came completely out of the hole and was lying on the table right below it. I now have loctite blue'd both set screws on both the X belt pulley and Y belt pulley.

----------


## dacb

Fantastic!  Yeah, I really dig the UI.  Intuitive and functional.  Have you setup a time-lapse movie yet?

----------


## gmay3

No, I didn't get that set up yet but definitely will soon! I think I saw where do to it but I was just happy to be able to control and see the printer on camera remotely! 

Are you able to auto level the bed from OctoPi? (maybe that would get me interested :P)

----------


## dacb

> ... Are you able to auto level the bed from OctoPi? (maybe that would get me interested :P)


In as much as you can issue a G28 X0 Y0 Z0 followed by a G29 in the Gcode terminal through the web interface.  That terminal is pretty nice once you click the checkbox to suppress the M105 request/responses. 

*I should add that I've also begun uploading firmware via the Pi.* There are two ways to do this:
1. There is a post in this thread that describes the command line setup of ino (a command line version of the Arduino IDE) and using it to upload to an Arduino board.  Compilation is slow and you have to munge the .ino file to get it to work correctly with the Marlin.ino
2. Install avrdude and send the .hex file to the Pi and upload with avrdude at the command line.  *This is what I am doing.*  E.g.
Install avrdude, on the Pi as pi@octopi:


```
sudo apt-get install avrdude
```

Upload your hex to your Pi (pi@octopi).  When you 'verify' (i.e. the check in the upper left corner which does a build without upload) the Marlin firmware in the Arduino IDE, the full path of the temporary .hex file will appear in the log at towards the end of the output. *Note*: for newer versions of the Arduino IDE, you will have to turn on "Show verbose logging" during compilation in the preferences.  I use scp via the command line to copy that .hex file to the Pi (usually just into the root of the pi user home directory).  For OS/X, Linux, and Windows there is almost certainly an sftp/scp GUI client. E.g. (example only!!!! where the hex ended up in /var/folders/nw/_0y0_37s63z_zj3kz42zw9jc0000gn/T/build6973326520497902471.tmp/Marlin.cpp.hex ):


```
scp /var/folders/nw/_0y0_37s63z_zj3kz42zw9jc0000gn/T/build6973326520497902471.tmp/Marlin.cpp.hex pi@octopi:
```

Use avrdude to upload the .hex to the Arduino. Instead of using the Arduino IDE to upload the .hex, use the avrdude tool you installed.  Behind the scenes, the Arduino IDE is using avrdude to upload the sketch.  Skip the IDE an do it from the command line (for example with your firmware in the current working directory called Marlin.cpp.hex):


```
avrdude -p m2560 -c stk500v2 -P /dev/ttyACM0 -b 115200 -F -U flash:w:Marlin.cpp.hex
```

*
Warning: Use this at your own risk:* Don't try this for your first Marlin firmware change.  Make sure you can do that, at will, without problems on some other platform.  That way, if this process doesn't work for you, you can reinstall the firmware with your known working method. _Disclaimer end._

----------


## gmay3

> In as much as you can issue a G28 X0 Y0 Z0 followed by a G29 in the Gcode terminal through the web interface.  That terminal is pretty nice once you click the checkbox to suppress the M105 request/responses.


Sounds pretty awesome! Are you able to completely print and level remotely with a good success rate?

Agreed on the firmware changes, I definitely would take your advice to do the first one the traditional way but this sounds like a really cool feature! Thanks for the guide!

----------


## dacb

> Sounds pretty awesome! Are you able to completely print and level remotely with a good success rate?


Yes.  However, OctoPi doesn't give you anyway to remove the print from the bed!  :Wink:

----------


## gmay3

Very cool, I must say that is tempting then. Maybe I should look into  auto bed leveling. Although it seems a little complex at the moment.




> Yes.  However, OctoPi doesn't give you anyway to remove the print from the bed!


WE HAVE THE TECHNOLOGY!  :Big Grin: 
Untitled.jpg

----------


## dacb

Or: http://www.thingiverse.com/thing:407800

----------


## AbuMaia

Or if you've printed a relatively tall object, just move the nozzle to X190 Y190 Z5, then slowly move Y back to 0. Let the X axis extrusions sweep it off.

----------


## gmay3

Here's a screen shot of a print in progress with OctoPrint!

octoprint.jpg

----------


## dacb

Dig it!  I just noticed that the wscode viewer was updated recently and has some nice new features.

----------


## AbuMaia

Well, phooey. I just got my raspi, and I put the octopi image on the sd, put it in the raspi, then connected it to my router. I have no HDMI-capable screen in my house, nor a spare keyboard/mouse. I put power to the raspi, and I still do not see it show up on my router config page... I'll have to figure something else out when I get home from work.

----------


## gmay3

Aw man that's frustrating! You should sneak it into the local electronics store computer section (or library lol) and configure it up!

Are you able to see anything in your browser when you go to "octopi.local" in a browser window?

----------


## AbuMaia

No, the page times out. I didn't expect it to work, as I haven't even managed to verify the OS is working. I can't even mount the SD card on my Linux laptop to examine it.  

Looks like it *might* be the microSDHC. I got the Samsung Evo 32GB class 10. The wiki says it doesn't work, so I'm swapping it out for the 32gb microSDHC from my phone. The green LED on the B+ didn't blink or anything, which the wiki says means it didn't boot properly.

Second card did not work. It also will not mount on my laptop after flashing. I think it's the OctoPi image I downloaded. It downloaded over 900mb, when the mirror said it's only 867mb. Redownloading.

----------


## Geoff

> No, the page times out. I didn't expect it to work, as I haven't even managed to verify the OS is working. I can't even mount the SD card on my Linux laptop to examine it.  
> 
> Looks like it *might* be the microSDHC. I got the Samsung Evo 32GB class 10. The wiki says it doesn't work, so I'm swapping it out for the 32gb microSDHC from my phone. The green LED on the B+ didn't blink or anything, which the wiki says means it didn't boot properly.
> 
> Second card did not work. It also will not mount on my laptop after flashing. I think it's the OctoPi image I downloaded. It downloaded over 900mb, when the mirror said it's only 867mb. Redownloading.



Use the formatting utility from sdcard.org

https://www.sdcard.org/downloads/formatter_4/

I had the same issue as you until I used that to format my card instead, just make sure you tick use all space and do a full format.

----------


## AbuMaia

I did that with the second card. It had two partitions, so I deleted them and made one that used the whole disk, then flashed the image to it. Didn't work. About 20% into the new download now, so I'll try again in the morning.  I run Ubuntu Linux on my computer, so the Formatter won't work for me. (It will under WINE, but I don't want to trust something like this to a program running under an emulator)

Edit: I got it working.  The SD card device name was something like mmcblk0. The disk utility I was using kept installing the image to mmcblk0p1, or to the partition. I used a command-line command to do it to mmcblk0 instead, and it was mountable, and booted up properly in the raspi. I finally got wifi working on it, so I'm about to hook it up to the printer and send the first gcode through it.

----------


## gmay3

Awesome! Glad to hear you got the SD card and all working.

I've been having some connection issues with mine, not during prints or anything but when I boot up the raspberry pi board. I unplugged everything from the raspberry pi and would have to power cycle a few times until the octopi page would come up. I couldn't ever determine what was causing it to hang but I've been leaving it on all the time now and haven't had any issues with the connection since!

Also as a note, the pause and stop buttons do work but take about 15 to actually stop the printing.

----------


## AbuMaia

I got it working to the point where I can access the web page on my phone's browser without using wifi. Current problems are, 1, the webcam I have doesn't seem to work with mjpeg-whatever, and 2, if I upload a .gcode file to the raspi, it tries to send commands even while old commands are still being executed. I have auto bed leveling set up and running, and while it's probing the bed, nearly 60 commands get sent to the printer, which then chokes because it last saw command #13. So for now I'm stuck with uploading .gcodes to the SD card, and printing from there.  

Did either of you guys need to use a powered USB hub to get your webcams working, or did they work plugged directly into the raspi?

Edit: I fixed problem 2 by increasing the communication timeout to 300. Now OctoPrint doesn't get carried away sending commands to the printer without a response.

----------


## gmay3

> Did either of you guys need to use a powered USB hub to get your webcams working, or did they work plugged directly into the raspi?


Nope, I didn't need a powered USB hub to get any of the peripherals powered up. I'm running a Rasberry Pi B+ version with a 5V, 2A power supply.

----------


## dacb

Hi, sorry for not responding, I've been traveling.

I've read through this quickly, but maybe you can summarize the current state?

----------


## AbuMaia

For me, the current state is OctoPi up and running, the webpage working properly, the webcam working properly once I bought one that works with OctoPrint, and everything being viewable and controllable remotely over the internet. Changing the communication timeout setting in OctoPrint from 5s to 300s lets me get through auto-bed-leveling without OctoPrint spamming the printer with unacknowledged commands. Now all I need is to find some way to mount my webcam. There aren't many options on Thingiverse for a Logitech C270. It's currently being held by two clamps.

----------


## dacb

Fantastic!  I have my camera sitting on a stack of empty spools.  Not elegant, but it works.  For a while I had it perched next to the LCD looking down, but you can't really see much that way.

Glad it is working out for you.

----------


## gmay3

Yeah I'm still trying to get an ideal camera angle! Right now the LEDs on my extruder are over exposing the printing area on the video feed so I'm working on getting them on a switch! I'm not sure if there is a way to modify the video settings on the raspberry pi but there might be.

----------


## AbuMaia

I ended up using the beams and camera holder from this http://www.thingiverse.com/thing:31171 and the beams from this http://www.thingiverse.com/thing:199517. I originally had it mounted to the X0 Y0 corner of the printbed, but I now have it mounted to the RAMPS-side Z nut holder. The camera sits in line with the nozzle along the X axis.  

I, too, had a problem with the LEDs under the extruder making it too bright, so I unplugged them. I have additional LEDs behind the top of the frame, shining down onto the bed, and they seem to be sufficient (other than a big shadow cast by the X extrusions  :Smile: )

----------


## gmay3

Those look pretty cool! Thanks AbuMaia!




> I have additional LEDs behind the top of the frame, shining down onto the bed, and they seem to be sufficient (other than a big shadow cast by the X extrusions )


That's perfectly in time for some Spooky Halloween printing!  :Big Grin:

----------


## gmay3

So I have been finding that getting Octopi.local to come up in my browser has been somewhat difficult at times. I try hard resetting the Pi to get it to work but it usually takes a good amount of hard resets to get the server going.

Has anyone else had this issue? I usually leave the pi powered up and running to try to avoid this problem but maybe I am causing the problem by leaving it running.

Is there a timeout or screensaver function on the pi that could be hosing things up?

----------


## AbuMaia

I haven't been having any trouble with it. I, too, leave it running. It's been up nonstop for nearly a month now. Are you running it only on your home network, or do you have it set up to be accessible from the internet? You may need to reinstall the OS, or run some updates.

----------


## gmay3

I am running it on a home network using wifi. 

I also don't have a static IP assigned to the Pi so it is likely changing its IP address depending on what other wireless devices are connected to the router. I'm not sure if this could be causing the problem.

I actually removed it from the printer and plugged it into my TV to see if I could see what could be hanging it up but it seemed like the desktop booted fine and there is some sort of background process which is not visible via the desktop hosting the octoprint server.

----------


## AbuMaia

I am about to rewire my printer with dual switches, kind of like the light switches at either end of a hallway, or at the top and bottom of stairs. Right now I have three physical switches on my printer, one for main power, one for lights, and one for X, Y, and Extruder motor fans. I have some SPDT switches on order to replace these three switches, which I'm going to hook together with a relay board controllable from the RasPi. This way I can control the power, lights, and fans when I'm at the printer, or I can control them when I'm away over OctoPi. I could flip a relay through the webpage to turn the lights on, then flip the switch on the printer to turn them off again, and vice-versa.

----------


## AbuMaia

> I am running it on a home network using wifi. 
> 
> I also don't have a static IP assigned to the Pi so it is likely changing its IP address depending on what other wireless devices are connected to the router. I'm not sure if this could be causing the problem.
> 
> I actually removed it from the printer and plugged it into my TV to see if I could see what could be hanging it up but it seemed like the desktop booted fine and there is some sort of background process which is not visible via the desktop hosting the octoprint server.


I told my router to give every device its own IP, and to not change it at all later. I then told the router firewall to redirect the OctoPi page to my home IP address with specific  :Stick Out Tongue: ort tagged on the end.

Does the server activate and run properly when you have it connected to the TV?

----------


## gmay3

> This way I can control the power, lights, and fans when I'm at the printer, or I can control them when I'm away over OctoPi. I could flip a relay through the webpage to turn the lights on, then flip the switch on the printer to turn them off again, and vice-versa.


This sounds awesome! Let us know how your development/build goes!

When I had it connected to the TV I went into the wifi manager and saw that it had not yet connected to my wifi so I clicked connect. I don't know why this was the case because I have been able to get it to work by just power cycling the board when it is not connected to the TV.

Is there a way to access a debug terminal to see the octoprint server process running?

----------


## AbuMaia

Not that I know of. I haven't been able to find any way to run the server with debug info through the terminal yet. 

 I finally received the wires to connect my RasPi to the relay board. I followed the instructions here: https://github.com/foosel/OctoPrint/...-from-your-RPi  I used the relay board listed on that page from Amazon. I have power going through relay 4, lights through 3, and fans through 2. Relay 1 is still unused. The relays are SPDT, so when combined with three more SPDT switches, I get the double-switch action.   

The power goes into common on the switch, NO connects to the relay NC, and the switch NC is connected to the relay NO. The relay common takes the power into the power supply. (Yes, I checked to make sure the relay and switch could handle 120v AC.) 

The fan and light switches are run the same way. Power out from the power supply into common on the switch, NO-to-NC and NC-to-NO connections to the relay, and relay common out to the fans and lights.  I should note I'm running the - wires through the switches and relays. The + side just connects directly.

i had to install wiringPi in order to get the commands to control the GPIO pins from the webpage. I would recommend NOT using physical pin 8 (wPi pin 15, BCM pin 14) to control a relay, as when the RasPi starts up, that's the TxD pin, and it will rattle the relay and send intermittent power to whatever you're switching. I used physical pin 12 instead.

edit: I've also written a small script to call from the OctoPi webpage that let me condense six commands (Printer On, Printer Off, Fans On, Fans Off, etc) into three (Toggle Printer, Toggle Fans, Toggle Lights).

pintoggle goes into ~/scripts:



```
#!/bin/bash
#read the pin and toggle mode
pin=$1
state=$(gpio read $pin)
if [ $state = "1" ]; then
gpio mode $pin out
else
gpio mode $pin in
fi
```

This goes into the config.yaml for OctoPrint:



```
  - action: toggle printer
    command: bash ~/scripts/pintoggle 1
    confirm: You are about to turn the printer On or Off
    name: Toggle Printer
  - action: toggle lights
    command: bash ~/scripts/pintoggle 7
    confirm: false
    name: Toggle Lights
  - action: toggle fans
    command: bash ~/scripts/pintoggle 9
    confirm: false
    name: Toggle Fans
```

Use whatever pin numbers you end up using.

----------


## kd7eir

Never mind - it was "helpful" caching that was not showing me the changes when I was expecting them.

I entered everything exactly as you have it shown here, but I could never get the actions to show up in the menu. I can run the script that you wrote from terminal and it works properly, so I must be doing something wrong in how I am entering the actions. Strangely, any other actions that I create, besides the ones you have here, will show up in the menu.

----------


## gmay3

Hey Kd7eir, welcome to the forums! Glad you were able to get past the "helpful" caching haha. Do you have octoprint up and running then?

----------


## dacb

Outstanding stuff, Abu!

----------


## kd7eir

> Hey Kd7eir, welcome to the forums! Glad you were able to get past the "helpful" caching haha. Do you have octoprint up and running then?


Thank you gmay3

I do have octoprint up and running, complete with camera. It's very nice to have complete control of the printer remotely as well as being able see exactly what it's doing.

----------


## gmay3

Very cool! Yeah I have liked it so far. Sometimes it's a little buggy but nothing a "reset octoprint" or browser refresh can't usually fix.

----------


## kd7eir

> Very cool! Yeah I have liked it so far. Sometimes it's a little buggy but nothing a "reset octoprint" or browser refresh can't usually fix.


I have definitely become familiar with those. I've only had one print that just would not work through octoprint. It was a case for a Sainsmart 4 relay board.  It would constantly throw an error about line numbers being wrong. Copied the gcode straight to the SD card and it printed fine from there. That makes my reliability rating about 99% for octoprint - not too bad for free software.

----------


## gmay3

Absolutely, for about 50 dollars for all the stuff needed, you can't beat it!

----------


## Stigern

Just got my RPI up and running with OctoPi  :Big Grin: 

Btw, are there plugins or such available? Would be very cool to have a plugin which shows where the printer extruder is at all times :P

----------


## AbuMaia

Now all we need is some way to remotely clear the print bed of a finished print so another print could be started.  :Smile:  I've had thoughts of a servo-actuated "blade" mounted to the back side of the lower X vslot that could be flipped down after a print to scrape it off the glass. 




> Would be very cool to have a plugin which shows where the printer extruder is at all times :P


  This has been discussed several times on the OctoPrint requests page, and from what I understand, it would tax the RasPi too much to do continuous polling of the extruder position. The RasPi doesn't keep track of position, it would have to continuously ask the printer where it is. Doing that while it's sending movement commands to the printer seems to be too much.

----------


## gmay3

> Now all we need is some way to remotely clear the print bed of a finished print so another print could be started.  I've had thoughts of a servo-actuated "blade" mounted to the back side of the lower X vslot that could be flipped down after a print to scrape it off the glass.


Haha or just have the nozzle do a maze pattern 1 mm above the glass after the bed is at ambient temp.

----------


## 1stage

Hey, what do you have as your Axis mm/min settings? (Settings > Printer Parameters > Axis)

I don't want to over-tax my steppers by issuing commands that will fry them.

----------


## AbuMaia

X: 3000, Y:3000, Z:200, E:540  I took the values from Marlin and put them in here.

----------


## printbus

> X: 3000, Y:3000, Z:200, E:540  I took the values from Marlin and put them in here.


OK, I'll bite. What settings in Marlin are these? DEFAULT_MAX_FEEDRATE? If so, aren't the stock values  15000, 15000, 120, and 1320 (adjusted for mm/min)? Interestingly, your values for Z and E aren't far from what my initial experimenting with motion related settings suggested. You've seen the other thread for sharing improvements to the motion settings, right?   :Smile:

----------


## AbuMaia

> OK, I'll bite. What settings in Marlin are these? DEFAULT_MAX_FEEDRATE?


Yup  :Smile:  

```
#define DEFAULT_MAX_FEEDRATE          {250, 250, 2, 22}    // (mm/sec)
```




> You've seen the other thread for sharing improvements to the motion settings, right?


Yup, I've been waiting to see if that thread will help me figure out what to do with acceleration and jerk settings. I haven't figured those out yet.

edit: huh, I guess I didn't get the numbers from Marlin after all. I don't remember where they came from, then. Maybe stock OctoPrint?

----------


## dacb

I don't think OctoPi defines those parameters.  It does have some motion related but IIRC those are only for the interface jog, not printing.

----------


## AbuMaia

Nearly panicked last night, thought my OctoPrint had suffered a major bug, and I didn't know what to do to fix it. I could load the page, see the webcam, everything. I could upload any .gcode file I wanted. But I could not load or load/print the file. The buttons were faded. The only solid black button was the Trash button. I don't know how many times I rebooted the RasPi, or how many times I restarted OctoPrint.

Then I hit on the brilliant idea of refreshing the web page. Success!

*headdesk*
I've said it before... I'm dense.

----------


## gmay3

Haha I know this struggle! "Why can't I click the buttons! Oh I need to login again for some reason..." I like the *headdesk*  :Smile:

----------


## CalifDan

I have been reading through these posts and have ordered what appears to be necessary to set up the Raspberry Pi with Octopi.  However, it is not clear to me if this eliminates the need for the kit lcd display or not?  I do understand that a display is required to access the Raspberry Pi.

----------


## AbuMaia

I haven't really had much use for the LCD since I started using the OctoPi. I haven't even used the SD card. While the print is running from the OctoPi, the only info the LCD gives is temperature and location. I do use the LCD knob, though, to resume a print if my filament runs out and triggers a pause switch, though I could do that with any momentary switch, I think. Now you've got me thinking about removing my LCD. As for a display being required for the Raspberry Pi, not necessarily. I access my RasPi over wifi from my Ubuntu laptop. I open a terminal and SSH into the RasPi via its router address. Then I can do the setup from my laptop (only because I have zero hdmi-capable displays in my home, and I didn't want to buy any).

----------


## gmay3

> I have been reading through these posts and have ordered what appears to be necessary to set up the Raspberry Pi with Octopi.  However, it is not clear to me if this eliminates the need for the kit lcd display or not?  I do understand that a display is required to access the Raspberry Pi.


The kit LCD on top of your printer is not needed if you are using octopi. Since I'm working on new LCD bracket parts that will become a rear spool holder, I actually have my kit LCD, ribbon cables, and sd card unplugged from the printer completely. You just need connect the usb on the raspberry pi to the usb on your RAMPS board.

If you want to, you can run with the kit LCD attached, and it will just mirror the commands given by octopi. One thing that is nice about having the LCD attached is as a redundancy, if the octopi server goes down for some reason, it's nice to see that the temperatures are commanded 'off' on the LCD. Also varying the print speed is easier using the kit LCD knob.

----------


## dacb

Personally, I would keep the LCD.  It can be the only place that some errors are displayed.  It is also useful for doing manual moves, etc.

----------


## AbuMaia

So who's interested in setting up a "bullet time" camera rig for their printer?  :Smile:  http://hackaday.com/2014/12/19/multiplexing-pi-cameras/

----------


## gmay3

Haha only to be used while printing a bust of Neo!

----------


## dacb

Ha ha!

Out of curiosity, is anyone use a non-USB camera with OctoPi right now?

----------


## AbuMaia

Nope, I'm using a USB webcam, though I'm considering getting the RasPi camera to use instead. It has more image controls, such as brightness level, so I can turn on my extruder LEDs without washing out the print area.

----------


## csader

I'm getting some pretty unpredictable behavior with OctoPi on my 512MB Raspberry Pi:

1. Commands often don't get received at all. Other times it seems they get put into a queue and take a long time to make their way to the printer. Right now I'm having trouble getting the Temp Set commands to be sent to the hotend and bed. Other times I have trouble getting the Z axis raise button to work.

2. Since yesterday, almost every time I try to print with OctoPi the print starts fine and about 5 seconds in just stops. No errors, just stops. The heat bed and hotend stay on, though. When I try manually loading the same gcode on an SD card, it works fine.

3. Today, I tried to start a print and Octopi was reporting the heatbed was at 110, while the LCD showed it was at 98. So the print tried to start with the heatbed way below temp. Tried stopping the print from Octopi immediately and it took about 2 minutes before it finally cancelled.

4. This might be a Cura thing, but I'm getting unpredictable pre-heating behavior. Sometimes the heatbed and hotend will heat at the same time. Sometimes the heatbed heats first, then the hotend. Can't figure out why.

----------


## csader

But of course, now that I've posted this, it's working great. Again, unpredictable...at least for me.

----------


## andyschneider

First off I'd like to thank you guys for this wonderful thread.

Unfortunately, I'm having issues with my files using OctoPrint. I can upload files to both the local and the SD card and I've tried .gcode and .gco extensions. I have no problems with this part. 

When I click 'load' or 'load and print' under "Files" nothing happens. This happens with any file I try, regardless of how I uploaded them or if they were already on the SD card. Delete doesn't work either.

I can change temperature and control the axis and the extruder through OctoPrint.  I can also start .gco files from the LCD on the printer which I uploaded earlier through OctoPrint.

I've tried using Chrome and Firefox and I'm in octopi.local. I feel like there might be a simple solution to this, or at least I'm hoping there is. 

Any suggestions?

----------


## kd7eir

Are you certain that you are connected to the printer when you are trying to load the files?

----------


## andyschneider

> Are you certain that you are connected to the printer when you are trying to load the files?


Almost certain, yes. I can change the temperature and move the axis and such from OctoPrint, so I think this means I'm correctly connected to the printer.

----------


## kd7eir

Sorry if I'm asking the obvious, but have you rebooted Raspberry? I have had several strange interactions with OctoPrint that were resolved by rebooting the Raspberry or at the very least restarting OctoPrint. Twice in three months I have been forced to re-image the SD card and start new with OctoPrint.

----------


## andyschneider

> Sorry if I'm asking the obvious, but have you rebooted Raspberry? I have had several strange interactions with OctoPrint that were resolved by rebooting the Raspberry or at the very least restarting OctoPrint. Twice in three months I have been forced to re-image the SD card and start new with OctoPrint.


No problem, thanks for your help. But yeah I've tried that. I've already re-formatted the SD card and reloaded OctoPi once. I feel like there's an issue with my browser but I don't know why... Are you just using octopi.local?

----------


## kd7eir

I am using the IP address. I had an issue once where custom system commands were not showing, and it never went away until I cleared the cache in my browser. Also, make sure that you are not using plugins in the browser - A plugin that helps with one page can wreak havoc with another.

----------


## clough42

I've been having similar problems, but it seems to be related to chrome or the naming on my network.  I've seen the same reboot-several-times kind of behavior, but I recently discovered that if I use the IP address, it comes up reliably.  I still haven't tracked down the issue.

----------


## clough42

> Ha ha!
> 
> Out of curiosity, is anyone use a non-USB camera with OctoPi right now?


Yes.  I'm using the raspberry pi board camera.  It's really convenient with this mount (shameless plug):  http://www.thingiverse.com/thing:489717

2014-10-05 22.49.19.jpg

The performance of the camera isn't that great, and the colors can be a little weird--especially under fluorescent lights, but it works.

----------


## clough42

> First off I'd like to thank you guys for this wonderful thread.
> 
> Unfortunately, I'm having issues with my files using OctoPrint. I can upload files to both the local and the SD card and I've tried .gcode and .gco extensions. I have no problems with this part. 
> 
> When I click 'load' or 'load and print' under "Files" nothing happens. This happens with any file I try, regardless of how I uploaded them or if they were already on the SD card. Delete doesn't work either.
> 
> I can change temperature and control the axis and the extruder through OctoPrint.  I can also start .gco files from the LCD on the printer which I uploaded earlier through OctoPrint.
> 
> I've tried using Chrome and Firefox and I'm in octopi.local. I feel like there might be a simple solution to this, or at least I'm hoping there is. 
> ...


First, I just stopped trying to use the SD card.  It's slow and I've had mixed results.  I just upload the files and print from Octoprint.

Second, there seems to be some kind of defect in the state of the Octoprint UI with respect to selecting files.  Sometimes the file is selected, the printer is connected, but it just won't respond to the print button.

When this happens, I select another file (click the file icon) and then reselect the file I want to print.  This clears the state and then I can print.

----------


## clough42

I have Octopi setup on both of my printers, and I'm loving it.  I'm powering the Raspberry Pi from the 5VSB bus of the power supply, so it is always on, and I can turn the 12V power on and off with GCODE using the power supply output on the RAMPS board.

Here's the wiring:

Raspberry Pi:
Powered through the GPIO port (be careful--there's no reverse polarity protection)One +5v pin to PS 5VSBOne GND pin to PS GND

RAMPS:
D1 cut or removedBoth + power terminals to power supply+12VBoth - power terminals to power supply GNDVCC to power supply 5VSB5V to power supply 5V or 5VSBPS-ON to power supply green wire

This way, the Pi is always on, and I can turn the 12V power to the printer on and off with GCODE M80/M81.  I have buttons defined in the Octoprint UI to do this, and I also do it in the start/end GCODE generated out of my slicer.

Some notes:

Because of the USB connection to the RAMPS board, it's always going to be on, too, so I just go ahead and connect RAMPS VCC to 5VSB as well.  No point trying to turn it on and off with the power supply--especially since you need it to handle the M80/M81 commands.  I also wouldn't count on the USB power from the Pi to power it (and the LCD).  Depending which version of the Pi, the RAMPS LCD, the WiFi dongle and the webcam, the internal fuses in the Pi can be overloaded and cause resets and lockups.  Running separate power to the RAMPS solves this.

The 5V bus on the RAMPS (used to power the Z probe servo) can be connected to 5V or 5VSB.  It doesn't matter.

I ran separate 5V conductors (20AWG) from the power supply to the pi and to each point on the RAMPS to try to keep noise (especially from the Z probe servo) from messing up the Pi.

----------


## clough42

Some photos of my setups:

2014-12-29 10.24.09.jpg2014-12-29 10.25.04.jpg

----------


## TopJimmyCooks

Looks like you got a longer cable for the camera - does it work well?  Where did you get it from?

----------


## andyschneider

I'm also using the Raspberry Pi camera board with a longer cable, I didn't notice any loss of image quality compared to the shorter cable. 

I bought a 24 inch long cable from Adafruit for 3 bucks: https://www.adafruit.com/products/1731  They have a variety of lengths as well.

----------


## TopJimmyCooks

What are the plusses/minuses of using a usb webcam v/s the pi camera?

----------


## kd7eir

I'm also using the Raspberry Pi camera with a 24" cable.

----------


## AbuMaia

I use a webcam. One of the minuses for it is if you have any LEDs on the X extruder carriage to light up your print area, they will often "wash out" the image so you can't see the print. There is no brightness setting for using a USB camera, as opposed to using the RPi camera. Another minus would be you'd have to come up with your own mounting solution if someone else hasn't designed one for your particular webcam, unlike the RPi camera, which has many mounts and cases designed for it already. A plus for the USB webcam is long cords, you can put it anywhere. So far all I've seen is a maximum of 24 inches for the RPi camera, which may limit its location options.

----------


## kd7eir

Here is my setup using part of a white LED strip for light. I need to print another holder for the lights in black instead of yellow, but I went with I had at the time. The Pi will eventually be mounted to the side wood at the top of the printer along with relays for controlling the power to the printer, fans, and lights.
Lights on:
2014-12-30 12.15.57.jpg

Lights off:
2014-12-30 12.16.22.jpg

----------


## sniffle

Has anyone come up with a fix for Octoprint and ABL line error timeouts?

I can't seem to print anything because octoprint is erroring because it is forcing lines instead of waiting on custom gcode to finish like G29 for ABL

----------


## AbuMaia

Increase the Communication Timeout to 300. That worked for me.

----------


## sniffle

> Increase the Communication Timeout to 300. That worked for me.



is that in code or a setting that i missed?

edit... i feel stupid :-P been fighting with this all day... and it seems to have made no difference

edit2: it would help if i would change the right variable...

----------


## clough42

> is that in code or a setting that i missed?
> 
> edit... i feel stupid :-P been fighting with this all day... and it seems to have made no difference
> 
> edit2: it would help if i would change the right variable...


It's in the settings dialog in the UI.

I think that has solved the last of my reliability issues.  The symptom on the timeout was that it would occasionally finish the ABL, run my prime and wipe sequence and then stop, with the nozzle on the bed, everything hot, and not actually print anything.  The terminal had lots of messages about retransmitting lines and the firmware deciding that it was getting the wrong line number.

----------


## clough42

> Looks like you got a longer cable for the camera - does it work well?  Where did you get it from?





> What are the plusses/minuses of using a usb webcam v/s the pi camera?


I got mine from Amazon:

http://www.amazon.com/gp/product/B00...?ie=UTF8&psc=1

The AdaFruit cable is cheaper--until you factor in shipping.  I have Prime, so...

I have one printer with the Pi camera and one with a Microsoft webcam.  The pi camera is easier to mount, and it works, but the colors are awful if you have fluorescent or LED lighting.  I had to break the lens loose and screw it out a turn or so to get the camera to focus close enough.  I'm also getting very slow frame rates from the Pi camera.  I would have thought it would be faster.

The USB webcam (Microsoft LifeCam Cinema) works great.  It has much better color and it auto-focuses, which is both a blessing and a curse.  The frame rate seems much better as well, and it doesn't seem to interfere with printing.  I don't have a mount for it yet, but probably will design something soon.

----------


## sniffle

> It's in the settings dialog in the UI.
> 
> I think that has solved the last of my reliability issues.  The symptom on the timeout was that it would occasionally finish the ABL, run my prime and wipe sequence and then stop, with the nozzle on the bed, everything hot, and not actually print anything.  The terminal had lots of messages about retransmitting lines and the firmware deciding that it was getting the wrong line number.


Yep with that fixed and the fan re rtsed i printed your x carraige without any warping :-)  now to print the rest and get ready to tear it all apart do i can rebuild and retune it :-P

To print tomorrow...

New unwarped abl mounts and foot... Part cooling will be needed at some point might as well go ahead and print it along with the makerfarm cold end...

Then its time to break it and make it better :-D

----------


## csader

> It's in the settings dialog in the UI.
> 
> I think that has solved the last of my reliability issues.  The symptom on the timeout was that it would occasionally finish the ABL, run my prime and wipe sequence and then stop, with the nozzle on the bed, everything hot, and not actually print anything.  The terminal had lots of messages about retransmitting lines and the firmware deciding that it was getting the wrong line number.


This may have been the same issue I was running into in my earlier post. I'll give this timeout setting a shot. Thanks all!

----------


## AbuMaia

Yeah, with the timeout at its original setting, OctoPrint would just keep firing off gcodes to the printer without waiting for an acknowledgement. And the printer is busy during a G29, and can't acknowledge. When G29 finishes and the printer finally opens up and starts taking commands again, it's expecting (say) command 29, while OctoPrint is sending it command 250. That's where the "wrong line number" comes from.

----------


## sajattack

Has anyone tried replacing their LCD with OctoPiPanel + PiTFT?

----------


## AbuMaia

Not yet, but I have been wondering if it was possible to connect the LCD to the RasPi.

----------


## sajattack

You're probably better off replacing it with the cheap 2.8" 320x240 full-colour touchscreens that adafruit sells. That's my plan anyhow.

----------


## sniffle

got my webcam in today and all setup :-)

Now i can watch my prints from another room or if it is a fairly short build i can build from work and watch to make sure nothing goes wrong :-)

sniffle.is-a-geek.net :-) for those bored people that like watching printers run :-P

----------


## paulpangrazzi

I was previously able to use Octoprint on my Raspberry B+ with the baud rate of 115200 (I think). After upgrading the Makerfarm/Ramps to the Itty Bitty Dual extruder, I can't connect at any rate. 

I see in configuration.h the rate is set at 250000 but every setting in Octoprint returns "Connecting..." until the timeout.

Any tips?



```
Changing monitoring state from 'Offline' to 'Opening serial port'
Connecting to: /dev/ttyAMA0
Connected to: Serial<id=0x29494b0, open=True>(port='/dev/ttyAMA0', baudrate=250000, bytesize=8, parity='N', stopbits=1, timeout=2.0, xonxoff=False, rtscts=False, dsrdtr=False), starting monitor
Changing monitoring state from 'Opening serial port' to 'Connecting'
Send: M105
Send: M105
Send: M105
Send: M105
Send: M105
Changing monitoring state from 'Connecting' to 'Closed'
```

----------


## kd7eir

You should be connecting to /dev/tty/ACM0.  /dev/tty/AMA0 is the built-in serial port of the Pi.

----------


## paulpangrazzi

> You should be connecting to /dev/tty/ACM0.  /dev/tty/AMA0 is the built-in serial port of the Pi.


Thank you. I swear, up until several minutes ago... there were only two options: Auto and AMA0... now the ACM0 port is available and working.

----------


## kd7eir

I fought that demon myself for quite a while. /dev/tty/ACM0 only appears when the Pi can see the RAMPS via USB. Not sure what causes it to not detect it at times. Restarting OctoPrint seems to resolve it most times, occasionally I have had to reboot the Pi itself.

----------


## clough42

> I fought that demon myself for quite a while. /dev/tty/ACM0 only appears when the Pi can see the RAMPS via USB. Not sure what causes it to not detect it at times. Restarting OctoPrint seems to resolve it most times, occasionally I have had to reboot the Pi itself.


I used to struggle with this as well as a number of other seemingly random instabilities.  I think the 5v regulator on the Arduino isn't really up to the task.  With RAMPS and the LCD, it's very close to what it can handle--even on the Taurino Power.  Adding a servo to the 5v rail caused me all kinds of instability.  In the end, I cutt D1 off the RAMPS board and supplied 5v from the power supply to the +5v and VCC pins (no jumper) as well as to the Raspberry Pi through the GPIO pins, all with separate runs back to the power supply.  This fixed pretty much all of the random symptoms I was having, including Octopi falling to start on boot and the Pi crashing or rebooting mid print.

----------


## paulpangrazzi

> I used to struggle with this as well as a number of other seemingly random instabilities.  I think the 5v regulator on the Arduino isn't really up to the task.  With RAMPS and the LCD, it's very close to what it can handle--even on the Taurino Power.  Adding a servo to the 5v rail caused me all kinds of instability.  In the end, I cutt D1 off the RAMPS board and supplied 5v from the power supply to the +5v and VCC pins (no jumper) as well as to the Raspberry Pi through the GPIO pins, all with separate runs back to the power supply.  This fixed pretty much all of the random symptoms I was having, including Octopi falling to start on boot and the Pi crashing or rebooting mid print.


How are you stepping down the 12v from your power supply? 

(I wish I could "star" various posts on this board and view them all together.)

----------


## printbus

> How are you stepping down the 12v from your power supply?


I believe Clough42 is taking advantage of the +5V Standby output from the ATX power supply he is using.

----------


## kd7eir

I use a 4-40V buck regulator to get 5V from the 12V line of my power supply. This in turn powers the servo and the Pi.

----------


## clough42

> How are you stepping down the 12v from your power supply? 
> 
> (I wish I could "star" various posts on this board and view them all together.)


I'm using the 5VSB output from my power supply.  That way, I can also connect the power supply switch line (green wire) to the PS-ON terminal of the RAMPS board, and I can turn the power supply on and off with M80/M81.  Since the Rpi and arduino are on the standby line, they're always on, waiting for me to VPN in and start a print job.

----------


## N5QM

Has anybody experienced random disconnections between the Pi and their printer?

While doing some testing today, on multiple occasions, I would get an error from the printer, according to OctoPrint, and it would disconnect.  Each time this happened it was in the first 20 seconds of a print.

I am thinking it might be a power related issue, any other thoughts?

----------


## AbuMaia

If you power your Pi from your printer power supply, that might be the problem. I have mine plugged into a phone charger, separate from the printer supply. I have not experienced any random disconnections.

----------


## sniffle

Same here i have my pi powered by a i believe 1.5amp phone charger and heavy gauge usb cable.  Its enough to power the pi and c310 camera witbout hiccups.

----------


## N5QM

Hmm...  Mine is powered from a 2A phone charger as well.  In thinking it might have been a power issue, I removed the camera, but still had the issue.

----------


## sniffle

Hmm... Odd... If the pi is rebooting that generallg means its drawing too much power... The cheap usb cables usually cant handle a decent current throughput the small wires just wont permit it... If you have a stock cell phone cable that is thicker/stiffer than the others you have try using it and see if it might fix the problem.  

Much like heated beds suffer on the 12" printer if you dont have 12awg wire because the smaller wire limits your current... Beyond that i wont be much help im not a pi or linux guru... I know just enough to get myself into trouble and google a way back out...

----------


## N5QM

It isn't rebooting, I just get some error message and the print stops abruptly.

The "terminal" provides an error from the printer saying that the current line isn't the last line +1 so it stops printing and the connection to the printer is closed.

----------


## N5QM

It just happened 3 times in a row...  :/

Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Changing monitoring state from 'Printing' to 'Error: Printer requested li...'
Recv: ok
Recv: ok
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: Resend: 59
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok
Recv: Error:Line Number is not Last Line Number+1, Last Line: 58
Recv: Resend: 59
Recv: ok

----------


## sniffle

Ooohhhh do you have abl enabled?

----------


## N5QM

No sir, I am running dacb's firmware though, with the no_abl configuration.h file.

As a test, I removed the wireless NIC and am using a cable now.  We shall see if it makes any difference.  At this point I am guessing.  haha

----------


## sniffle

Hmmm... It could be from you homing taking too long i know wierd... Later updates fixed it but if you start a print and watch the command line in octoprint and it starts yalking about forcing next line while it does your print star procedure you need to extrnd one of the timeout settings.  

I believe it is the communication timeout... But could be connection timeout... By extending that it forces octoprint to wait for the printer to be ready instead of octoprint trying to rush the printer when it cant.

----------


## AbuMaia

Yeah, it would be the communication timeout. I increased mine to 300 to accommodate ABL. The printer (for some reason) is ignoring incoming commands from OctoPrint while it does something, but OctoPrint keeps sending commands anyway. Then when the printer starts taking commands again, it's looking for line 25 (or so), while OctoPrint is sending it line 250. That's when it fails. Increasing the communication timeout makes OctoPrint wait longer for an "okay" from the printer before sending the next line.

----------


## N5QM

Excellent, thank you everyone.  I will make the changes and see if it settles down.

----------


## clough42

There are a few things that can cause this.

1.  Power issues:  The Pi needs a solid power supply.  The 5V regulator on the Arduino will not suffice.  If you have an ABL servo, this will make things even worse.  If you cut D1 (RAMPS) and power everything from the 5V rail of your supply, you should be okay.  Running separate wires from the supply to RAMPS +5, RAMPS VCC and the Pi is best.  Using a cell phone style supply for the Pi is probably also fine.

2.  Timeouts.  If you run an ABL sequence at the beginning of your job, OctoPrint can give up because it isn't getting anything back from the printer during the sequence.  If the carriage is high and it takes a long time to get back down to zero, the same can happen.  Increase the communication timeout in OctoPrint to fix this.  I think mine is set to 150 seconds.

3.  Floating endstops.  If you have your max endstops enabled with the pullups disabled, the printer will still work most of the time, but they can false trigger with power rail noise.  Make sure your max endstops are disabled in the firmware if you aren't using them.

----------


## N5QM

> There are a few things that can cause this.
> 
> 1.  Power issues:  The Pi needs a solid power supply.  The 5V regulator on the Arduino will not suffice.  If you have an ABL servo, this will make things even worse.  If you cut D1 (RAMPS) and power everything from the 5V rail of your supply, you should be okay.  Running separate wires from the supply to RAMPS +5, RAMPS VCC and the Pi is best.  Using a cell phone style supply for the Pi is probably also fine.
> 
> 2.  Timeouts.  If you run an ABL sequence at the beginning of your job, OctoPrint can give up because it isn't getting anything back from the printer during the sequence.  If the carriage is high and it takes a long time to get back down to zero, the same can happen.  Increase the communication timeout in OctoPrint to fix this.  I think mine is set to 150 seconds.
> 
> 3.  Floating endstops.  If you have your max endstops enabled with the pullups disabled, the printer will still work most of the time, but they can false trigger with power rail noise.  Make sure your max endstops are disabled in the firmware if you aren't using them.


Thank you sir, I will check the endstops just to be sure.  I am using one of those LED power supplies and now I realize I should have just used an ATX power supply.  Your statement about being able to power everything on and off made me realize that is an excellent idea.

----------


## N5QM

Guys, your suggestions seem to have sorted out my issues, thank you!

----------


## clough42

> Guys, your suggestions seem to have sorted out my issues, thank you!


Awesome!  Have fun.

----------


## gmay3

> There are a few things that can cause this.
> 2.  Timeouts.  If you run an ABL sequence at the beginning of your job, OctoPrint can give up because it isn't getting anything back from the printer during the sequence.  If the carriage is high and it takes a long time to get back down to zero, the same can happen.  Increase the communication timeout in OctoPrint to fix this.  I think mine is set to 150 seconds.


My octopi seems to be timing out/shutting off after I power it on and I think this timeout is to blame. Is this something you change in the settings through the normal browser octopi page?

----------


## sniffle

> My octopi seems to be timing out/shutting off after I power it on and I think this timeout is to blame. Is this something you change in the settings through the normal browser octopi page?



yeah it is in the settings options

----------


## gmay3

Woo hoo! Thank you guys!

----------


## N5QM

So....  If I were to get an ATX power supply with enough capacity on the standby 5v line, I could power the pi from it and use the PS-ON signal on the RAMPS board to power the rest of the system off, is that correct?

----------


## clough42

> So....  If I were to get an ATX power supply with enough capacity on the standby 5v line, I could power the pi from it and use the PS-ON signal on the RAMPS board to power the rest of the system off, is that correct?


Yes.  That's what I'm doing on both of my printers.  It's nice because I can leave the Pi on all the time and power up the printer remotely to start a print.  Assuming the Pi is stable, you can also shut down the power to the printer remotely if something goes wrong.

----------


## Drone

Has anyone tried a Rasberry Pi 2 yet with Octoprint? Gotta say I'm really interested in setting up a Pi with Octoprint and would prefer to get the 2 if it doesn't have issues other than no flash camera pics while printing. Definitely intrigued and ready to jump in.

----------


## hernejj

> Has anyone tried a Rasberry Pi 2 yet with Octoprint? Gotta say I'm really interested in setting up a Pi with Octoprint and would prefer to get the 2 if it doesn't have issues other than no flash camera pics while printing. Definitely intrigued and ready to jump in.


According to http://www.raspberrypi.org/raspberry-pi-2-on-sale/ the pi-2 is completely backwards compatible with the pi-1  :Smile: . So, in theory, you should be good to go.

----------


## hernejj

> According to http://www.raspberrypi.org/raspberry-pi-2-on-sale/ the pi-2 is completely backwards compatible with the pi-1 . So, in theory, you should be good to go.


Just to add a clarifying statement: The Pi-1 and Pi2 have different cpus, meaning images pre-compiled for the pi-1 will not work directly on the pi-2.
http://thepihut.com/blogs/raspberry-...raspberry-pi-2

So you cannot simply grab an OctoPi image and install it on a Pi-2. The above link does give instructions for converting an image to run on the pi. I would expect, from my experiences as a software developer, that it probably will not be as simple as they make it seem. A quick Google search turned up no evidence that anyone is working on porting, although someone must be somewhere.

With all that said, OctoPrint will very likely run without issues on the Pi-2. After all, it is just a piece of software, and the hardware environment is essentially "the same". But if you were hoping for the convenience of OctoPi, it looks like it will take a little more work.

----------


## sniffle

> Just to add a clarifying statement: The Pi-1 and Pi2 have different cpus, meaning images pre-compiled for the pi-1 will not work directly on the pi-2.
> http://thepihut.com/blogs/raspberry-...raspberry-pi-2
> 
> So you cannot simply grab an OctoPi image and install it on a Pi-2. The above link does give instructions for converting an image to run on the pi. I would expect, from my experiences as a software developer, that it probably will not be as simple as they make it seem. A quick Google search turned up no evidence that anyone is working on porting, although someone must be somewhere.
> 
> With all that said, OctoPrint will very likely run without issues on the Pi-2. After all, it is just a piece of software, and the hardware environment is essentially "the same". But if you were hoping for the convenience of OctoPi, it looks like it will take a little more work.



it "should work no matter the CPU, because it runs on the Debian(Raspbian) OS, you may need to compile it from source once Raspbian for PiV2 is released because it's written mostly in javascript/python

----------


## SgtToe

> Yes.  That's what I'm doing on both of my printers.  It's nice because I can leave the Pi on all the time and power up the printer remotely to start a print.  Assuming the Pi is stable, you can also shut down the power to the printer remotely if something goes wrong.


What size ATX power supply would my printer need to have on it to provide enough power for the 12" printer and the PI?

----------


## Drone

> Just to add a clarifying statement: The Pi-1 and Pi2 have different cpus, meaning images pre-compiled for the pi-1 will not work directly on the pi-2.
> http://thepihut.com/blogs/raspberry-...raspberry-pi-2
> 
> So you cannot simply grab an OctoPi image and install it on a Pi-2. The above link does give instructions for converting an image to run on the pi. I would expect, from my experiences as a software developer, that it probably will not be as simple as they make it seem. A quick Google search turned up no evidence that anyone is working on porting, although someone must be somewhere.
> 
> With all that said, OctoPrint will very likely run without issues on the Pi-2. After all, it is just a piece of software, and the hardware environment is essentially "the same". But if you were hoping for the convenience of OctoPi, it looks like it will take a little more work.


Thanks for the reply. Since it's early days for the Pi2 I think I'll wait just a bit to see if there are any compiling issues before I jump. I'm sure it'll be worth the wait rather than getting the B+ now though.

----------


## kd7eir

From the developer of OctoPrint:

Gina Häußge originally shared:
 
So I finally came around to flashing my current custom development version of OctoPi (incl. slicing via Cura and netconnectd) on a MicroSD and test it in the RPi2. I also flashed the exact same image on an equal card (both 8GB MicroSD, Transcend, class 10) and put that in an RPi B.

First of all: the first boot (where it needs to generate the SSL key and all that) is definitely faster. I didn't measure the time, but where it goes something like "wait for it wait for it waiiiiiiit for it" on the old one, it's more like "3, 2, 1, lift-off" on the new one.

Secondly: Slicing. I uploaded and sliced three STLs on both Pis, with results that made me giggle with joy:

STL1: RPi1 => 36.87s, RPi2 => 14.71s, Factor => 2.50
STL2: RPi1 => 173.85s, RPi2 => 69.55s, Factor => 2.49
STL3: RPi1 => 16.23s, RPi2 => 5.94s, Factor => 2.73

So slicing on the RPi2 with CuraEngine is about 2.5 times faster on that limited set of tested models.

Third, loading: An uncached reload of the main page (so without the new server side cache I added recently) until after the full handshake with the server through the websocket takes around 16s on the RPi1 and around 8s on the RPi2 - this IS noticable.﻿

----------


## clough42

> What size ATX power supply would my printer need to have on it to provide enough power for the 12" printer and the PI?


The 12V rail needs enough current to drive the printer.  I don't know what the requirements are for the 12" bed, but I'm sure it's in Colin's docs.

If you're running the electronics off the 5v line, any ATX power supply will have enough.  But if you're running off the 5VSB, I would think you would want at least 2A.  3A would give you some margin for the servo.  

I'm running HP server supplies that deliver 7.5A on the 5VSB bus and I recommend that route.  They're all over eBay.

----------


## PyramidDave

I am probably a glutton for punishment, but I ordered the Raspberry Pi model 2 B since MCM electronics had it for $35 & it does seem to run the octoprint.  I also ordered the
5MP Raspberry Pi Camera Board 
Wi-Pi Raspberry Pi 802.11n Wireless Adapter 
5V 2.2A Micro USB Switch Mode Power Adapter 
16Gb Sandisk Ultra MicroSDHC Class 10 Card
My router is within a couple of feet of the printer, so I did not really need the wireless usb unless I decide to move the printer to another spot in the house.  I also ordered a 24" flex cable for the camera from amazon that someone else mentioned.  I will see how this goes when the shipment arrives.

----------


## SgtToe

So I have a Pi B, and need to get a camera, if I buy the raspberry pi cam it won't tie up a sub port, if I go that route and use the two USB ports for the printer and wifi can I run without a powered usb hub?

also used book store has PS3 cams used for $15 but that would require the hub, is that printer just as good as the pi cam?


thanks

----------


## PyramidDave

I am not sure what your comment "is that printer just as good as the pi cam?" means.  I have only hooked this pi to my TV  so far & do not have it configured correctly yet.  It is nice to have the 4 usb ports.  I am using 3 of them with the mouse, keyboard & wireless adapter.  One way you could also save a USB plug would be to get a Network extender like the Netgear WiFi Range Extender WN2000RPT.  That way you could plug a network cable between the Raspberry Pi & the Range Extender & free up the usb port you are using for the wireless adapter.  I am not sure that would be less cost than getting a Raspberry Pi B+ or model 2 though.

----------


## sniffle

now that i have octoprint setup, i use 2 usb ports... 1 for the camera and 1 for the printer everything else is done over the network.  i were to resetup my wifi I would be using 3.  there isn't necessarily a need to worry about usb port usage.  the only real need for a usb hub is if you are using a camera that draws a lot of power.  i use a single cell phone usb power adapter with a 1.5 amp raiting, I run the raspberry pi that has the ethernet port the printer and the Logitech C310 webcam all hooked into it with no issues at all.  

I don't know what else you might plug into it really.  at one point i also had the suggested wifi adapter in use instead of the ethernet port and also had no issues.

----------


## SgtToe

> I am not sure what your comment "is that printer just as good as the pi cam?" means.


Sorry it was late when I posted the question.  I meant to say is the PS3 eye as good as the pi cam.  I want to save money but realize that if I buy the PS3 eye for $10 less than the pi cam then I will also need to buy a powered hub, if I buy the pi cam then I can skip the hub once the system us up and running and I don't need a kb and mouse.  Also seems like there are some neat enclosures for the pi and pi cam to print.  So will go that way unless anyone has some experience that would point me in another direction.

----------


## sniffle

It really depends on what you have amperage wise for your power source for the pi.  My wall to usb adapter puts out 1.8amps(corrected from previous post) it powers the pi and Logitech C310 webcam without the need for a powered usb hub.  I dont use the usb input to run my rambo board though so that may be why im not having any power issues.

----------


## AbuMaia

I have the printer, a Logitech cam, and wifi connected to my RasPi B+, all powered with a phone charger, and no powered hub.

----------


## kd7eir

I use a charger with a measured 2.5 amp capacity with my Pi 2. That eliminates any concerns about capacity. I have the printer, Pi camera, and wifi connected to it. I run 4-40 volt buck converter to derive 5 volts from the power supply to power my relays and led lighting. I have the Pi powered separately because I use it through the relays to control power the to printer itself, this way the Pi can stay powered on even when I shut the printer down.

----------


## SgtToe

> I use a charger with a measured 2.5 amp capacity with my Pi 2. That eliminates any concerns about capacity. I have the printer, Pi camera, and wifi connected to it. I run 4-40 volt buck converter to derive 5 volts from the power supply to power my relays and led lighting. I have the Pi powered separately because I use it through the relays to control power the to printer itself, this way the Pi can stay powered on even when I shut the printer down.


Are you saying you are controlling relays with the pi? If so how are you doing that?

----------


## AbuMaia

> Are you saying you are controlling relays with the pi? If so how are you doing that?


 https://github.com/foosel/OctoPrint/...-from-your-RPi

----------


## kd7eir

AbuMaia beat me to the link

----------


## SgtToe

> https://github.com/foosel/OctoPrint/...-from-your-RPi


Perfect, thanks!

----------


## clough42

> Sorry it was late when I posted the question.  I meant to say is the PS3 eye as good as the pi cam.  I want to save money but realize that if I buy the PS3 eye for $10 less than the pi cam then I will also need to buy a powered hub, if I buy the pi cam then I can skip the hub once the system us up and running and I don't need a kb and mouse.  Also seems like there are some neat enclosures for the pi and pi cam to print.  So will go that way unless anyone has some experience that would point me in another direction.


To be clear, the RasbiCam isn't that great of a camera.  Its big win is that it uses the separate camera port, so it doesn't take up a USB port.

Note that if you use it and want to mount it close to the printer, with just a view of the bed, you will probably need to adjust the focus.  You can unscrew the lens assembly (after breaking the adhesive that locks it in place) to shorten the focus.  I had to turn the lens out about one full turn to get acceptable focus where I have my camera mounted.

----------


## TopJimmyCooks

I'm no Linux guru to say the least, but I've been using Octoprint successfully for a while.  I can usually find files, edit them etc.  However, I want to add a few control buttons, and I can't locate one called config or config.yaml as referenced on the octoprint github faq.  I installed octopi from the card image , not from source.  Do you have these automatically under octoprint?  should I make a file and put my controls in it?  Thanks.

----------


## sniffle

ssh into the pi



```
cd .octoprint

sudo nano config.yaml
```

don't forget the . in front of octoprint.  that means it is a hidden folder.   that's why you can't find it...

https://github.com/foosel/OctoPrint/wiki/Configuration  it's on the 3rd line

----------


## TopJimmyCooks

blew it on the hidden folder period.  Thanks much for the help.

----------


## PyramidDave

I have my new Raspberry Pi 2 B all hooked up to my printer except for getting the PiCam to work within Octoprint.  I am using the 2015-01-31-octopi-0.11.0.zip image & everything seems to work except for the camera.  Does anyone know what I might be missing here?  I did enable the camera in the raspi-config.   I was able to see an image from the camera, so I know the camera does work.  I have not actually printed anything from octoprint, but I did test the x,y,z & temperature settings so far.

I also made a bracket for my Pi to attach to the left inside wood support on the opposite side of the board from the P/S & the P/S holds up & it is a snug fit sliding over the wood.  I wasted about a half pound of plastic getting it to the fit I wanted.  Here is the link on thingiverse for it: http://www.thingiverse.com/thing:705163
Here is what it looks like attached to my printer.

----------


## kd7eir

Try this in your browser - http://192.xxx.xxx.xxx:8080/stream_simple.html, inputting the IP address of your Octoprint.

----------


## gmay3

Hi PyramidDave, snazzy OctoPi case! Make sure you post this on the SHOW YOUR MODS sticky thread in case any one misses it here.

If you haven't already, you can join the Makerfarm thingiverse group here and add your case design here as well!
http://www.thingiverse.com/groups/makerfarm-i3v

----------


## PyramidDave

> Try this in your browser - http://192.xxx.xxx.xxx:8080/stream_simple.html, inputting the IP address of your Octoprint.


Thanks for the reply, but that still does not do it.  All I get is an little X image where I guess the image should be.  Is this maybe a permissions problem somewhere or is it trying to use a USB camera instead of the Pi Cam?  The little red light comes on the camera board after I enabled it. 
Here are my Webcam settings in Octoprint
Stream URL: /webcam/?action=stream
Snapshot URL: http://127.0.0.1:8080/?action=snapshot
Path to FFMPEG: /usr/bin/avconv
Timelapse bitrate: 5000k
Upload Folder: /home/pi/.octoprint/uploads
Timelapse Folder: /home/pi/.octoprint/timelapse


I am also not able to print yet.  I can move the motors & set the temperature, but when I uploaded a .gcode file that I sliced with Sli3r 0.99, it would not print it.  Any other suggestions?

Thanks,
David

----------


## N5QM

David,

I am also using a v2 as of last Friday and haven't had any issues, but I don't use the integrated camera.  A few suggestions..

SSH into the Pi and do a `sudo apt-get update` then `sudo apt-get upgrade` to ensure that all of the software on the system is current.
SSH into the Pi and do a `sudo rpi-update` to ensure you have the latest firmware, drivers, and kernel modules and reboot after this.

In regards to not being able to print, can you provide more details?  Does the printer show as connected?  What type of messages, if any, do you receive when you try to print?

----------


## PyramidDave

Thanks for the suggestions.  What fixed my problem was switching to Firefox.  I am ok with using Firefox for this, but does anyone know what settings in IE 11 that might be causing this not to function properly?  I am using Windows 7 Pro 64bit on a HP desktop machine.  I will try it on my Win7 laptop also to see if it has the same problem.

Thanks for your help.  Now I need to look into a good location for the camera.

----------


## PyramidDave

Is there a way to log the statistics from each print with OctoPrint or this data kept somewhere other than the /home/pi/.octoprint/logs directory?  I was using a batch file front end for pronterface to keep track of the daily print data.  I have been searching octoprint sites, but have not come up with anything.  I would like to at least keep track of Filenames & how much time each print took.  I found the octoprint.log file, but it does not seem to show any info about the prints.  I am not very familiar with Linux or python.

Here is what I am using with pronterface.  It keeps a log file for each day I print.  The filenames generated are Plog_YYMMDD.log

set /a UHH=%TIME:~0,2%
set OHH=0%UHH%
set HH=%OHH:~-2%
rem pronterface.exe >> "Plog_%date:~-4,4%%date:~-10,2%%date:~-7,2%_%HH%%time:~3,2%.log"
pronterface.exe >> "Plog_%date:~-2,2%%date:~-10,2%%date:~-7,2%.log"

----------


## tsteever

So everything I have read made it seem super simple installing Octoprint and octopi. Not the case so far. I think I was successful in getting the octopi image on the raspberry. I plugged it into my printer and tried going to octopi.local but nothing happens. I am using a Mac. What steps am I missing?

----------


## PyramidDave

I was not able to get th octopi.local to work for me either, but used the ip address in the address to access it.  http://xxx.xxx.xxx.xxx  substitute the xxx's with your id address.  I did read on this http://octoprint.org/download/ site that for windows you need to install "Bonjour for Windows" from apples site to be able to use octopi.local address.

----------


## tsteever

On a mac. How do I find the IP address of the PI?

Hopefully the web cam and iPad features will be easier to hook up once I get it connected.

----------


## sniffle

> On a mac. How do I find the IP address of the PI?
> 
> Hopefully the web cam and iPad features will be easier to hook up once I get it connected.



do into your router and look into the dhcp section, it will tell you what the pi's ip address is

----------


## PyramidDave

I do not know much about Macs.  Someone that know Macs on here might be able to give a better answer, but this page references a way to find that ip address on a Mac by installing nmap & using that to find the ip address, http://www.raspberrypi.org/documenta.../ip-address.md I used a google search for "how to find the ip address of a raspberry pi on a mac" to find this page.

----------


## tsteever

Okay, I am now looking at my printer in Octoprint! However, i cannot print anything. I can move the printer around an everything but when I hit print, nothing happens. Can seem to figure out how to get things on the raspberry card and printing. Got some reading to do!

----------


## PyramidDave

I had the best luck using Firefox & dragging & dropping the .gcode instead of using the upload button.  I have not tried safari browser with it.  Which browser are you using?  I manually set the temperatures before starting my print, then under the Action column I click the load button which looks like a open folder icon.  Then I hit the print button above the file names & it starts printing.

----------


## tsteever

Mine says sd card not initialized.

----------


## sniffle

> Mine says sd card not initialized.


you need to upload locally, the sdcard upload is if you also have an sdcard in your sdcard reader on the display

----------


## tsteever

Realized that late last night. Still can't print. When I select a file from the file picker the progress bar goes up and then down. If I click print, nothing happens. 

I also had an error show up the ONE time I was able to print something. I had a thermal runaway error and the printer shut off.

----------


## N5QM

> Realized that late last night. Still can't print. When I select a file from the file picker the progress bar goes up and then down. If I click print, nothing happens. 
> 
> I also had an error show up the ONE time I was able to print something. I had a thermal runaway error and the printer shut off.


Are you waiting for the printer to heat up?  It takes several minutes after you hit print for it to reach the appropriate temperature.  Until then, you won't see anything except the temperature graph change as the temperatures come up.

----------


## tsteever

Yup, waiting patiently. Just sits there. Often, it has trouble running commands from the terminal. It was so frustrating that I just opened up pronterface. I will work on it a bit more.

----------


## sniffle

sometimes, octoprint gets hung when an error occurs, when this happens just reload your browser or restart octoprint

----------


## tsteever

I still can't load files to print from octopi. The only time I can is if I have an SD card in the printer. I can't upload. Also, I can't load anything into the gcode viewer.

----------


## kd7eir

I recommend posting these issues to the OctoPrint community - https://plus.google.com/communities/...08349328485741

----------


## tsteever

Haven't had any luck posting there. Not sure why I can't upload locally. The progress bar quickly goes up and then back down, like it changes it's mind. I can only load files to the SD card. The gcode viewer doesn't load anything either. 

I am getting this on the terminal display...


Communication timeout during printing, forcing a line

----------


## sniffle

Did you expand your disk size after flashing the image?

If not that's why

When you ssh into the pi and your username is pi and password is raspberry that's what's probably wrong

----------


## AbuMaia

> I am getting this on the terminal display...   Communication timeout during printing, forcing a line


  Go into settings and increase the communication timeout, then.

----------


## tsteever

> Did you expand your disk size after flashing the image?
> 
> If not that's why
> 
> When you ssh into the pi and your username is pi and password is raspberry that's what's probably wrong


I thought I had followed the settings pretty closely and that I increased the size. I did not SSH but did it following Tom's guide as I have no idea what SSH even means. Well, I know what is is after reading countless hours on the Octo stuff. I just don't know how to do it.

----------


## sniffle

You followed toms guide you should be fine... But ssh is a good thing to learn as well as a general thing to know...

Yes communication timeout will fix that error... It usually comes from the printer expecting a line of gcode during an abl

----------


## PyramidDave

I did not see where you said which browser you are using.  I could not get the upload to work correctly with IE11 on Windows & switched to Firefox & it worked perfectly.  Have you tried Firefox on the Mac?

----------


## sniffle

> I did not see where you said which browser you are using.  I could not get the upload to work correctly with IE11 on Windows & switched to Firefox & it worked perfectly.  Have you tried Firefox on the Mac?


Chrome is another option... From windows though dunno about a Mac...

----------


## tsteever

Using Safari. I will try Chrome.

----------


## tsteever

Tried Chrome. It worked better. Still didn't get the real time updates on the viewer. Why does one browser work over another?

----------


## PyramidDave

I guess all browsers do not play by the same rules.  Since you had better luck with Chrome, you might also want to try Firefox to see if that works better.  I did not actually try Chrome.  I do not like Chrome as the last time I tried it,  it put a lot of its files in my profile rather than in its program folder.

----------


## PyramidDave

Are you using a wireless or wired Network connection?  If you are using wireless & can try it wired, see if that is the problem.  I have noticed video updates on mine being sluggish sometimes, but have not been able to determine the cause.  I thought it was a loose connection somewhere, but now suspect the wireless somehow.  I have the printer within 2 feet of my router, so I can use either one.  I am going to use it wired to the router for awhile & see if the problem comes back.

----------


## Drone

Got my Pi 2 in yesterday and spent a little time setting up OctoPrint today. Went very smoothly and it was setup and running in about 30 minutes. I setup the recommended 300s for the communication timeout and no issues with ABL. I haven't setup the camera yet, that will be the next step, but I have done all the network stuff like reserved IP for the Pi on the DHCP server, port forwarding and dyndns setup and it all just works beautifully inside the lan and over the internet. I'm really quite surprised it went so well. I was prepared for a battle, but honestly it was just very straightforward and works very well. Thanks for the intrepid users that spent the time figuring this out and posting here this out so I didn't have to! All the previous posts have helped a great deal.

Now I can start customizing the camera setup and adding relays for specific features.

----------


## sniffle

At least you can forward port 80 my ISP doesn't allow it... I have to access via port 5001...

----------


## Drone

> At least you can forward port 80 my ISP doesn't allow it... I have to access via port 5001...


Where is the config file for setting the forwarding port for camera viewing? I can set to a non-standard port and all features work except the camera viewing. I just haven't figured out how to set an alternate port for the camera viewing in the control tab. I can still view the camera by opening a separate browser tab and using the http port (80) when I set a different port for the rest of octoprint, but I would really like to change the port and have the camera view work in the control tab of octoprint.

----------


## sniffle

```
/etc/haproxy/haproxy.cfg
```

Change the frontend port marked by the *//*


```
global
        maxconn 4096
        user haproxy
        group haproxy
        daemon
        log 127.0.0.1 local0 debug

defaults
        log     global
        mode    http
        option  httplog
        option  dontlognull
        retries 3
        option redispatch
        option http-server-close
        option forwardfor
        maxconn 2000
        timeout connect 5s
        timeout client  15min
        timeout server  15min

frontend public
*//*        bind *:80
        use_backend webcam if { path_beg /webcam/ }
        default_backend octoprint

backend octoprint
        reqrep ^([^\ :]*)\ /(.*)     \1\ /\2
        option forwardfor
        server octoprint1 127.0.0.1:5000

backend webcam
        reqrep ^([^\ :]*)\ /webcam/(.*)     \1\ /\2
        server webcam1  127.0.0.1:8080
```

----------


## Drone

Thanks for the quick reply sniffle. This saves me a lot of searching. I'll set it up tomorrow as soon as my print job finishes.

----------


## sniffle

i just recently figured it out myself... glad i can help

----------


## Drone

Thanks again sniffle. I edited the haproxy.cfg and setup the port I wanted to use, setup the forwarding in my router and it's working exactly as intended.

It's hard to believe a $35 Raspberri Pi is doing the same job I had a $2500 computer doing, and it's doing it well. I've got a camera setup and gave my dyndns info to a few friends and they are just blown away. I'm playing with the optimal timelapse settings now and seeing what I can do with that. It's not really all that useful, but definitely cool for a geek.


The only thing I would like changed at this point is adding a password to allow just viewing. I would much rather that the system doesn't allow just anybody to view without any access control, but I haven't seen a way to do this yet. I see there is access control for admin and active users, but I don't see a way to add requiring a password just for viewing. If anyone knows of a way to set this up it would be appreciated.

----------


## sniffle

do you really need a password for that? nothing can be clicked on or used so there is no real point.  you can setup a webpage that you can password that only shows tge raw stream... but i'm not sure how to go about it.

----------


## Drone

> do you really need a password for that? nothing can be clicked on or used so there is no real point.  you can setup a webpage that you can password that only shows tge raw stream... but i'm not sure how to go about it.


Yeah, I really would like a password for viewing. The main reason is that I don't want unfettered access to real-time build streaming of proprietary new designs I'm working on. But I still want to be able to remotely view the print in progress for myself (and anyone I trust to view the live stream). Not a really big deal I guess, but would be a nice feature.

The controlled access website is a good idea and maybe when I get some time I'll look into that.

The easy workaround is to change the streaming port address and forwarding so it doesn't work for the people that accessed it earlier and just change the port back if I want to grant them access. Not nearly as elegant as a simple password access to viewing though. But it's effective. I also have to be careful to remove timelapse videos before I give access since that is unrestricted for guest downloads also.

But the above being said, Octoprint has far exceeded my expectations and I can't imagine not having it now.

----------


## PyramidDave

I have been playing with this for a couple of weeks now & noticed the Wi-Pi Raspberry Pi 802.11n Wireless Adapter I bought transmits the video very choppy relative to a wired connection.  I should have looked into this a little more before getting that adapter.  I just realized that is only running at 150Mbps.  My pi is only a couple of feet from the router, but it is nice to have 1 less wire attached.

I found a Panda 300Mbps Wireless-N USB Adapter w/ WPS button for $17 on Amazon that I think might buy. Here is the link to it on Amazon. http://www.amazon.com/gp/product/B00...A1K5RDMQ6V4659
Anyone have any experience with this adapter?  The WPS button should make it easier to setup on a wireless network if your router supports this.

I am also going to go back to using Pronterface until there is a way to keep a log of print files automatically.  I put a message on the octoprint discussion board about how this can be done.  Apparently it is not possible yet, but sounds like someone there might make a plugin to do this.  I have programmed in a few languages, but not python.  Maybe I will look into seeing if I can do something with this  also.

----------


## SgtToe

> https://github.com/foosel/OctoPrint/...-from-your-RPi


So while I wait for my printer to arrive I figured I would get the RPi and the relay working.  And had some questions after reading this and watching some youtube videos.

Concerning hooking the pi to the relay he says:


connect JD-VDD to one of the 5V pins on the Piconnect VDD to 3.3V (these two power the relays)
The 6-pin-header is to be connected as follows:

connect GND to Ground (surprise ;D)connect VCC to the other 5V pinconnect IN1-IN4 to the remaining pins

Question Are:
1.  He refers to plugging some 6 port header into the remaining pins, really we just need VCC to 5v, Ground to ground, and one GPIO pin going to one of the 4 relays right? No clue what 6 pin header he is talking about. I think he is using just pin 18

2. Why pull the jumper and power those other two pins separately?

----------


## clough42

> So while I wait for my printer to arrive I figured I would get the RPi and the relay working.  And had some questions after reading this and watching some youtube videos.
> 
> Concerning hooking the pi to the relay he says:
> 
> 
> connect JD-VDD to one of the 5V pins on the Piconnect VDD to 3.3V (these two power the relays)
> The 6-pin-header is to be connected as follows:
> 
> connect GND to Ground (surprise ;D)connect VCC to the other 5V pinconnect IN1-IN4 to the remaining pins
> ...


He's talking about the 6-pin header on the relay board.  The 4-channel boards have a header with power, gnd and four signal lines.

The rest of the instructions are about supplying 5V to the JD-VCC line, which powers the relay coils and 3.3V to the VCC line, which powers the LED side of the optoisolators, which are connected to the GPIO pins.  Technically, this is correct, because the RPi GPIO pins are 3.3V logic.  It's also probably not necessary, since there are two diode drops in the circuit.  I have been running 5V SainSmart relay boards off the GPIO pins of a Model B for months without any apparent issues.

----------


## SgtToe

> He's talking about the 6-pin header on the relay board.  The 4-channel boards have a header with power, gnd and four signal lines.
> 
> The rest of the instructions are about supplying 5V to the JD-VCC line, which powers the relay coils and 3.3V to the VCC line, which powers the LED side of the optoisolators, which are connected to the GPIO pins.  Technically, this is correct, because the RPi GPIO pins are 3.3V logic.  It's also probably not necessary, since there are two diode drops in the circuit.  I have been running 5V SainSmart relay boards off the GPIO pins of a Model B for months without any apparent issues.


Ok, thanks for the answer clough42.

----------


## clough42

> Thanks again sniffle. I edited the haproxy.cfg and setup the port I wanted to use, setup the forwarding in my router and it's working exactly as intended.
> 
> It's hard to believe a $35 Raspberri Pi is doing the same job I had a $2500 computer doing, and it's doing it well. I've got a camera setup and gave my dyndns info to a few friends and they are just blown away. I'm playing with the optimal timelapse settings now and seeing what I can do with that. It's not really all that useful, but definitely cool for a geek.
> 
> 
> The only thing I would like changed at this point is adding a password to allow just viewing. I would much rather that the system doesn't allow just anybody to view without any access control, but I haven't seen a way to do this yet. I see there is access control for admin and active users, but I don't see a way to add requiring a password just for viewing. If anyone knows of a way to set this up it would be appreciated.


I solved the remote monitoring with a VPN.  All of my printers have Octopi setups on my local, private network, and then I have OpenVPN set up at the gateway.  That way, I can connect in with a laptop, tablet or even my cell phone to monitor and control prints when I'm away from home.  Everything is encrypted and I'm not exposing OctoPrint to the outside world.

I'm using Untangle NG-Firewall as my gateway/router, so the OpenVpn setup was easy.

----------


## SgtToe

Need some help, I have my pi setup and octoprint installed, my printer is on order so obviously I don't have a printer hooked to the pi.  When I don't have the camera plugged in it complains every 2 min about no camera.  Now that I have the camera hooked up it no longer complains, but when I go to the page I see the graph of the temp and the other tabs, but I don't see any picture, what tab should it be on?  Does a printer need to be hooked up for the camera to work? I have the Xbox web cam and it says it is supported as is out of the box.


2nd question, I read that octopi.local should work on a windows pic if I install bonjour, it does not work from my iPad either, any idea why?  It does work if I use the ip.


**
edit I just checked with safari from my iPad and everything works! so octopi?local and video both ok via safari but not with chrome

----------


## PyramidDave

I discovered that the video will not work under Windows Internet Explorer.  Works on browsers that support Mjpg-Streamer.  IE does not supportthis.   Here is a link to a page that describes that problem.    http://www.raspberrypi.org/forums/vi...=8659&start=25

I just use the ip address in my browser.  I did not want to install bonjour on my windows machine.

----------


## clough42

The image should appear on the Control tab.

In Chrome, try "http://octopi.local"

Chrome can be very aggressive about searching instead of visiting local network sites.

----------


## SgtToe

> The image should appear on the Control tab.
> 
> In Chrome, try "http://octopi.local"
> 
> Chrome can be very aggressive about searching instead of visiting local network sites.


Any idea why the video works in safari but not chrome?  when I use the IP that is.

Also the video is delayed about 4 seconds and seems chopy, is this normal?  is it because I am using a usb camera and if I used the pi cam it would be much more fluid since that uses a different data bus?  Is it that the default is 10 fps?  Do folks up that?

----------


## clough42

Not sure about the video working in Safari.

Delayed and choppy video isn't that unusual.  There are a lot of factors.  Not all cameras are created equal.  If the camera can natively provide an mjpg stream, the pi doesn't have to do much.  With other cameras, the pi has to do a lot of computation on the video stream.  The pi camera is good because it doesn't use USB bandwidth, but I get better, more responsive video from a Microsoft LifeCam.

----------


## Drone

> Any idea why the video works in safari but not chrome?  when I use the IP that is.
> 
> Also the video is delayed about 4 seconds and seems chopy, is this normal?  is it because I am using a usb camera and if I used the pi cam it would be much more fluid since that uses a different data bus?  Is it that the default is 10 fps?  Do folks up that?


Your video should be pretty smooth if viewing from inside the LAN, but across the internet I have found it is very choppy and lags quite a bit behind the actual print. I haven't found a cure for the laggy performance across the internet when connecting directly to the Pi, but if you remote into a local computer to the Pi (from the internet) and connect to the Pi from there it is smooth and immediate. I have also changed the frame rate to 20fps from the default 10fps although it was quite smooth at 10fps. You can edit video resolution and fps (either USB camera or a Pi cam) in the /boot/octopi.txt file.

Remoting into a local computer to connect to the Pi also solves my problem of allowing protected access to print viewing for me since I can control username and password to the remotes easily. I'm using virtual machines through Hyper-V and my 2012 server and have 3 virtual Win 8.1 machines setup for this so I can allow multiple viewing access at once. I have them setup so when logging into the VMs it has restricted access to the VM and opens Chrome and logs into the Pi automatically so my friends just enter a username and password at the login screen and OctoPrint starts immediately. And even with 3 logged in it is very smooth video.

BTW, you don't need a server for this. If you have a Win8 machine at home you can have Hyper-V and one VM running concurrent with your console session. It's a free addon to Windows 8 and 8.1 (but you will need a license for the virtual machine OS... but you can use the Win 8.1 Enterprise evaluation for 120 days for free or use the Windows 10 technical preview for free if you prefer). So with Windows 8 Hyper-V you can have 2 people using the Win8 machine at the same time. 

The difference with the video streaming is night and day when logged in from a LAN source rather than across the internet, even though you are remoting into a computer from the internet. Maybe there is a way to get the Pi server to handle internet connections better and I just haven't found it yet. But this makes a big difference for me.

----------


## TopJimmyCooks

I just use teamviewer to remote into a home pc and open an octopi browser window.  Easier than accessing the pi over the internet for us non linux guys.

----------


## SgtToe

Thanks for all the info, I will edit my ocotopi.txt and bump the frame rate up to 20. I think the choppyness I am refering to is because of frame rate.  When I wave I see my hand on the right side, middle and left side, I donn't see it move across the screen.

My setup is all local, not over the internet, it is all wireless, but there is definitely about 3-4 second delay.  I can walk over to the camera and wave and then walk back to my computer just in time to see myself arrive at the camera and wave.  Does the amount of light slow the camera down?  Does it try and compensate some how?  All my testing was in pretty low light.

Printer will arrive Monday, so this weekend I need to get the relay working with octoprint so I can turn power on and off.

----------


## Drone

> I just use teamviewer to remote into a home pc and open an octopi browser window.  Easier than accessing the pi over the internet for us non linux guys.


Teamviewer should provide the same results and give much better internet stream than the built-in Pi internet streaming TJC... great idea. And Teamviwer (also VNC) can be had for free. So even better.

----------


## Drone

> Thanks for all the info, I will edit my ocotopi.txt and bump the frame rate up to 20. I think the choppyness I am refering to is because of frame rate.  When I wave I see my hand on the right side, middle and left side, I donn't see it move across the screen.
> 
> My setup is all local, not over the internet, it is all wireless, but there is definitely about 3-4 second delay.  I can walk over to the camera and wave and then walk back to my computer just in time to see myself arrive at the camera and wave.  Does the amount of light slow the camera down?  Does it try and compensate some how?  All my testing was in pretty low light.
> 
> Printer will arrive Monday, so this weekend I need to get the relay working with octoprint so I can turn power on and off.


Even 10fps should give smooth video over a LAN connection, at least it did with mine. I would guess it is wireless latency. With a 150mbs wireless dongle and 10fps mine was very smooth on the LAN, and was very smooth when remoting into a local PC accessed from the internet. Just as a test I also used a 300mbs wireless adapter and didn't see any improvement, so I'm guessing a good 150mbs adapter should be fine. If possible, move the printer close enough to the router to run a direct ethernet cable and run something like a G29 ABL command and see if the results get better.

----------


## clough42

> Even 10fps should give smooth video over a LAN connection, at least it did with mine. I would guess it is wireless latency. With a 150mbs wireless dongle and 10fps mine was very smooth on the LAN, and was very smooth when remoting into a local PC accessed from the internet. Just as a test I also used a 300mbs wireless adapter and didn't see any improvement, so I'm guessing a good 150mbs adapter should be fine. If possible, move the printer close enough to the router to run a direct ethernet cable and run something like a G29 ABL command and see if the results get better.


Wireless is always sketchy for this kind of stuff.  It's not just the max bandwidth.  It's also about latency, latency distribution and the USB hardware behind the dongle in the Pi, which of course competes with the USB camera.

----------


## lakester

I've skimmed the thread beforehand..., and what I'm wondering is why the OctoPi does better wrt the USB connection with the printer than, say, your typical PC/laptop/Mac/etc/etc.  Does OctoPi drive the printer directly via gcodes through the USB interface, OR, does it simply upload the gcode to SD on the printer's controller?  Thx!

----------


## clough42

I don't know if it's better than a PC.  I guess it depends on the software.

OctoPrint has the ability to upload to the printer's SD card, but most people just print directly from the Pi.  OctoPrint feeds the lines of GCODE directly to the printer firmware as the printer prints.  It uses line numbers and monitors the printer's responses, so it can re-send missed lines automatically.

----------


## lakester

OK..., cool.  It has both options.  Thx!




> I don't know if it's better than a PC.  I guess it depends on the software.
> 
> OctoPrint has the ability to upload to the printer's SD card, but most people just print directly from the Pi.  OctoPrint feeds the lines of GCODE directly to the printer firmware as the printer prints.  It uses line numbers and monitors the printer's responses, so it can re-send missed lines automatically.

----------


## jimc

its better because there arent ton of background processes going on in the operating system that can disrupt the stream of gcode. the pi will be a dedicated computer with the only svc running is octoprint.

----------


## clough42

In general, though, the reason most people use OctoPrint is because it puts the printer on the network so you can start jobs and monitor progress remotely, and it does this with a very inexpensive Raspberry Pi.

This is especially awesome if you have several printers.

----------


## CalifDan

I am having a minor little problem.  Maybe self induced...probably self induced.  I got all excited about building my next Makerfarm about 6 months ago.  I got all the parts including the Bulldog, E3dv6, and the raspberry pi and associated stuff.  And then life got in the way.

I got back to it a few weeks ago and have much of the Makerfarm printer together.  A few days ago, I decided to wade into the Raspberry Pi and re-read this forum.  I don't have an HDMI monitor, but I do have the little 320 x 240 mini monitor that attaches to the Raspberry Pi.  I also have a little keyboard and the wireless adapter.

I got this up and running without too much of a problem.  Keep in mind, the Pi is running separate from the printer at this point.  I am able to Putty into the Pi.  I did all the updates and upgrades.  I can see Octopi in the browser.  I have made the lan address on the Pi fixed.

What I am having trouble with is the Camera.  I ordered one of the Raspberry Pi cameras.  It is plugged into the appropriate connection and I have even tried two different connectors.

When I boot the Pi, it goes through every thing but it does not find a camera.  I get the message that the camera was not found and will try again in two minutes.

I am either missing something really simple, or maybe the camera is bad out of the box.  Any suggestions on where to start?  I have reviewed this thread and while I found a similar problem, I am not sure I saw a solution.

----------


## PyramidDave

I had some trouble with the raspberry pi camera at 1st.  My 1st problem turned out to be using a browser that does not support Mjpg-Streamer.  When I switched from IE to firefox that problem went away.  Here is the link again that describes that problem https://www.raspberrypi.org/forums/v...=8659&start=25
Another problem I had was using a slower wireless connection.  I had video with the slow wireless connection, but it was choppy.

If you are using Internet Explorer for your browser, switch to Firefox, Chrome, Safari or Opera & see if it works.

----------


## CalifDan

Thanks.  Worked on it early this morning and found the issue.  I got the Pi with a TFT monitor.  I set up the Octopi image (without the camera attached the first time) and then added the recommended packages to run the TFT monitor.  Once I had that running, I plugged in the camera and it would not work.

This morning, I reflashed the sd card with Octopi and booted with the camera already attached (as well as the TFT monitor).  Surprise....the camera works.  So I went ahead and set up Wifi (no problem) and then I went through the process of setting up the TFT monitor.  The camera stopped working.  It appears that the code to add the camera either interferes with or removes the code to run the camera.  Or, the TFT and the camera do not work together.

So, I went back again, reflashed Octopi, configured and set up Wifi.  All is working now.

The TFT screen is not necessary, either to set up the Pi or for ongoing operations.  When I bought it all, I thought it might be necessary to set up the Pi.  You don't even need an HDMI monitor.  I just hooked it up to my lan and then found the ip address from the router.  Then I used Putty to log into the Pi.  I was able to do everything necessary right from there.

Octopi loads in the browser.  I can't test the connection to the printer until I get it hooked up.

Next steps will be to finish up the new printer with the Pi included.

----------


## dacb

That's great to hear that you got it working, Califdan.

As a datapoint, I recently did a Pi2 test and installed a stock image, the octoprint source and mjpg-streamer via git and then added enough service files to get the webcam and flask app to start up.  I had to make one change for the USB camera to make it work in the mjpg-streamer config.  Unfortunately, I didn't make a note of it but it is a known issue with the pi2 and the USB camera output mode.

In the end, it really isn't worth using a Pi2 on this.  The PiB is more than enough to handle the modest demands.  I have heard that people using Cura on the Pi to do slicing have seen significant performance improvements, but to be honest, slicing on the Pi never seemed useful to me. I'm always doing rotations and multi-piece repacking and the GUI on my Mac was preferred for this kind of activity.

So, in the end, I went back to a standard Pi model B and reinstalled from the octopi distribution.

YMMV, but I'd say, don't bother with a Pi2 for this purpose.

----------


## kd7eir

I tested OctoPrint with my Pi2 as well. It certainly loaded the web interface very quickly, but the actual operation was really no different than with my Pi B+.  I kept the B+ for OctoPrint and use my Pi2 for other tasks.

----------


## PyramidDave

I saw someone was looking for a way to clear their prints off the build plate remotely.  There was a new design on thingiverse that seems to handle that problem.  Take a look at this novel design if you have not seen it. http://www.thingiverse.com/thing:872617
It probably would not work well for buildtak or similar surfaces.  I have to pry parts off with a knife from the buildtak surface sometimes.

----------


## tsteever

Trying to get Octoprint to work and when I try and print something I get a waiting for user message on the LCD display. Nothing prints.

----------


## clough42

> Trying to get Octoprint to work and when I try and print something I get a waiting for user message on the LCD display. Nothing prints.


It's a known issue for this to happen with Pronterface connected and monitoring temperatures.  I have never seen it with Octoprint.  With Pronterface, clicking the dial on the printer LCD acknowledges the message and allows the printer to continue.

----------


## dacb

I have seen this with Octoprint and auto bed leveling enabled.  The host side will timeout during bed probing.  The pathology I saw was during the bed probing, octopi will timeout and the printer will display a message "M105" and stall until the user presses the the dial on the printer LCD as clough42 describes.

Once I changed all of the timeout settings (except auto detect) to 30 seconds this stopped happening.

----------


## clough42

> I have seen this with Octoprint and auto bed leveling enabled.  The host side will timeout during bed probing.  The pathology I saw was during the bed probing, octopi will timeout and the printer will display a message "M105" and stall until the user presses the the dial on the printer LCD as clough42 describes.
> 
> Once I changed all of the timeout settings (except auto detect) to 30 seconds this stopped happening.


You may need much more than 30 seconds for homing if the carriage is way up high.  I think I'm running something more like 150 or 200.

----------


## singhm29

Has anyone implemented these neat add ons sucessfully? 

Automatically upload timelapses to Youtube 
Send an email after a print finishes with a snapshot 
( https://github.com/foosel/OctoPrint/...ful-Eventhooks)

I have been trying to get these working to finish off my install but whenever I modify the config.yam1 file the server becomes inaccesible and I get a 503 error on my webbrower if I access it locally or over the internet. I feel like I dont get the syntax correct for adding these changes but if anyone else has managed todo this and could shed some light it would be much appreciated.

----------


## PyramidDave

With a google search, I found these 3 web pages that may help you with yaml syntax.

http://docs.ansible.com/YAMLSyntax.html
http://ess.khhq.net/wiki/YAML_Tutorial
http://docs.octoprint.org/en/devel/c...nfig_yaml.html

----------


## singhm29

> With a google search, I found these 3 web pages that may help you with yaml syntax.
> 
> http://docs.ansible.com/YAMLSyntax.html
> http://ess.khhq.net/wiki/YAML_Tutorial
> http://docs.octoprint.org/en/devel/c...nfig_yaml.html


That was very very helpful turns out I was spacing things incorrectly. Thanks alot.

Unfortunately I've hit a new roadblock. Previously I didnt have an issue connecting to the printer and I hve tested moving the printer axes before. Now after uploading my first file it throws an error when i try to connect to the printer saying Machine Status: Error:volume.init failed. Any ideas what might be causing this?

----------


## singhm29

Hmm I take that back turns out just because the server error is gone doesnt mean I entered the information in correctly...I commented out the section I added and tried again and was able to connect. Damn it.

----------


## PyramidDave

At least it is working for you now.  Hope you figure it out.  I have not tried the task you are attempting.  Maybe someone else here will have a suggestion for you.

----------


## kd7eir

I have gotten both of those eventhooks properly coded in config.yaml, but they have never actually done anything. No errors at all, just no emails and no video uploads.

----------


## singhm29

> I have gotten both of those eventhooks properly coded in config.yaml, but they have never actually done anything. No errors at all, just no emails and no video uploads.


 Enable access for less secure apps via the security options for the email (im assuming gmail) your using to send you the snapshot. What I found was the code was working but it was being blocked by Gmail. That should at least get the email a snapshot event working

----------

