LibrePilot Forum
Development => GCS General => Topic started by: rabno1 on April 23, 2016, 09:29:18 pm
-
New to all this git stuff. I've managed to setup all the dev tools and build the next branch but now i want to add the dRonin auto tune port. Ive used dRonin autotune and got great results.
The problem is i have now idea what commands i need to do to pull?/clone?/merge? that branch so when i build the GCS and firmware it includes the autotune stuff.
Ive been playing around trying all sorts of commands but getting nowhere fast. Ive done a "git checkout theothercliff/LP-76_Port_Autotune_from_dRonin" and built everything after that but nothing seems different in the build.
-
The wiki page https://github.com/librepilot/LibrePilot/wiki/Git-Workflow explains this toward the bottom in the section "reviewing someone else's work".
Essentially:
git fetch https://bitbucket.org/THEIR_USERNAME/librepilot.git <branch_name>
git checkout FETCH_HEAD
-
thanks ill give that stuff a read and they commands a try.
-
That seemed to work and the firmware built ok but now the gcs wont build (never had a problem before).
mingw32-make[4]: *** No rule to make target 'C:/msys32/mingw64/bin/libproj-9.dll', needed by 'C:/librepilot/build/librepilot-gcs_release/bin/libproj-9.dll'. Stop.
mingw32-make[4]: Leaving directory 'C:/librepilot/build/librepilot-gcs_release/src/libs/osgearth'
Makefile:434: recipe for target 'sub-osgearth-make_first-ordered' failed
mingw32-make[3]: *** [sub-osgearth-make_first-ordered] Error 2
mingw32-make[3]: Leaving directory 'C:/librepilot/build/librepilot-gcs_release/src/libs'
Makefile:41: recipe for target 'sub-libs-make_first-ordered' failed
mingw32-make[2]: *** [sub-libs-make_first-ordered] Error 2
mingw32-make[2]: Leaving directory 'C:/librepilot/build/librepilot-gcs_release/src'
Makefile:40: recipe for target 'sub-src-make_first-ordered' failed
mingw32-make[1]: *** [sub-src-make_first-ordered] Error 2
mingw32-make[1]: Leaving directory 'C:/librepilot/build/librepilot-gcs_release'
Makefile:269: recipe for target 'gcs' failed
mingw32-make: *** [gcs] Error 2
-
Your Msys is up to date ?
Added Librepilot repo ?
https://librepilot.atlassian.net/wiki/display/LPDOC/Windows+Building+and+Packaging#WindowsBuildingandPackaging-InstallMsys2
-
yes all up to date. I can still build the "next" but when i try to build after the 'git checkout FETCH_HEAD' it fails.
-
Which branch do you try to build ?
-
theothercliff/LP-76_Port_Autotune_from_dRonin
-
Maybe this branch is not up to date with current Next.
You can try a :
git merge next
If no conflicts, this should work.
-
there was a conflict
CONFLICT (content): Merge conflict in flight/modules/Stabilization/innerloop.c
im begining to think this is over my head and i should just stick with dRonin until this has been officially merged with next :(
-
If you edit flight/modules/Stabilization/innerloop.c
The conflict is:
<<<<<<< destination:137b3b24c158751a7614a12182101c74c39c097b
static bool measuredDterm_enabled;
=======
#if !defined(PIOS_EXCLUDE_ADVANCED_FEATURES)
static uint32_t systemIdentTimeVal = 0;
#endif /* !defined(PIOS_EXCLUDE_ADVANCED_FEATURES) */
>>>>>>> source:22055cf6c773eb96d115d9c6d053ac29e23535c4
Just replace with:
static bool measuredDterm_enabled;
#if !defined(PIOS_EXCLUDE_ADVANCED_FEATURES)
static uint32_t systemIdentTimeVal = 0;
#endif /* !defined(PIOS_EXCLUDE_ADVANCED_FEATURES) */
In fact keep all code and remove "<<<<<<< destination:...." and "=============="
-
Second conflict with shared/uavobjectdefinition/flightstatus.xml
<<<<<<< destination:137b3b24c158751a7614a12182101c74c39c097b
<field name="FlightMode" units="" type="enum" elements="1" options="Manual,Stabilized1,Stabilized2,Stabilized3,Stabilized4,Stabilized5,Stabilized6,PositionHold,CourseLock,VelocityRoam,HomeLeash,AbsolutePosition,ReturnToBase,Land,PathPlanner,POI,AutoCruise,AutoTakeoff"/>
<!-- Keep Armed (first pos) and FlightMode (second pos) before this line for OSD compatibility -->
<field name="AlwaysStabilizeWhenArmed" units="" type="enum" elements="1" options="False,True" defaultvalue="False"/>
=======
<field name="FlightMode" units="" type="enum" elements="1" options="Manual,Stabilized1,Stabilized2,Stabilized3,Stabilized4,Stabilized5,Stabilized6,PositionHold,CourseLock,VelocityRoam,HomeLeash,AbsolutePosition,ReturnToBase,Land,PathPlanner,POI,AutoCruise,AutoTakeoff,AutoTune"/>
>>>>>>> source:22055cf6c773eb96d115d9c6d053ac29e23535c4
Keep the top/first part and add "Autotune" to the enum list.
<field name="FlightMode" units="" type="enum" elements="1" options="Manual,Stabilized1,Stabilized2,Stabilized3,Stabilized4,Stabilized5,Stabilized6,PositionHold,CourseLock,VelocityRoam,HomeLeash,AbsolutePosition,ReturnToBase,Land,PathPlanner,POI,AutoCruise,AutoTakeoff,AutoTune"/>
<!-- Keep Armed (first pos) and FlightMode (second pos) before this line for OSD compatibility -->
<field name="AlwaysStabilizeWhenArmed" units="" type="enum" elements="1" options="False,True" defaultvalue="False"/>
-
So i edited those and now im getting
$ git merge next
error: merge is not possible because you have unmerged files.
hint: Fix them up in the work tree, and then use 'git add/rm <file>'
hint: as appropriate to mark resolution and make a commit.
fatal: Exiting because of an unresolved conflict.
Thanks for the help, Im sure you'd all rather noobs would stick the stable builds :P
-
tried this
$ git add flight/modules/stabilization/innerloop.c
$ git add shared/uavobjectdefinition/flightstatus.xml
warning: CRLF will be replaced by LF in shared/uavobjectdefinition/flightstatus.xml.
The file will have its original line endings in your working directory.
$ git merge next
error: merge is not possible because you have unmerged files.
hint: Fix them up in the work tree, and then use 'git add/rm <file>'
hint: as appropriate to mark resolution and make a commit.
fatal: Exiting because of an unresolved conflict.
-
So wait the branch to be updated with next :(
-
Guess I'll just stick to dRonin for now. Shame librepilot gcs does seem to be a bit more stable.
-
If you experienced crashes you could report trace and step to reproduce....
https://librepilot.atlassian.net/issues
Attached archive with two files without conflict, not flight tested!
-
Not really had many crashes with librepilot GCS but i cant get it flying anywhere near as good as dRonin after using there autotune.
Ill have a play around, im sure what im trying to do is easy when you know how.
I tried starting from a fresh clone of next and going through everything above, then replaced the 2 files with the conflicts with the ones you attached. When i try to merge now its telling me the merge will override the changes ive made to they 2 files and i need to commit them.
-
You should only replace the files after you get the merge conflict,
git add the_two_files
git commit
-
Well i got it to build. Then it bricked my Revo ::)
-
Got the Revo back up and running. Now to figure out how to use this autotune :P