Can Webcontrol Run without wifi on a RP3?

I have a spare RP3 laying around as well as a spare monitor and keyboard, My CNC is setup in my detached garage which is unfortunately too far for my wifi signal, so I’m wondering if it is possible to use all the WebControl features without wifi?

I realize the irony in asking if something called WEB control can run without internet but unfortunately not everyone has access to internet in the same spot as their Maslow and I’m told Webcontrol is better then GroundControl.

Thanks

yes, WebControl does not require Internet access. It does require that you
access it from a browser, that browser can be on a local wired or wifi
connection.

David Lang

2 Likes

so… then it does technically require internet? or I just need a browser? I mean obviously I wont run inside my house to add my design and running it from a phone while solving the internet problem introduces more issue as in copying your designs to your phone. I guess what I am looking for is a fully offline version. I just thought maybe having it on the raspberry pi meant I could just copy my designs to a flash drive then plug it into the pi and control it from the offline browser or start the operation from my phone.

what?

It does not require the Internet, it only requires a browser be able to reach
it.

you can control it from your phone, you just need wifi to get from your phone to
the pi.

you load the gcode via your browser.

David Lang

I misread @dlang 's post, so mine didn’t make any sense.

If you hook the pi up to a monitor, keyboard and mouse you can use the raspbian default browser to access WC on localhost.

If you hook up a USB stick, you’ll be able to copy the nc file to a directory off of ~ (via the file browser or terminal) and WC should be able to see it.

(All of this is dependent on loading the WC docker container in a full version of raspbian. That’s how I got things running last year - but I’m not sure what the current default method is to install WC onto a pi.)

Yep. Just checked - docker is now deprecated with WC (boo) so you’ll have to use the new pyinstaller method.

It’s a strange concept at first, but it makes a lot of sense and opens up a lot of possibilities when you think about the implications.

Most people are happy with running a web browser somewhere (on your Pi, on your phone, on your laptop) to connect to a web server somewhere else (usually on the internet, probably in another city or country). However, if you run the web server on the same machine you can connect to it from a web browser on the same machine, or your phone or laptop on your home network.

Basically, if you decouple the user interface from the code that does the work it gives you a lot of flexibility, especially because now the user interface can be anywhere.

If you want to run things “locally” or “off-line” then you can, but you still have a tiny network inside the Pi, where the WC software exposes a local network interface on the Pi, and the web browser on the same Pi connects to WC via the local network interface. The Pi isn’t (and doesn’t have to be) connected to anything else, but it does need a local keyboard, mouse, and monitor so that you can log in and run a browser.

If you build a small network in the garage that is not connected to the house then any device in the garage can connect to WC on the Pi via the garage LAN, but (obviously) those devices, and the Pi, can not connect to anything outside of the garage. Similarly, anything outside the garage can not connect to WC on the Pi.

If you connect the Pi to your home LAN and expose the Pi’s network ports to the outside world then you can run the user interface on a browser anywhere in the world. Probably you should call home first and make sure no-one is near the router’s Spinning Blades of Death before starting the job. :slight_smile:

Does that help?

Yes, so the idea I had was to first get the Maslow running with Webcontrol on the pi and offline using a monitor, mouse and keyboard, then be able to connect an old ipad I have to use as a wireless control for things such as zeroing the Z-axis and what not.

I have recently finished 3D Printing the parts and have received the other parts necessary to build the meticulous Z-Axis so first thing is to get the Maslow up and running and Calibrated, probably using Ground Control then use it to cut the Final Sled and then the parts needed for the M Z-Axis and finally get everything running on the Pi so I don’t need to tie up my laptop or another computer for it.

Eventually I will set up a repeater so that I can get internet in my shop but for now I will have to do this offline. I should add that my reason for doing things in this order is that I have in the past had the Maslow running on Ground Control and I’m more familiar with it, so rather then introducing another step I will again get it up and running then worry about Webcontrol when i feel comfortable with my setup.

Opinion only follows: adjust to taste.

Webcontrol is a web server system. It can run on anything, but it makes a lot of sense to run in on a dedicated computer. Many people use a Pi for this. I do also.

