Jump to content
  • 0

Cannot connect to Moonraker


Haziq

Question

Hi everyone, this is my first time building a Voron 2.4r 3D printer. I have several question and challenges that I faced as I building the printer.

1. For now, I already installing mainsail on my raspberry pi (Raspberry pi 4). I always get an error 'Cannot connect to Moonraker (mainsailos.local)'.

Sometimes, the web interface is working at first but suddenly the error is come out again. Why is it happened and how to solve it?

2. How many Micro SD card need to be used? Should I use 2 (1 for Raspberry and 1 for BTT octopus)?

I really need help on these

Thank you

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 1

You'll need two SD card temporarily. You, permanently, need a largish SD card (16GB or more) for the Raspberry PI since that will effectively be the OS disk. Then you need a smaller sized SD card (size is probably immaterial but I wouldn't really go beyond 16GB) for the BTT Octopus to flash the Klipper "driver" or firmware onto it. The "klipper.bin" file that you generate on the raspberry PI ("make menuconfig", remember the "klipper.bin" needs to be renamed to "firmware.bin" on the SD Card) is around 25KB in size thus why the second SD card can be tiny (in reality it's quite hard to get sub-1GB SD cards). You only need the second SD card for the flashing process, once the BTT Octopus is flashed then you can remove the SD card.

I believe it is also possible to flash the controller board over the USB (serial) connections, however, I have always used the SD card flashing method. The only time I directly flashed klipper directly over USB was when flashing an ANET Controller board but that is based on the older 8-bit AVR chips.

I appreciate that's just a high-level answer, but if you need to know more just ask and I'll do my best.

  • Like 1
Link to comment
Share on other sites

  • 1

I did a bit of digging, according to the klipper documentation it is quite easy to directly flash the controller board from the raspberry pi (running klipper) using the "make flash" command. I guess as long as there is a boot loader on the BTT Octopus (which I'm 99.9% certain there will be)  and you can identify the name of the USB connection on your raspberry PI (it's all in the Klipper documentation linked). I think I'll try it as part of my next Voron build which I started yesterday.

Whichever method you use to flash the controller board, you don't permanently need a second SD card in the Octopus board.

As for your issue connecting to moonraker, at the risk of sounding like so many not necessarily helpful people on forums (sorry!) I think we need a bit more information otherwise I would be majorly guessing. I would suggest looking in the "moonraker.log" files they generally  live in the "klipper_logs" directory which is generally in the main user's home directory (if you've  gone for a fairly bog-standard PI install the main user will be "pi" so the directory will be "/home/pi/klipper_logs"). Depending how on long the system has been running for there could be multiple historic log files e.g. "moonraker.log.1", "moonraker.log.2", etc. Have a trawl looking for obvious errors - by that I mean something say "error" or "exception" or "cannot find". That is a good starting point to diagnosing the issue.

Am I correct in thinking the issue is intermittent?

 

Out of interest were you using something like the "MainSail OS" image or was it a basic linux image that you have added mainsail and klipper into.

 

  • Like 1
Link to comment
Share on other sites

  • 0

I had this yesterday and for me it was (very weird but verified) the DNS given by DHCP server.
I dont use fixed IP's but reserve the IP's in DHCP for everything, but even if using a fixed IP, the DNS server entries are important.

I tried different DNS servers because I will be switching providers and used the provider DNS servers, and I changed them.
Somehow I thought it was a good idea to use SurfShark their DNS server, but that didnt work, so went to 1.1.1.1 and 8.8.8.8 as reserve.

I was surprised by this, but, it really was the root cause of my issue, it threw out Cannot connect to Moonraker error, on both printers.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...