Raspberry Pi - Python Based GPS System

hutchy143211

Member
Location
E. Yorkshire
Hi All,

I just wanted to share something I have been for a couple of months now. I got interested in raspberry pis as cheap way of creating farm hardware. This started with a sheep RFID scanner which for the cost of ~£100 can read and manage all the data about our sheep flock like a commercial system. I then moved on to a weather station and then the GPS where I am now. At the moment it's very simplistic, I can read the GPS position from the module, convert the coordinates to a UTM grid and set an A/B position. I'm starting to implement a light bar system to allow for tractor guidance with RTK level accuracy. My end goal is to use this GPS for autosteer, section control etc The system could also be used for other things such as surveying utilities such as drains, cables, etc as well as for drones . Thought I would share to get ideas, show how powerful user developed technology can be and maybe help others who also want to build their own tech.

1596985356313.png
 

hutchy143211

Member
Location
E. Yorkshire
So I've managed to get my python program working for guidance. At the moment its working as a lightbar indicating cross track error from an AB line. At the minute the GPS is very inaccurate but the plan is to go to 2 ardusimple F9P board and hopefully get as close to 10mm accuracy as possible. In theory this should be enough to guide a tractor accurately then. Next steps are to implement a 2D map graphic for things such as the field boundaries and guidance lines. I'm also hoping to integrate some hardware buttons for example to set the AB line on a joystick and see how that goes!

1597785623923.png
 

hutchy143211

Member
Location
E. Yorkshire
What hardware did you use for the rfid?
For the RFID reader control I used a raspberry pi with an LCD, matrix keypad and LEDs. For the reader itself I used a RFID module from priority1design in Australia as it can read both HDX and FDX tags. These simply plug into the UART port on the pi. With the scanner I used the 49mm antenna. Takes around 3 weeks to ship to the UK with economy postage.
 

hutchy143211

Member
Location
E. Yorkshire
I've spoken to this guy a few times. He's already running a similar setup. He might be able to give you some guidance.
Yeah I spoke to him when I first set out to build my system. He recommended some really useful python modules to use to convert the GPS data. My approach is slightly different as his is based on wxPython whilst mine is using pyqt5 for the GUI.
 

hutchy143211

Member
Location
E. Yorkshire
Did you consider AgopenGPS?
Yeah, I did consider AgOpenGPS and am still considering it as an option as it is likely to be able to do more than my system ever will. If i decide that I should be able to use the same F9P boards to give RTK for that. However, my main reason for trying to do my own is several fold.

- I want understand how the software works so that I can implement features that I want as well as knowing the possibilities and limitations
- A raspberry pi can be used for other hardware software interfaces such as wireless cameras, electrohydraulic control using other programs (I have a few ideas ;))
- I won't be the main user of the system (older parents who aren't tech savy) so something simple I can explain/diagnose would also be useful
- Lack of cheap windows tablets to run AOG so it's not as easy to fit a system in each machine (4 tractors + combine + quadbike?) and I don't want to transfer homemade electronics really
 

hutchy143211

Member
Location
E. Yorkshire
Got my 2 F9P ardusimple simpleRTK2B boards today. All I can say is wow! These little things are insanely good. I’ve only tried one so far by plugging in the radio USB to the Pi (TX1 to RX1 hack) with the main USB connected to U-Center. So easy to customise the board for what you need. Currently I have removed all messages except the GxGGA which I use. Got it running at 5Hz on my GUI and no problems so far, seems to handle it fine which is great. In theory all I need to do now is set the base station up to output RTCM messages and transmit them to the rover pi and then we have a fully function autoguidance (obviously a long way to go for features yet). Even though they cost £200 each, it should be pretty easy to fit along with a touchscreen and pi for less than £400 which would be incredible value for money. Now I'm hoping to develop this system quite a bit more, with a GUI to map field boundaries etc. I may also build a quick LED light bar which mirrors the one on the screen to be controlled by the pi.

118213867_302119790877243_9037066755502486674_n.jpg
 

marklr90

