How Do I Install? Raspberry Pi and WebControl setup for complete beginners

I wanted to do a write-up of my experiance with setting up WebControl since it involved a lot of learning and “first-time” experiances for me. I followed MadGrizzle’s instructions to get set up (along with a lot of help in a private message) but I added my own bits of info for anyone with less skill than myself. Grizzle made all the steps and I added things after the dash

“1. MadGrizzle is the man” (I borrowed these steps)

-My notes (I added this stuff for other beginners like myself)

PREFACE:
-If you’re like me, you know what raspberry pi is and have always wanted to try it out. I never had a specific project I needed one for until the Maslow. I got a 3B+ from adafruit. I was able to 3D print a case for myself. If you don’t have a printer, I’d recommend buying a case and also a good power supply. I found this one one Amazon for a decent price. I would NOT recommend just finding any old micro usb phone charger you have laying around. You also need a micro SD card with at least 8GB of storage (for full raspbian install, more on that later). I’ve had luck with SanDisk brand and try to stick with them (although a good friend of mine just told me that many fake SD branded cards are out there). I’ve used older, 8GB cards and brand-new 16GB with good results. I get mine on Amazon. You will also need a USB-A to USB-B cable. You only need a very short cable unless you plan on having the Rpi some distance from the Arduino. If you don’t have a spare one laying around from an old printer or other device, here’s one on Amazon. You can also find all of this on Adafruit.

-I did all of this with the Rpi 3+ hooked up to a monitor with HDMI and also using a wireless mouse/keyboard combo with a USB dongle. I recommend getting this set up before you do your first boot so you can have full control of the Rpi.

START HERE:
Step 1: Download and install PiBakery from:

pibakery.org

-This file is HUGE, give it some time.

Do NOT download PiBakery V2

Step 2: Download this recipe from the webcontrol github repo:

https://raw.githubusercontent.com/madgrizzle/WebControl/master/webcontrol-us-recipe.xml

If you right-click the link, it gives you the option to “save link as…” to save the file to your computer… If you click the link, you’ll get a page of raw of XML, but you can then right click on the page and select “save as…” to save it.

Step 3: Startup PiBakery. I think it downloads stuff for a while when it starts…

Step 4: Import the webcontrol-us-recipe.xml file.

-this is the file you saved back in Step 2.

Step 5: Go to this portion of the recipe and enter in your WiFi’s network SSID, password, etc.

-SSID and password are the name of your WiFi and the password to connect to it as if you are connecting a laptop, phone, or nintendo switch. This is not the password to your router, a password you might need later.

Change the WPA/WPA2 if you are using something insecure and adjust the country code if you aren’t in the U.S.

Step 6: Click ‘Write’ to write the prebuilt image to the RPI.

-You will have the option of raspbian full, raspbian lite, or both. I picked full and it works great. Plus, you will have a raspbian desktop to monkey around with for other stuff that you might want to try with Maslow/webcontrol. Just know that doing too much on the RPI itself while doing a cut may slow down the ability of webcontrol to feed gcode to the controller and respond to user input.

After done, you should be able to insert the SD card into the RPI, boot it, wait a minute or two (has to download and install webcontrol) and then access it from the RPI’s IP address, port 5000.

-to find the Rpi’s IP address you can do it one of two ways:

5A. Log into the admin panel of your router and find a tab called “connected devices” (may vary from brand to brand). You should see a device named “webcontrol” with an IP address. Mine was 192.168.1.6 which is a variation of my main IP address. If you don’t know how to do this, you should take a few minutes and google how to access your router, it’s a very useful thing to know how to do.

5B. If logging into your router is beyond you, you can get the IP from the raspberry pi side in raspbian. You need to open a prompt and type in sudo ip addr show and hit enter. Then, look for Wlan and the number. It will look like this: 192.168.1.8/24 (but a custom number for your rpi). Let’s just say yours is the number I just listed. In step 6, you will need to type this in but drop the /24 part and add the 5000 port.

-From my example above: 192.168.1.8:5000 from the remote computer you are trying to access from. Make sure to swap in the webcontrol IP you found on your router or in raspbian after running the “sudo ip addr show” command. Leave the tab open for now.

-The Rpi boots up when you plug it into micro USB power and it detects a micro SD card with a bootable image. It takes two or three seconds and then you will see a flashing green light next to the red power on light. You should see streaming lines of text as it boots up. There will be a grey dialog box that runs before you arrive at the full raspbian desktop.

-go to the main menu (looks like a raspberry)>system tools> task manager in raspbian and look for webcontrol to be running as one of the threads.

-From my example above: 192.168.1.8:5000 from the remote computer you are trying to access from. Type it directly into the search or address bar in internet explorer, chrome, or firefox. Don’t let auto suggest or autocomplete finish the text for you. Make sure to swap in the webcontrol address you found on your router or in raspbian after running the “sudo ip addr show” command. If you use the example one I put in, it likely won’t work. This should pull up webcontrol. Leave this tab open for now.

-Now that you have webcontrol up on your main computer, go into maslow settings and look at the ports settings. Take a screenshot or write down what is showing there. These will be the ports to NOT use later once you hook the Rpi to the Arduino.

-Optional step: get VNC viewer up and running from your main computer to the Rpi so you can have remote control of it, it might come in handy later. I’m planning on adding a webcam soon so I’m glad I added this for easy setup, should I need it.

-Use the main menu and power down the Rpi, don’t just unplug it like I was doing! Bad.

