pro tip: make sure your date and time is correct otherwise the auto download and setup will not be happy. Big Thanks to @johnboiles for pointing that out in the log file.
I’m really surprised that NTP didn’t pull the correct time on your pi. I’m not sure why that would be. Perhaps there’s a race condition where if NTP is slow enough and Docker is fast enough you can end up with Docker running before the NTP update
Unless you add NTP yourself then the pi doesn’t use NTP to set time. Much to my surprise it uses a little shell script and makes a call to Google. Not sure how reliable that is. My guess is it may be one and done at boot and isn’t resilient not support slew if the first call fails.
For my home dvr front-end I added NTP manually using these instructions http://raspberrypi.tomasgreno.cz/ntp-client-and-server.html
I used the NRC stratum 2 servers in Canada and have super accurate time.
I thought the Raspbian lite image this is based on included NTP. I’ve never manually set the time on my Pi and is pretty sure the time has been correct. I’ll have to talks a look sometime when I’m home.
Tl;Dr If time is important on your Pi then install NTP. Otherwise you may experience incorrect time for a variety of reasons. NTP is resilient as best I can be in the absence of a real time clock and battery to maintain time across reboots.
Yeah it tries to set it. Basically it has no real time clock but they write out the time on shut down as a backup and during boot apparently they make a call to Google to get time but not sure what the exact method is. I think it’s http. If that fails I believe they fall back to last known time and if unavailable start at the epoch of Jan 1 1970 I think.
I didn’t review the scripts but went down the rabbit hole researching when doing MythTV work and what I said above surprised me and also explained weird time issues at different points. If you are relying on time you need ntp and even then it slews the clock slowly if you are way off the reference so it can take a bit to arrive at accurate time.
modern versions of ntpd support the -g flag which allows the first adjustment to
be big rather than slewing slowly or giving up (prior to this, we used to have
to run ntpdate before starting ntpd to get the clock close)
I haven’t looked at raspian to see if it uses the -g flag by default.
For auto-zero the z-axis, this is the command in ground control:
“G20 G90 G38.2 Z-” + plungeDepth + " F1 G20 G90 M02"
where plungeDepth is the Advanced Settings->maxTouchProbePlungeDistance value.
For webcontrol functionality, do you want it to plunge to touch and then you manually tell it to set z to zero or do you want it to plunge to touch and automatically set z to zero? I’m pretty sure I can do either way.
I think it makes sense to auto-zero
I put this into the holeywebcontrol branch, which I hope to merge into main branch soon. I don’t know if it works though, but it’s there for someone to test if they are setup for it and inclined to do so. There’s a setting in advanced to enable the use of a touch plate.
Can I use a Raspberry pi 2 to run WebControl
Yes, just remember it doesn’t have built-in wifi, but as long as you hook it up
via ethernet or add a wifi adapater, it will work.
Thanks @dlang, at last got it working and it’s great
Maybe someone can send me in the right direction, I got WebControl up, and it looks like its connecting but it will not move the motors.
I’ve installed the latest Raspbian, (i just couldnt get the image version to connect to the internet), i was installed webcontrol and ssh through a lot of trial and error and was able to get it up and running, along with VNC and a second monitor.
I think its probable something simple that i’m missing but after hours of reading i am not sure if i overlooked something. i installed the arduino IDE just in case it need it to connect to the board, but that has not fix the issue.
Thank you in advance
There are two connections, one is between the browser and webcontrol on the rpi… that’s what the left “Connected” represent (in the top right of your screenshot) The next is between webcontrol and the Arduino controller… that’s what the right “Not Connected” represents. I do not believe you are connected to the Arduino. Go to settings, maslow settings, and select the Com Port for the Arduino. The little refresh symbol you will see will query the comports on the rpi and populate the list for you.
Awsome, Thank you madgrizzle, I tried that and was able to get 4 ports, i tested and it does connect but still no movement, ill test more tomorrow.
Be aware that some ports give ‘false connections’… Which port did you end up using? Most of the time, I end up on /dev/ttyACM0. Did you see the messages coming in from the controller?
Look at this thread for some more information:
The default Raspberry Pi combination works.
TLDR Don’t trust the IP address being reported as the IP address of the webcontrol server.
One of the recent improvements was to report the host IP address on the screen so you know what IP address to use to reach webcontrol on your phone/tablet/whatever. This was added for the Windows 10 version since you might not readily know your IP address. For the RPI, in a headless implementation, you probably do know the address since you’ll be stuck otherwise. The problem on the RPI is that the address being reported is the docker container’s internal IP address, not the one that is accessible to the outside. I have a solution from stackoverflow, but to make it work requires a modification of the startup script of the pre-built image. I don’t know that the juice is worth the squeeze just to make it consistent. So unless I find a better way, I’ll probably just disable that in docker implementations. But in the meantime, don’t trust the IP address being reported if you are using an RPI.
I will admit, I’m still setting up my Maslow CNC and I am using Web Control on it’s own to prevent getting used to software that may not work when Python 2.7 goes into the abyss. I am having a problem calibrating the machine using it’s own stuff. I’ve used a tape measure to the best of my ability, but I have a feeling I’m going to end up with a system that can’t cut straight. Can you put some resources into developing the calibration functions that are in ground control? An example, I can’t find where I can cause one motor to extend by a particular amount. I can get the tooth to go straight up for each motor. Maybe on that page, add the extend/ retract features for each motor too, as well as the measure the distance between motors feature.
Or…someone please reply to me with specific instructions how to do this operation in Web Control 1.27.