Recording mowing path of lawn robot



  • With a M5Stack Fire plus a GPS module, I want to record the mowing path or the position of a lawn robot, record it and display it offline (possibly live) on a tablet or a PC.
    Programming would be preferred with Arduino.
    Has anyone tried this or seen such or similar applications (such as recording the jogging path or a motorcycle tour)?
    I would be pleased with any feedback. Thank you very much.

    0_1587116348425_Miimo mit M5Stack FB.JPG



  • Additional question: Does anyone know a way to read the GPS position from an iPhone with a M5Stack Fire (e.g. in 1-second intervals)?



  • Your best bet for this project would probably be to upload the GPS data to a local webserver and view it through localhost on your wifi. If the Fire comes with built in wifi or bluetooth, have the module connect to your local wifi, and make an HTTP Post request through the arduino language to your webserver. To host a webserver, you can use the Apache WebServer. https://www.apache.org/

    I've never used a microcontroller to make an HTTP request as I've never found a use for it, so I am unable to help you with the code.

    Hope this helped.



  • One thing to note: GPS data is sometimes accurate only to about 3 meters. It's certainly theoretically better -- and often is -- depending on how many satellites are currently in view. But when looking at data like this on a very small area, your GPS data will often seem erratic or jittery as the reported value moves around within the range of error.

    For example, if your mower were moving back and forth in .5 m swaths, it may actually seem to say in the same place for 3 meters or so, then jump forward and maybe sideways by 2-3 meters. So the results may seem less regular, and less smooth, than real life. Even if the mower is sitting in a single spot for some time, it may seem to jiggle around.

    The usual solution to this is to take multiple samples over a period and smooth them out, based on some knowledge of the speed of the device being tracked.



  • Many thanks to Devilstower!

    I am aware of these accuracy-issues of GPS readings (analog measurements in general).
    My plan is to read in the GPS-Readings as fast as possible and store time and value on a SD-card.
    Evaluation und graphical display of the stored values will be done offline on a PC.
    This will allow to do any kind of averaging like "moving average".
    I am hoping of getting an accuracy of < 0,5 meter (3 sigma) at a given static position.
    So far I have no idea on how many measurements need to be done and averaged to get this accuracy.
    I also do not know, how fast GPS-measurements can be done and if there is a trade off between measurement rate and accuracy.

    Do you have any further informations and/or recommendations on "accurate" GPS-measurement-hardware which is compatible to the M5Stack-Fire?



  • I spent several years working on projects to automate construction / mining equipment that required highly accurate location values. At the start, we could use GPS fairly effectively for vehicles moving down a pre-defined path, but had to switch to GPS + RTK base stations when looking to get < 1M accuracy needed for things like loading dump trucks, etc.

    Originally, RTK units were very expensive (as in $80K for a base station and another $20-40K on each vehicle) which limited the range of applications. But the price has dropped tremendously. The last set of items I built for this used a variety of GPS+RTK boards that brought the whole system below $300. Sparkfun makes one such board.

    With these systems, you can get down to the sub-centimeter range. So ... really accurate. But you're still going to spend $200-400 if you want to track movement that accurately.

    To get the kind of .5M accuracy you're looking for, look for a GPS chip that incorporates GLONASS and Galileo (which is, honestly, just about every new chip). Your device is moving slowly, so you could do something like sample four times a second and take a rolling average. You'll probably have to do some smoothing and filtering, because momentary blockages of satellites can result in an abrupt apparent shift in position and sometimes GPS just gives a "WTH" value. But it can definitely be done.

    Oh, and there's really no limit on how often you can check GPS signals. Several libraries out there do try to slow things down, or just feed you the same results if you ask again repeatedly, because GPS can be a power hog. But if you have the power, just take more measurements.



  • @devilstower Thanks again to Devilstower!
    Sounds very promising and worth continuing with my project.
    I'll keep you informed (will take some time).