-Leave the micro SD card in and remove the HDMi cable and wireless mouse/keyboard dongle. Go out to the maslow and hook the USB-A to USB-B cable up to the arduino from one of the Rpi’s 4 USB ports. Run the power supply to the Rpi and plug it in. Watch for the green lights, one on the Rpi as I described earlier and also one on the Arduino that will light up when it is connected to the Rpi. They should both light up in about 5 seconds, the Rpi first and then the Arduino shortly afterwards. If you did something wrong along the way, one or both of these lights will not come on and you maybe have to go back and start at step 3, compiling raspbian with webcontrol.

-Go back to your main computer, the one you used to access the rpi before moving it to the Maslow. If you left the tab open to the webcontrol IP address, the tab might just refresh and webcontrol will be up again. If not, refresh the tab or make sure you typed the IP address correctly and added the right port.

-You should now see a new port under maslow options:

ttyACM0. If it’s not already selected, pick this port and hit accept. If everything is working correctly, you will get three green boxes at the top right of the window, above the manual move controls.

-You might run into trouble getting the Rpi/Arduino to talk to the motors and make them move. I had to restart my whole setup twice before I finally got webcontrol to connect and also send commands properly. Remember that it’s better to power down the Rpi from the menu (here’s where remote control is super handy) vs a hard shut down by unplugging. You can also try to shut it down from webcontrol using Actions->Shutdown. I also recommend allowing the Arduino to power up first, then power up the Rpi and let it boot for a full minute or so, and then connect the USB cable. This seemed to be the magic sequence for me.

13 Likes

I did all the above and had success.

Now… since I had previously run the Maslow directly from my laptop, and had it all calibrated and everything, how do I copy all those settings over to the pi and where do the go?

M

1 Like

upload your groundcontrol.ini and it will translate your settings to webcontrol

David Lang

This thread might have more information that you want like where that file is for different OS:

Completely forgot that step, sorry!

Completely new to webcontrol and RPI but I tried the instructions above and let it run but no webcontrol… After about an hour I followed the instructions on the Github page and initiated the download, install and setup the service. All works great just not sure if I was impatient or something didnt work right.

Congrats on getting it going! A little late now, but a great video was just released on youtube that Graham made and he shows how to download everything and set it up. With this method above using raspian jesse and the pibakery recipe, where did you get hung up? Which part didn’t work like it should have?

1 Like

From the writeup, it sounds like once you startup the rpi with the card you just wrote to with pibakery, it should initiate the download and start webcontrol as a service. I downloaded the file, imported it to pibakery, updated my wifi settings and wrote to the card with full version of raspbian. Inserted the card to rpi and started it up, OS loaded, wifi connected but no webcontrol ever showed up in the task manager. I figured I’d messed up so I did it all a second time from the very beginning with the same results. I ended up running the commands to download, install and setup webcontrol as a service. It seemed like the download part didnt happen for me.

I’m having the same experience now too. My first time through, docker started and downloaded webcontrol just fine. Now, on my second attempt, nothing is happening. @madgrizzle do you know why the xml recipe/pibakery method wouldn’t download webcontrol?

Yes, actually. I deleted the releases from my GitHub repo. If you can edit the xml file, change where you see 0.933 to 0.94. Might be in two places in the file… just search for it. I’ll update tomorrow otherwise.

Or, you could try the better prebuilt image here:

2 Likes

I created a new version on my personal repo. Let me know if you try it out and if you have any problems. If you already fixed it or used the other image, that’s fine also. Just let me know either way.

https://raw.githubusercontent.com/madgrizzle/WebControl/master/webcontrol-us-recipe.xml

Right-click, save as… webcontrol-us-recipe.xml

1 Like

New recipe works great, thank you. It really helps if I type in the SSID and password correctly. Threw me off a couple of times.

2 Likes

I found my .ini file, but inside of webcontrol, i cannot for the life of me figure out where/how to upload it. do I have to get VNC going and drag/drop it into the file system in the R/pi? or is there a webcontrol “upload your config file here” button?

Thanks!

There is, it’s in “Actions”.

I have a pi4, so followed the recipe line by line.

Fitted a screen to the pi. Use my phone (by Bluetooth) as the keyboard and mouse.

Note this means you can copy the long links on your phone’s web browser and paste them into the pi’s shell window.

Today have we control up.and running. Some. Questions:

How can you see what version Webcontrol is running from the web page it hosts?

Is 94 the latest? I am running the "single directory pi version.

Yes, 0.94 is the latest. If you go to Help->About you will see it listed (along with another version number that is relatively meaningless).

Thanks. I’m beginign to think yesterday was just a bad day. This was blank when visited before.

Hi folks, joining in on this one. Figured the ‘single directory’ release is the recommended one for the RPi.

  • is there a recommendation for the PI-OS to put on a 3B+?
  • what is the recommended Firmware? Is the ‘holy-firmware’ the path to go for some one to start fresh at zerro?

Kind regards, Gero

  • is there a recommendation for the PI-OS to put on a 3B+?

any linux varient should work, but Raspian is the most common to use.

  • what is the recommended Firmware? Is the ‘holy-firmware’ the path to go for some one to start fresh at zerro?

I don’t know of any compaisons of holey vs the new external calibration that
I’ve read about recently, but it does seem that holey is better than the prior
calibration.

David Lang

1 Like

Is that the external script drilling into masking tape? Guess will go with the holey first and then check that thing out. Did not get the math, but the reading on the blog sounded solid.

Edit: RefineCalibrationParameters
Blog post