Internet access is not required at all for webcontrol to run. If you want to update webcontrol it is useful. This update can be done using other methods though.

Since it is a web server, it has to “listen” to some IP address(es). It will, by default listen to every address on the dedicated computer. Certainly it will listen to 127.0.0.1, and if you have other networks defined, it will listen to them, as well. 127.0.0.1 is only available from other tasks running on the Pi, though. I recommend that you set up a 192.16.xxx.xxx network on the dedicated computer solely for the use of webcontrol. And that this network not be the one that you use for wifi.

There are two reasons for this. First, security. webcontrol does no authentication. Anyone who can reach port 50000 of the computer on which webcontrol is running can do things to your maslow. I have seen far too many people accidentally enable remote access into their internal devices to be comfortable recommending that people use webcontrol on their primary wifi. If you do use your primary wifi, at least be sure that you block TCP port 50000 incoming on your edge device. Second, reliability. I prefer a wired connection. Wire will obviously not work for people who want to use a phone or an iPad as a controller. With a reasonably recent laptop, you won’t even need a switch, you will be able to directly cable to the Pi and the laptop and Pi will automatically adjust.

Finally, as to using the PI as both a browser and web server, it is possible, but I would not recommend it. Web browsers are fairly heavy beasts, eating up a lot of memory and CPU cycles. Moreover, webconotrol uses websockets to push data back into the controller. This constant updating adds stress to both the server and the controller.

Even though the Pi is, by historical standards, a capable machine; it is not the environment for which current web browsers are optimized. For the controller, find a used laptop, or a low-end chromebook. I use a pinebook pro. It won’t cost you much more than a monitor, a keyboard, and a mouse, especially since the Pi only supports HDMI which means you probably can’t use an old used monitor.

Final note: if you do use the Pi as both server and controller, it is probably best to simply forget about the iPad. While it might be useful for the z-axis, it comes at the expense of the server needing more memory and more cycles to build the extra session and to keep both sessions updated. Choose one or the other.

If I’ve got an old linux pc kicking around not doing anything, can I use this instead of an rPi for server and controller?

Yes, most people go with a Pi as it’s small and cheap, but you can use a linux
system (or if you really want to, a windows system, but there aren’t many people
doing that so support isn’t going to be as good)

David Lang

check with @zaneclaes about the revived docker version for WC. I thought he had fixed it and was using it.

The newer rpi image that @emilecantin posted for webcontrol has there raspberry pi go into wifi access point mode if no network is found, so you can connect to it via phone or other wireless browser after authentication.

1 Like

inzania/web-control:armhf

Been using it for a month now (docker on rpi).

I’ve had a PR open for almost a month that updates the README. I fixed the Docker deploy for both amd & arm.

You all are awesome.

I’ve been putting off upgrading WC for as long as possible - this makes things easier.

It all depends on where you want to run the browser. My understanding is that you want to use your phone’s browser to run Webcontrol. However, you are too far from your house to use WiFi. The typical issue here is confusing WiFi, Internet, and Web.

  • WiFi is a wireless networking standard. You use it as an alternative to a wired network connection. Your phone probably only talks WiFi.
  • Internet - this is often used interchangeably with the World Wide Web. This is the connection out to the wide world of the internet. How you reach the Maslow forums or the Make Magazine site. Not necessary for Webcontrol.
  • Web when used in the Webcontrol sense means that you are accessing a server using the web protocol and standards. Effectively, http or https and HTML. This does not require internet access.

So, what you need is a way to have your phone talk to Webcontrol on the Rasbperry Pi. The easiest way to do this is to get a cheap WiFi router and never plug in the WAN/Internet side. Configure the WiFi as you normally would and have both your phone and RPi use it. This gives you the WiFi connection from the phone to the RPi but not to the internet. You can talk to Webcontrol but not to the Maslow forums from there.

To make your life easy, plug the RP3 into the router using a cable. The router’s default configuration will give it an IP Address via DHCP. You can then use the browser on the RP3 to configure the router with a unique SSID (don’t use the same one as your home network to avoid confusion). Join your phone to that network and voila!