Francklin2 / RTKLIB_Touchscreen_GUI

RTKLIB GUI for Raspberry Pi with touchscreen made with Qt by the ENSG students
175 stars 63 forks source link

build_rtkbase.sh does not contain all neccessary packages to build RTKBASE #33

Open exi2163 opened 7 years ago

exi2163 commented 7 years ago

The script build_rtkbase.sh does not contain all neccessary packages to be able to build RTKBASE. I needed to additionally install qtcreator and qt4-dev-tools to be able to build.

If the needed packages are not installed qmake will fail and the user will not be notified. Also there is no information on where to find the log which contains the error. The success message could be based on the presence of the RTKBASE binary at the end of the script to prevent confusion.

Francklin2 commented 6 years ago

Hi Thank you for the report, I think you are installing from a fresh image of raspbian, the script we have was based on a image with qtcreator already installed. We have to do a script for a fresh install on raspbian

Claudio033 commented 6 years ago

Hello, Congratulation for this application and its evolutions. As future evolutions, I suggest you integrating it the projections Lambert-93 and Corresponding Conics 9 zones (CC42 to CC50).

jbeilin commented 6 years ago

Hi, What about linking Proj4 to the project. That could be interesting for @ENSG_IGN students. We just have to see whether it's enough work for a project. Jacques

Francklin2 commented 6 years ago

Hi Claudio You mean I have to add the projection options in the setting tabs ?

Francklin2 commented 6 years ago

For the linking with proj4, it's a good idea but I dont know how to do it, I will take a look on linking this week

kikislater commented 6 years ago

Proj.4 is a lib in common GIS software. Inside the lib there is a command line program which can convert data from one projection to another. It's very powerfull. Program name is cs2cs and usage is like that : echo "-1.176492 45.587111 " | cs2cs +init=epsg:4326 +to +init=epsg:2154 This command convert from Lat/Lon to Lambert 93. There is python binding for this command and proj4js, a javascript implementation to enhance your web script...

Proj4 is available with this package under rpi : libgeo-proj4-perl and does not need rebuilding it. source : http://micmac.ensg.eu/index.php/Compilation_de_MicMac_sur_ARM_(RaspBerryPi)

So usage is just to call cs2cs or use python-proj4 or use proj4js

Francklin2 commented 6 years ago

I see so Claudio want a tool to convert results in another projection (I thought it was the projection option in rtklib). cs2cs from proj4 could be integrated in rtkbase to do that and write the output to a file and the screen

Francklin2 commented 6 years ago

I did a few test with cs2cs and was able to use it as a cmd line in rtkbase to convert the post processing results from rnx2rtkp in ECEF. so I used this command line to convert to WGS 84: cs2cs +proj=geocent +datum=WGS84 +to +proj=latlong +datum=WGS84 -f" "%.12f" I'm not sure it's the correct way to do that, do the XYZ(ECEF wgs84?) results from rnx2rtkp are correctly described in " +proj=geocent +datum=WGS84 " . On the output side Do i need more arguments for the wgs84 or is it better and safe to use the EPSG ? : cs2cs +init=epsg:4328 +to +init=epsg:2154 (for geocent WGS84 to Lambert93) I can add in the interface the choice of EPSG and have a output in a separate file

Francklin2 commented 6 years ago

It's a bit more clear for me now after testing again cs2cs, so I will use this method forcss2cs : cs2cs +init=epsg:4328 +to +init=epsg:2154 I can add a transformation to the saved point files for the rover mode and in the post processed results (you can do a datalog>post process>transform results). For the transformation I will use the ECEF coordinates , I presume it's the geocentered WGS84 with the EPSG 4328 for the rtklib output (tell me if it's not the good one)

Francklin2 commented 6 years ago

I made a update with cs2cs, in the save point option, you can choose Lambert93 and the CC42 to CC50, the converted coord will be added at end of saved point in pointfiles foldes. cs2cs or proj5 have to be installed before on the system (It stil have to be add to the build script)

kikislater commented 6 years ago

Hi Francklin, Great addition.

WGS84 is 4326 and not 4328. 4326 is more standard and it's the output of rtklib http://spatialreference.org/ref/epsg/4326/ https://en.wikipedia.org/wiki/World_Geodetic_System 4328 is variant. Don't use it here ! Watch line 628 of rnx2rtkp.cpp There is already a stage to convert from ECEF to standard WGS84 From rtklib you could specify different output, it depends on the output provided in rtkbase :

  • Lat/Lon/Height: Latitude, longitude and height ‐ X/Y/Z ‐ ECEF : X/Y/Z components of ECEF coordinates ‐ E/N/U ‐ Baseline: E/N/U components of baseline vector ‐ NMEA0183 : NMEA GPRMC, GPGGA, GPGSA, GLGSA, GAGSA, GPGSV, GLGSV and GAGSV

Next step would be geoid correction ...

Francklin2 commented 6 years ago

Ok It's a bit more clear now, on our output both WGS84 and ECEF are available so that's why I took the ECEF (as EPSG 4328), I can change this and get the WGS84 as EPSG 4326 in the next update and keep WGS84 output as input for cs2cs. For the geoid correction do you have a example of theses parameters and syntax, (I saw a conic parameter an some x/y/z values in some example but I'm not sure it's that, still need some reading...). I was using Qprocess but was not able to use the echo command in it, so I had to write a file and read it to get coord for cs2cs, do you know a trick for that ?

Francklin2 commented 6 years ago

I've done a update, now we use the wgs84 coord (epseg 4326)from rtklib output as input for cs2cs . cmd line is now like this : cs2cs +init=epsg:4326 +to +init=epsg:2154. About the compilation on the new RPI3B+ and raspbian stretch, I'm able to compile with Qt5 but the new post processing part wrote in Qt5 dont work. I think there is something wrong with my Qt5 install (used apt-get install qtdeclarative5-dev qttools5-dev-tools qt5-default .

Francklin2 commented 6 years ago

I add a new build script for RPI3B+ and Qt5 or test, it build but the post process part still not working (Qlist out of range) I put this in the dependencies / apt get part proj-bin qtdeclarative5-dev qttools5-dev-tools libgles2-mesa libgles2-mesa-dev build-essential qt5-default Code is working when build on X86 desktop PC and qtcreator on qt 5.7.1 ...

Francklin2 commented 6 years ago

I done a update and found why it was not working on RPI3, the RNXCMP library (Hatanaka compress) in package were build for x86...I add a bin-arm and bin-x86 folder with compiled binaries. Now cs2cs is used in post process to convert XYZ to LLH with :
cs2cs +init=epsg:4978 +to +init=epsg:4326 -f %.6f Is the 4978 ok for xyz or should I put back this syntax +proj=geocent +datum=WGS84
The convbin and rnx2rtkp lib are not included in the scripts and the rights of binaries in package folder have to be checked too. By default I put the ARM binarie for Hatanaka in package folder. I also got a Qt'4 version that should work now (will test it soon on a raspberry)

Francklin2 commented 6 years ago

I added 2 scripts:

Francklin2 commented 6 years ago

@kikislater and claudio033 I add the geoid correction file option to the cs2cs transformation and opened a new issue for Proj4/cs2cs use in rtkbase .