New Member
Got my 2 F9P ardusimple simpleRTK2B boards today. All I can say is wow! These little things are insanely good. I’ve only tried one so far by plugging in the radio USB to the Pi (TX1 to RX1 hack) with the main USB connected to U-Center. So easy to customise the board for what you need. Currently I have removed all messages except the GxGGA which I use. Got it running at 5Hz on my GUI and no problems so far, seems to handle it fine which is great. In theory all I need to do now is set the base station up to output RTCM messages and transmit them to the rover pi and then we have a fully function autoguidance (obviously a long way to go for features yet). Even though they cost £200 each, it should be pretty easy to fit along with a touchscreen and pi for less than £400 which would be incredible value for money. Now I'm hoping to develop this system quite a bit more, with a GUI to map field boundaries etc. I may also build a quick LED light bar which mirrors the one on the screen to be controlled by the pi.

118213867_302119790877243_9037066755502486674_n.jpg

I'm considering going down the AgOpenGPS route and using a similar receiver setup. Some people prefer the Digikey version of the F9P (for reason that I now can't remember). What are you using for inclinometer, compass, etc?
 

hutchy143211

Member
Location
E. Yorkshire
I'm considering going down the AgOpenGPS route and using a similar receiver setup. Some people prefer the Digikey version of the F9P (for reason that I now can't remember). What are you using for inclinometer, compass, etc?
Currently don't have an inclinometer/compass at the moment. I think I'm going to go down the dual antenna route as it seems to provide the best system in the long run for reliability and accuracy. At £400 all in for 2 antennas/boards per tractor setup (+1 for the base) I think that's very reasonable money for what you get. I've also heard of issues with inclinometers/compasses in tractors due to vibrations, electrical interference which again makes me think that dual antennas is the best approach.
 

marklr90

New Member
Currently don't have an inclinometer/compass at the moment. I think I'm going to go down the dual antenna route as it seems to provide the best system in the long run for reliability and accuracy. At £400 all in for 2 antennas/boards per tractor setup (+1 for the base) I think that's very reasonable money for what you get. I've also heard of issues with inclinometers/compasses in tractors due to vibrations, electrical interference which again makes me think that dual antennas is the best approach.

Much of the need for dual antenna can be avoided if you place the inclinometer over the gearbox. Even without cab suspension, the cab vibrates too much and impacts the roll measurements - also when it is placed on the cab roof, this effect is multiplied the higher it is.
 

hutchy143211

Member
Location
E. Yorkshire
Much of the need for dual antenna can be avoided if you place the inclinometer over the gearbox. Even without cab suspension, the cab vibrates too much and impacts the roll measurements - also when it is placed on the cab roof, this effect is multiplied the higher it is.

That's very true, I haven't given much thought to inclinometers so I'd have to do a bit of research. A quick Google for AOG inclinometers does have an interesting video though.

 

Feedbeef

New Member
Im using AgopenGPS in Yorkshire, Got it setup on two tractors and a base station, really impressed with it! The Ardusimple boards are great!
I used tinkerforge brick v2 for my heading
and a seperate mma8452 roll sensor.
Reading through the forums seems to be like there are more issues with dual antenna
 

marklr90

New Member
Im using AgopenGPS in Yorkshire, Got it setup on two tractors and a base station, really impressed with it! The Ardusimple boards are great!
I used tinkerforge brick v2 for my heading
and a seperate mma8452 roll sensor.
Reading through the forums seems to be like there are more issues with dual antenna

Yes, I think you’re approach is best. I assume you’re not using a PCB then? I think a lot of the noise users are experiencing may be due to the PCB setup where components are so close together. What version of AgopenGPS are you running?
 

Will you help clear snow?

  • yes

    Votes: 68 32.1%
  • no

    Votes: 144 67.9%

The London Palladium event “BPR Seminar”

  • 9,746
  • 133
This is our next step following the London rally 🚜

BPR is not just a farming issue, it affects ALL business, it removes incentive to invest for growth

Join us @LondonPalladium on the 16th for beginning of UK business fight back👍

Back
Top