diff --git a/Paths/ErrorShortestPath.wima b/Paths/ErrorShortestPath.wima new file mode 100644 index 0000000000000000000000000000000000000000..9f1a18caf8c193939524a46121a84ad2677e9cd3 --- /dev/null +++ b/Paths/ErrorShortestPath.wima @@ -0,0 +1,5554 @@ +{ + "AreaItems": [ + { + "AreaType": "Measurement Area", + "BorderPolygonOffset": 5, + "BottomLayerAltitude": 5, + "LayerDistance": 1, + "NumberOfLayers": 1, + "ShowBorderPolygon": 0, + "maxAltitude": 30, + "polygon": [ + [ + 47.768165034497954, + 16.530367114686015 + ], + [ + 47.768387399161995, + 16.530999731467745 + ], + [ + 47.76812854504581, + 16.531122155188 + ], + [ + 47.76786601618492, + 16.5303875186394 + ] + ] + }, + { + "AreaType": "Service Area", + "BorderPolygonOffset": 5, + "ShowBorderPolygon": 0, + "maxAltitude": 30, + "polygon": [ + [ + 47.76776732265493, + 16.530415210899026 + ], + [ + 47.7679416889412, + 16.53088605132929 + ], + [ + 47.767792547023724, + 16.530894795694252 + ], + [ + 47.76760642514769, + 16.53044290179302 + ] + ] + }, + { + "AreaType": "Corridor", + "BorderPolygonOffset": 5, + "ShowBorderPolygon": 0, + "maxAltitude": 30, + "polygon": [ + [ + 47.76803587211828, + 16.530756233575623 + ], + [ + 47.768090728907424, + 16.53095307457629 + ], + [ + 47.76792493389012, + 16.530976392623735 + ], + [ + 47.76785734226939, + 16.530773721840692 + ] + ] + } + ], + "MissionItems": { + "fileType": "Plan", + "geoFence": { + "circles": [ + ], + "polygons": [ + ], + "version": 2 + }, + "groundStation": "QGroundControl", + "mission": { + "cruiseSpeed": 15, + "firmwareType": 3, + "hoverSpeed": 5, + "items": [ + { + "autoContinue": true, + "command": 22, + "doJumpId": 1, + "frame": 3, + "params": [ + 15, + 0, + 0, + null, + 47.76777699617343, + 16.53065973954301, + 5 + ], + "type": "SimpleItem" + }, + { + "AMSLAltAboveTerrain": null, + "Altitude": 5, + "AltitudeMode": 1, + "autoContinue": true, + "command": 16, + "doJumpId": 2, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76789859352497, + 16.530769680987596, + 5 + ], + "type": "SimpleItem" + }, + { + "AMSLAltAboveTerrain": null, + "Altitude": 5, + "AltitudeMode": 1, + "autoContinue": true, + "command": 16, + "doJumpId": 3, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76799906808081, + 16.530759838792154, + 5 + ], + "type": "SimpleItem" + }, + { + "TransectStyleComplexItem": { + "CameraCalc": { + "AdjustedFootprintFrontal": 25, + "AdjustedFootprintSide": 25, + "CameraName": "Manual (no camera specs)", + "DistanceToSurface": 5, + "DistanceToSurfaceRelative": true, + "version": 1 + }, + "CameraShots": 0, + "CameraTriggerInTurnAround": true, + "FollowTerrain": false, + "HoverAndCapture": false, + "Items": [ + { + "autoContinue": true, + "command": 16, + "doJumpId": 4, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7680968573124, + 16.530371766856316, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 5, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76811582254947, + 16.53037764978413, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 6, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76813489046403, + 16.530382745325458, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 7, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76815404629094, + 16.53038704953459, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 8, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76817327519695, + 16.530390559078576, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 9, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76817327519695, + 16.530390559078576, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 10, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681857134856, + 16.53042594541198, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 11, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681857134856, + 16.53042594541198, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 12, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76816225587887, + 16.530422310445523, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 13, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768138891072546, + 16.530417532242407, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 14, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76811564423052, + 16.530411615948754, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 15, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768092540389624, + 16.53040456793642, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 16, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76806960443271, + 16.530396395796107, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 17, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768046861061784, + 16.530387108329208, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 18, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768024334771454, + 16.530376715538324, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 19, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768024334771454, + 16.530376715538324, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 20, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76796667739723, + 16.530380649873862, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 21, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76796667739723, + 16.530380649873862, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 22, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767988883185815, + 16.530393611778564, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 23, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76801135784704, + 16.53040550373601, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 24, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76803407809792, + 16.530416313426553, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 25, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76805702040109, + 16.530426029651732, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 26, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76808016098912, + 16.53043464234588, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 27, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76810347588919, + 16.530442142586548, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 28, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768126940947866, + 16.53044852260375, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 29, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76815053185617, + 16.530453775788008, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 30, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768174224174764, + 16.53045789669721, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 31, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76819799335922, + 16.530460881062247, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 32, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76819799335922, + 16.530460881062247, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 33, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768210133956146, + 16.53049542047698, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 34, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768210133956146, + 16.53049542047698, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 35, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76818478928466, + 16.53049289790534, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 36, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76815951503293, + 16.530489122487857, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 37, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76813433917114, + 16.530484098402667, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 38, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76810928956062, + 16.530477831209755, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 39, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76808439392294, + 16.530470327844824, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 40, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768059679809305, + 16.530461596611605, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 41, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76803517457002, + 16.530451647172665, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 42, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76801090532423, + 16.530440490538734, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 43, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767986898929934, + 16.530428139056486, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 44, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767963181954215, + 16.53041460639491, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 45, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76793978064389, + 16.530399907530164, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 46, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76791672089642, + 16.530384058729002, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 47, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76791672089642, + 16.530384058729002, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 48, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76787162369843, + 16.530387136002485, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 49, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76787162369843, + 16.530387136002485, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 50, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767894815089356, + 16.530405243243486, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 51, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76791839907587, + 16.530422190889684, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 52, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767942349473564, + 16.530437960124765, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 53, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76796663969126, + 16.53045253344076, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 54, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76799124276046, + 16.53046589465747, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 55, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76801613136532, + 16.53047802894046, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 56, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768041277872996, + 16.530488922817504, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 57, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768066654364276, + 16.53049856419355, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 58, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76809223266464, + 16.53050694236415, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 59, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768117984375486, + 16.530514048027346, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 60, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768143880905676, + 16.530519873293994, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 61, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681698935033, + 16.53052441169653, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 62, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76819599328757, + 16.53052765819613, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 63, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76822215128091, + 16.530529609188346, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 64, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76822215128091, + 16.530529609188346, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 65, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76823405884736, + 16.530563485642595, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 66, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76823405884736, + 16.530563485642595, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 67, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768205963015134, + 16.530562015595226, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 68, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76817791852138, + 16.530559093116405, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 69, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768149959275924, + 16.53055472173984, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 70, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768122119085525, + 16.530548906751143, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 71, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76809443161298, + 16.53054165518148, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 72, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76806693033642, + 16.530532975799044, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 73, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76803964850885, + 16.53052287909845, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 74, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768012619117926, + 16.530511377288065, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 75, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76798587484607, + 16.530498484275235, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 76, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76795944803096, + 16.530484215649466, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 77, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76793337062641, + 16.530468588663577, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 78, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76790767416376, + 16.53045162221285, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 79, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76788238971373, + 16.53043333681216, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 80, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76788238971373, + 16.53043333681216, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 81, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76790025639901, + 16.530483333296207, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 82, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76790025639901, + 16.530483333296207, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 83, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76792535538292, + 16.5304998231406, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 84, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76795080659952, + 16.530515071140453, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 85, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767976582299845, + 16.53052906067116, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 86, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76800265438115, + 16.530541776480216, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 87, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76802899441756, + 16.530553204703825, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 88, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76805557369106, + 16.530563332882014, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 89, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768082363222774, + 16.530572149972237, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 90, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76810933380462, + 16.53057964636139, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 91, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76813645603109, + 16.530585813876307, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 92, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76816370033136, + 16.530590645792667, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 93, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76819103700151, + 16.53059413684233, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 94, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768218436236886, + 16.53059628321907, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 95, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76824586816466, + 16.530597082582737, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 96, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76824586816466, + 16.530597082582737, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 97, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76825758911027, + 16.53063042810965, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 98, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76825758911027, + 16.53063042810965, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 99, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768228489916446, + 16.530630155027907, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 100, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768199413897484, + 16.530628406054845, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 101, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681703948606, + 16.53062518322402, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 102, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768141466546744, + 16.530620490282686, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 103, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681126625914, + 16.530614332687403, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 104, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76808401648543, + 16.53060671759772, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 105, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768055561536194, + 16.53059765386784, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 106, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768027330828765, + 16.530587152036325, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 107, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76799935718749, + 16.53057522431384, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 108, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76797167313784, + 16.530561884568968, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 109, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76794431086855, + 16.530547148312067, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 110, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76791730219423, + 16.530531032677253, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 111, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76791730219423, + 16.530531032677253, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 112, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767933682945674, + 16.53057687106115, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 113, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767933682945674, + 16.53057687106115, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 114, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76796050016813, + 16.530591492480067, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 115, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767987623559186, + 16.53060480522023, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 116, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76801502427649, + 16.530616795125194, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 117, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76804267318277, + 16.53062744944519, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 118, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76807054087687, + 16.53063675685067, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 119, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76809859772495, + 16.530644707444363, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 120, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76812681389204, + 16.530651292771807, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 121, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768155159373755, + 16.530656505830315, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 122, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681836040282, + 16.53066034107646, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 123, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76821211760802, + 16.53066279443192, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 124, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76824066979256, + 16.530663863287867, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 125, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768269230220135, + 16.5306635465077, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 126, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768269230220135, + 16.5306635465077, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 127, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76828079891726, + 16.530696458895015, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 128, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76828079891726, + 16.530696458895015, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 129, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768250160216155, + 16.53069732477519, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 130, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768219519491765, + 16.530696635356584, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 131, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768188912400596, + 16.53069439144148, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 132, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768158374560024, + 16.530690595641104, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 133, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768127941506826, + 16.530685252372628, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 134, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76809764865585, + 16.530678367853984, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 135, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76806753125879, + 16.530669950096673, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 136, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768037624363146, + 16.530660008896405, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 137, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768007962771485, + 16.530648555821724, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 138, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7679785810009, + 16.530635604200533, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 139, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767949513242854, + 16.530621169104595, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 140, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767949513242854, + 16.530621169104595, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 141, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76796488005392, + 16.53066417017122, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 142, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76796488005392, + 16.53066417017122, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 143, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76799375307206, + 16.530677300007397, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 144, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76802289989525, + 16.53068901442754, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 145, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768052289186485, + 16.53069930083698, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 146, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768081889348075, + 16.530708148176345, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 147, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681116685556, + 16.530715546933486, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 148, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768141594792155, + 16.530721489153677, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 149, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76817163588276, + 16.530725968448184, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 150, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76820175952893, + 16.530728980001122, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 151, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76823193334345, + 16.530730520574643, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 152, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76826212488515, + 16.53073058851241, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 153, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76829230169379, + 16.53072918374138, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 154, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76829230169379, + 16.53072918374138, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 155, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768303744257395, + 16.530761737284877, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 156, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768303744257395, + 16.530761737284877, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 157, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76827100455753, + 16.530763750908662, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 158, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76823823760327, + 16.530764071386557, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 159, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768205482939536, + 16.53076269833179, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 160, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768172780096435, + 16.530759633401445, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 161, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76814016854152, + 16.530754880294435, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 162, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768107687632174, + 16.530748444747072, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 163, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76807537656812, + 16.530740334526122, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 164, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768043274344095, + 16.53073055941944, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 165, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768011419702795, + 16.530719131224142, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 166, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767979851088114, + 16.530706063732406, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 167, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767979851088114, + 16.530706063732406, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 168, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76799448017746, + 16.53074700042663, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 169, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76799448017746, + 16.53074700042663, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 170, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76802585030093, + 16.530758884680075, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 171, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76805747052222, + 16.5307691979505, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 172, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76808930531048, + 16.530777928649144, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 173, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768121318893726, + 16.530785066965525, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 174, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768153475299094, + 16.530790604878504, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 175, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76818573839322, + 16.530794536165256, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 176, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76821807192286, + 16.530796856408294, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 177, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768250439555615, + 16.53079756300042, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 178, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768282804920794, + 16.53079665514765, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 179, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76831513165021, + 16.53079413387012, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 180, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76831513165021, + 16.53079413387012, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 181, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768326468346146, + 16.530826386225172, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 182, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768326468346146, + 16.530826386225172, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 183, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76829451784833, + 16.530829378562586, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 184, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76826251896718, + 16.53083082946827, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 185, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76823050528916, + 16.530830737419336, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 186, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768198510416305, + 16.53082910251239, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 187, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7681665679309, + 16.53082592646346, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 188, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768134711360226, + 16.530821212606174, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 189, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768102974141414, + 16.530814965888265, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 190, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76807138958631, + 16.530807192866373, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 191, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76803999084651, + 16.53079790169918, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 192, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7680088108786, + 16.530787102138827, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 193, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7680088108786, + 16.530787102138827, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 194, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76802287896369, + 16.530826468970506, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 195, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76802287896369, + 16.530826468970506, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 196, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76805733319977, + 16.53083726902433, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 197, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76809201939904, + 16.530846276795405, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 198, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76812689545574, + 16.530853481349148, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 199, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76816191903362, + 16.530858873939913, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 200, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768197047617384, + 16.530862448021605, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 201, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76823223856424, + 16.530864199255625, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 202, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7682674491557, + 16.530864125516143, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 203, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768302636649445, + 16.53086222689267, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 204, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76833775833117, + 16.530858505689952, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 205, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76833775833117, + 16.530858505689952, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 206, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76834900517007, + 16.530890502406063, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 207, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76834900517007, + 16.530890502406063, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 208, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76831423559776, + 16.530894682743828, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 209, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768279390985775, + 16.530897114194175, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 210, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768244511063145, + 16.530897793984824, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 211, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768209635599156, + 16.530896721340696, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 212, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76817480435801, + 16.530893897484788, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 213, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76814005705349, + 16.530889325636803, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 214, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76810543330368, + 16.53088301100945, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 215, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768070972585775, + 16.530874960802528, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 216, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76803671419109, + 16.530865184194695, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 217, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76803671419109, + 16.530865184194695, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 218, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76805034159424, + 16.530903317862656, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 219, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76805034159424, + 16.530903317862656, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 220, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76808441206061, + 16.530912144345077, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 221, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76811865858828, + 16.53091930549654, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 222, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76815304441419, + 16.530924793629676, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 223, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76818753262577, + 16.530928602853066, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 224, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76822208620053, + 16.530930729077586, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 225, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768256668045815, + 16.53093117002076, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 226, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76829124103863, + 16.530929925209254, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 227, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76832576806547, + 16.530926995979346, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 228, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7683602120622, + 16.53092238547551, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 229, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7683602120622, + 16.53092238547551, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 230, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768371381888414, + 16.53095416309423, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 231, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768371381888414, + 16.53095416309423, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 232, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76833724011976, + 16.53095917768784, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 233, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768303008387335, + 16.53096257330386, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 234, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76826872136423, + 16.53096434650289, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 235, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76823441377957, + 16.530964495488874, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 236, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76820012038328, + 16.530963020110892, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 237, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76816587591094, + 16.530959921863356, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 238, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76813171504857, + 16.53095520388446, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 239, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76809767239748, + 16.530948870953015, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 240, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76806378243927, + 16.530940929483606, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 241, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76806378243927, + 16.530940929483606, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 242, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76807705494942, + 16.530978070051745, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 243, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76807705494942, + 16.530978070051745, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 244, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768114995842254, + 16.53098596473778, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 245, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76815309844532, + 16.53099188975619, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 246, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76819131657876, + 16.53099583792592, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 247, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76822960392268, + 16.530997804461844, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 248, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76826791407331, + 16.530997786980542, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 249, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768306200599255, + 16.530995785503205, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 250, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76834441709773, + 16.530991802455596, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 251, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768382517250835, + 16.530985842665118, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 252, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768382517250835, + 16.530985842665118, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 253, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768329550550106, + 16.531027090670623, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 254, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768329550550106, + 16.531027090670623, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 255, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76829532550813, + 16.531029998713112, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 256, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76826105675079, + 16.53103135104005, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 257, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.768226776217205, + 16.531031146391044, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 258, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76819251585747, + 16.53102938495683, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 259, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76815830760287, + 16.5310260683791, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 260, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76812418333613, + 16.531021199748963, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 261, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7680901748617, + 16.53101478360407, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 262, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.7680901748617, + 16.53101478360407, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 263, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76810315586079, + 16.53105110843455, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 264, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76810315586079, + 16.53105110843455, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 265, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76813965485149, + 16.531057168685507, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 266, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76817626567139, + 16.531061484813126, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 267, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76821295067883, + 16.53106405237975, + 5 + ], + "type": "SimpleItem" + }, + { + "autoContinue": true, + "command": 16, + "doJumpId": 268, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76824967215588, + 16.53106486874552, + 5 + ], + "type": "SimpleItem" + } + ], + "Refly90Degrees": false, + "TurnAroundDistance": 10, + "VisualTransectPoints": [ + [ + 47.7680968573124, + 16.530371766856316 + ], + [ + 47.76811582254947, + 16.53037764978413 + ], + [ + 47.76813489046403, + 16.530382745325458 + ], + [ + 47.76815404629094, + 16.53038704953459 + ], + [ + 47.76817327519695, + 16.530390559078576 + ], + [ + 47.76817327519695, + 16.530390559078576 + ], + [ + 47.7681857134856, + 16.53042594541198 + ], + [ + 47.7681857134856, + 16.53042594541198 + ], + [ + 47.76816225587887, + 16.530422310445523 + ], + [ + 47.768138891072546, + 16.530417532242407 + ], + [ + 47.76811564423052, + 16.530411615948754 + ], + [ + 47.768092540389624, + 16.53040456793642 + ], + [ + 47.76806960443271, + 16.530396395796107 + ], + [ + 47.768046861061784, + 16.530387108329208 + ], + [ + 47.768024334771454, + 16.530376715538324 + ], + [ + 47.768024334771454, + 16.530376715538324 + ], + [ + 47.76796667739723, + 16.530380649873862 + ], + [ + 47.76796667739723, + 16.530380649873862 + ], + [ + 47.767988883185815, + 16.530393611778564 + ], + [ + 47.76801135784704, + 16.53040550373601 + ], + [ + 47.76803407809792, + 16.530416313426553 + ], + [ + 47.76805702040109, + 16.530426029651732 + ], + [ + 47.76808016098912, + 16.53043464234588 + ], + [ + 47.76810347588919, + 16.530442142586548 + ], + [ + 47.768126940947866, + 16.53044852260375 + ], + [ + 47.76815053185617, + 16.530453775788008 + ], + [ + 47.768174224174764, + 16.53045789669721 + ], + [ + 47.76819799335922, + 16.530460881062247 + ], + [ + 47.76819799335922, + 16.530460881062247 + ], + [ + 47.768210133956146, + 16.53049542047698 + ], + [ + 47.768210133956146, + 16.53049542047698 + ], + [ + 47.76818478928466, + 16.53049289790534 + ], + [ + 47.76815951503293, + 16.530489122487857 + ], + [ + 47.76813433917114, + 16.530484098402667 + ], + [ + 47.76810928956062, + 16.530477831209755 + ], + [ + 47.76808439392294, + 16.530470327844824 + ], + [ + 47.768059679809305, + 16.530461596611605 + ], + [ + 47.76803517457002, + 16.530451647172665 + ], + [ + 47.76801090532423, + 16.530440490538734 + ], + [ + 47.767986898929934, + 16.530428139056486 + ], + [ + 47.767963181954215, + 16.53041460639491 + ], + [ + 47.76793978064389, + 16.530399907530164 + ], + [ + 47.76791672089642, + 16.530384058729002 + ], + [ + 47.76791672089642, + 16.530384058729002 + ], + [ + 47.76787162369843, + 16.530387136002485 + ], + [ + 47.76787162369843, + 16.530387136002485 + ], + [ + 47.767894815089356, + 16.530405243243486 + ], + [ + 47.76791839907587, + 16.530422190889684 + ], + [ + 47.767942349473564, + 16.530437960124765 + ], + [ + 47.76796663969126, + 16.53045253344076 + ], + [ + 47.76799124276046, + 16.53046589465747 + ], + [ + 47.76801613136532, + 16.53047802894046 + ], + [ + 47.768041277872996, + 16.530488922817504 + ], + [ + 47.768066654364276, + 16.53049856419355 + ], + [ + 47.76809223266464, + 16.53050694236415 + ], + [ + 47.768117984375486, + 16.530514048027346 + ], + [ + 47.768143880905676, + 16.530519873293994 + ], + [ + 47.7681698935033, + 16.53052441169653 + ], + [ + 47.76819599328757, + 16.53052765819613 + ], + [ + 47.76822215128091, + 16.530529609188346 + ], + [ + 47.76822215128091, + 16.530529609188346 + ], + [ + 47.76823405884736, + 16.530563485642595 + ], + [ + 47.76823405884736, + 16.530563485642595 + ], + [ + 47.768205963015134, + 16.530562015595226 + ], + [ + 47.76817791852138, + 16.530559093116405 + ], + [ + 47.768149959275924, + 16.53055472173984 + ], + [ + 47.768122119085525, + 16.530548906751143 + ], + [ + 47.76809443161298, + 16.53054165518148 + ], + [ + 47.76806693033642, + 16.530532975799044 + ], + [ + 47.76803964850885, + 16.53052287909845 + ], + [ + 47.768012619117926, + 16.530511377288065 + ], + [ + 47.76798587484607, + 16.530498484275235 + ], + [ + 47.76795944803096, + 16.530484215649466 + ], + [ + 47.76793337062641, + 16.530468588663577 + ], + [ + 47.76790767416376, + 16.53045162221285 + ], + [ + 47.76788238971373, + 16.53043333681216 + ], + [ + 47.76788238971373, + 16.53043333681216 + ], + [ + 47.76790025639901, + 16.530483333296207 + ], + [ + 47.76790025639901, + 16.530483333296207 + ], + [ + 47.76792535538292, + 16.5304998231406 + ], + [ + 47.76795080659952, + 16.530515071140453 + ], + [ + 47.767976582299845, + 16.53052906067116 + ], + [ + 47.76800265438115, + 16.530541776480216 + ], + [ + 47.76802899441756, + 16.530553204703825 + ], + [ + 47.76805557369106, + 16.530563332882014 + ], + [ + 47.768082363222774, + 16.530572149972237 + ], + [ + 47.76810933380462, + 16.53057964636139 + ], + [ + 47.76813645603109, + 16.530585813876307 + ], + [ + 47.76816370033136, + 16.530590645792667 + ], + [ + 47.76819103700151, + 16.53059413684233 + ], + [ + 47.768218436236886, + 16.53059628321907 + ], + [ + 47.76824586816466, + 16.530597082582737 + ], + [ + 47.76824586816466, + 16.530597082582737 + ], + [ + 47.76825758911027, + 16.53063042810965 + ], + [ + 47.76825758911027, + 16.53063042810965 + ], + [ + 47.768228489916446, + 16.530630155027907 + ], + [ + 47.768199413897484, + 16.530628406054845 + ], + [ + 47.7681703948606, + 16.53062518322402 + ], + [ + 47.768141466546744, + 16.530620490282686 + ], + [ + 47.7681126625914, + 16.530614332687403 + ], + [ + 47.76808401648543, + 16.53060671759772 + ], + [ + 47.768055561536194, + 16.53059765386784 + ], + [ + 47.768027330828765, + 16.530587152036325 + ], + [ + 47.76799935718749, + 16.53057522431384 + ], + [ + 47.76797167313784, + 16.530561884568968 + ], + [ + 47.76794431086855, + 16.530547148312067 + ], + [ + 47.76791730219423, + 16.530531032677253 + ], + [ + 47.76791730219423, + 16.530531032677253 + ], + [ + 47.767933682945674, + 16.53057687106115 + ], + [ + 47.767933682945674, + 16.53057687106115 + ], + [ + 47.76796050016813, + 16.530591492480067 + ], + [ + 47.767987623559186, + 16.53060480522023 + ], + [ + 47.76801502427649, + 16.530616795125194 + ], + [ + 47.76804267318277, + 16.53062744944519 + ], + [ + 47.76807054087687, + 16.53063675685067 + ], + [ + 47.76809859772495, + 16.530644707444363 + ], + [ + 47.76812681389204, + 16.530651292771807 + ], + [ + 47.768155159373755, + 16.530656505830315 + ], + [ + 47.7681836040282, + 16.53066034107646 + ], + [ + 47.76821211760802, + 16.53066279443192 + ], + [ + 47.76824066979256, + 16.530663863287867 + ], + [ + 47.768269230220135, + 16.5306635465077 + ], + [ + 47.768269230220135, + 16.5306635465077 + ], + [ + 47.76828079891726, + 16.530696458895015 + ], + [ + 47.76828079891726, + 16.530696458895015 + ], + [ + 47.768250160216155, + 16.53069732477519 + ], + [ + 47.768219519491765, + 16.530696635356584 + ], + [ + 47.768188912400596, + 16.53069439144148 + ], + [ + 47.768158374560024, + 16.530690595641104 + ], + [ + 47.768127941506826, + 16.530685252372628 + ], + [ + 47.76809764865585, + 16.530678367853984 + ], + [ + 47.76806753125879, + 16.530669950096673 + ], + [ + 47.768037624363146, + 16.530660008896405 + ], + [ + 47.768007962771485, + 16.530648555821724 + ], + [ + 47.7679785810009, + 16.530635604200533 + ], + [ + 47.767949513242854, + 16.530621169104595 + ], + [ + 47.767949513242854, + 16.530621169104595 + ], + [ + 47.76796488005392, + 16.53066417017122 + ], + [ + 47.76796488005392, + 16.53066417017122 + ], + [ + 47.76799375307206, + 16.530677300007397 + ], + [ + 47.76802289989525, + 16.53068901442754 + ], + [ + 47.768052289186485, + 16.53069930083698 + ], + [ + 47.768081889348075, + 16.530708148176345 + ], + [ + 47.7681116685556, + 16.530715546933486 + ], + [ + 47.768141594792155, + 16.530721489153677 + ], + [ + 47.76817163588276, + 16.530725968448184 + ], + [ + 47.76820175952893, + 16.530728980001122 + ], + [ + 47.76823193334345, + 16.530730520574643 + ], + [ + 47.76826212488515, + 16.53073058851241 + ], + [ + 47.76829230169379, + 16.53072918374138 + ], + [ + 47.76829230169379, + 16.53072918374138 + ], + [ + 47.768303744257395, + 16.530761737284877 + ], + [ + 47.768303744257395, + 16.530761737284877 + ], + [ + 47.76827100455753, + 16.530763750908662 + ], + [ + 47.76823823760327, + 16.530764071386557 + ], + [ + 47.768205482939536, + 16.53076269833179 + ], + [ + 47.768172780096435, + 16.530759633401445 + ], + [ + 47.76814016854152, + 16.530754880294435 + ], + [ + 47.768107687632174, + 16.530748444747072 + ], + [ + 47.76807537656812, + 16.530740334526122 + ], + [ + 47.768043274344095, + 16.53073055941944 + ], + [ + 47.768011419702795, + 16.530719131224142 + ], + [ + 47.767979851088114, + 16.530706063732406 + ], + [ + 47.767979851088114, + 16.530706063732406 + ], + [ + 47.76799448017746, + 16.53074700042663 + ], + [ + 47.76799448017746, + 16.53074700042663 + ], + [ + 47.76802585030093, + 16.530758884680075 + ], + [ + 47.76805747052222, + 16.5307691979505 + ], + [ + 47.76808930531048, + 16.530777928649144 + ], + [ + 47.768121318893726, + 16.530785066965525 + ], + [ + 47.768153475299094, + 16.530790604878504 + ], + [ + 47.76818573839322, + 16.530794536165256 + ], + [ + 47.76821807192286, + 16.530796856408294 + ], + [ + 47.768250439555615, + 16.53079756300042 + ], + [ + 47.768282804920794, + 16.53079665514765 + ], + [ + 47.76831513165021, + 16.53079413387012 + ], + [ + 47.76831513165021, + 16.53079413387012 + ], + [ + 47.768326468346146, + 16.530826386225172 + ], + [ + 47.768326468346146, + 16.530826386225172 + ], + [ + 47.76829451784833, + 16.530829378562586 + ], + [ + 47.76826251896718, + 16.53083082946827 + ], + [ + 47.76823050528916, + 16.530830737419336 + ], + [ + 47.768198510416305, + 16.53082910251239 + ], + [ + 47.7681665679309, + 16.53082592646346 + ], + [ + 47.768134711360226, + 16.530821212606174 + ], + [ + 47.768102974141414, + 16.530814965888265 + ], + [ + 47.76807138958631, + 16.530807192866373 + ], + [ + 47.76803999084651, + 16.53079790169918 + ], + [ + 47.7680088108786, + 16.530787102138827 + ], + [ + 47.7680088108786, + 16.530787102138827 + ], + [ + 47.76802287896369, + 16.530826468970506 + ], + [ + 47.76802287896369, + 16.530826468970506 + ], + [ + 47.76805733319977, + 16.53083726902433 + ], + [ + 47.76809201939904, + 16.530846276795405 + ], + [ + 47.76812689545574, + 16.530853481349148 + ], + [ + 47.76816191903362, + 16.530858873939913 + ], + [ + 47.768197047617384, + 16.530862448021605 + ], + [ + 47.76823223856424, + 16.530864199255625 + ], + [ + 47.7682674491557, + 16.530864125516143 + ], + [ + 47.768302636649445, + 16.53086222689267 + ], + [ + 47.76833775833117, + 16.530858505689952 + ], + [ + 47.76833775833117, + 16.530858505689952 + ], + [ + 47.76834900517007, + 16.530890502406063 + ], + [ + 47.76834900517007, + 16.530890502406063 + ], + [ + 47.76831423559776, + 16.530894682743828 + ], + [ + 47.768279390985775, + 16.530897114194175 + ], + [ + 47.768244511063145, + 16.530897793984824 + ], + [ + 47.768209635599156, + 16.530896721340696 + ], + [ + 47.76817480435801, + 16.530893897484788 + ], + [ + 47.76814005705349, + 16.530889325636803 + ], + [ + 47.76810543330368, + 16.53088301100945 + ], + [ + 47.768070972585775, + 16.530874960802528 + ], + [ + 47.76803671419109, + 16.530865184194695 + ], + [ + 47.76803671419109, + 16.530865184194695 + ], + [ + 47.76805034159424, + 16.530903317862656 + ], + [ + 47.76805034159424, + 16.530903317862656 + ], + [ + 47.76808441206061, + 16.530912144345077 + ], + [ + 47.76811865858828, + 16.53091930549654 + ], + [ + 47.76815304441419, + 16.530924793629676 + ], + [ + 47.76818753262577, + 16.530928602853066 + ], + [ + 47.76822208620053, + 16.530930729077586 + ], + [ + 47.768256668045815, + 16.53093117002076 + ], + [ + 47.76829124103863, + 16.530929925209254 + ], + [ + 47.76832576806547, + 16.530926995979346 + ], + [ + 47.7683602120622, + 16.53092238547551 + ], + [ + 47.7683602120622, + 16.53092238547551 + ], + [ + 47.768371381888414, + 16.53095416309423 + ], + [ + 47.768371381888414, + 16.53095416309423 + ], + [ + 47.76833724011976, + 16.53095917768784 + ], + [ + 47.768303008387335, + 16.53096257330386 + ], + [ + 47.76826872136423, + 16.53096434650289 + ], + [ + 47.76823441377957, + 16.530964495488874 + ], + [ + 47.76820012038328, + 16.530963020110892 + ], + [ + 47.76816587591094, + 16.530959921863356 + ], + [ + 47.76813171504857, + 16.53095520388446 + ], + [ + 47.76809767239748, + 16.530948870953015 + ], + [ + 47.76806378243927, + 16.530940929483606 + ], + [ + 47.76806378243927, + 16.530940929483606 + ], + [ + 47.76807705494942, + 16.530978070051745 + ], + [ + 47.76807705494942, + 16.530978070051745 + ], + [ + 47.768114995842254, + 16.53098596473778 + ], + [ + 47.76815309844532, + 16.53099188975619 + ], + [ + 47.76819131657876, + 16.53099583792592 + ], + [ + 47.76822960392268, + 16.530997804461844 + ], + [ + 47.76826791407331, + 16.530997786980542 + ], + [ + 47.768306200599255, + 16.530995785503205 + ], + [ + 47.76834441709773, + 16.530991802455596 + ], + [ + 47.768382517250835, + 16.530985842665118 + ], + [ + 47.768382517250835, + 16.530985842665118 + ], + [ + 47.768329550550106, + 16.531027090670623 + ], + [ + 47.768329550550106, + 16.531027090670623 + ], + [ + 47.76829532550813, + 16.531029998713112 + ], + [ + 47.76826105675079, + 16.53103135104005 + ], + [ + 47.768226776217205, + 16.531031146391044 + ], + [ + 47.76819251585747, + 16.53102938495683 + ], + [ + 47.76815830760287, + 16.5310260683791 + ], + [ + 47.76812418333613, + 16.531021199748963 + ], + [ + 47.7680901748617, + 16.53101478360407 + ], + [ + 47.7680901748617, + 16.53101478360407 + ], + [ + 47.76810315586079, + 16.53105110843455 + ], + [ + 47.76810315586079, + 16.53105110843455 + ], + [ + 47.76813965485149, + 16.531057168685507 + ], + [ + 47.76817626567139, + 16.531061484813126 + ], + [ + 47.76821295067883, + 16.53106405237975 + ], + [ + 47.76824967215588, + 16.53106486874552 + ] + ], + "version": 1 + }, + "complexItemType": "circularSurvey", + "deltaAlpha": 2, + "deltaR": 2.5, + "fixedDirection": false, + "polygon": [ + [ + 47.768165034497954, + 16.530367114686015 + ], + [ + 47.768387399161995, + 16.530999731467745 + ], + [ + 47.76812854504581, + 16.531122155188 + ], + [ + 47.76786601618492, + 16.5303875186394 + ] + ], + "referencePointAlt": 0, + "referencePointLat": 47.76824842154532, + "referencePointLong": 16.529360809158533, + "reverse": false, + "transectMinLength": 8, + "type": "ComplexItem", + "version": 1 + }, + { + "AMSLAltAboveTerrain": null, + "Altitude": 5, + "AltitudeMode": 1, + "autoContinue": true, + "command": 16, + "doJumpId": 272, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.767898593524976, + 16.5307696809876, + 5 + ], + "type": "SimpleItem" + }, + { + "AMSLAltAboveTerrain": null, + "Altitude": 0, + "AltitudeMode": 1, + "autoContinue": true, + "command": 21, + "doJumpId": 273, + "frame": 3, + "params": [ + 0, + 0, + 0, + null, + 47.76777699617345, + 16.530659739543026, + 0 + ], + "type": "SimpleItem" + } + ], + "plannedHomePosition": [ + 47.76777699617345, + 16.530659739543026, + 178 + ], + "vehicleType": 2, + "version": 2 + }, + "rallyPoints": { + "points": [ + ], + "version": 2 + }, + "version": 1 + } +} diff --git a/src/FlightDisplay/FlightDisplayWimaMenu.qml b/src/FlightDisplay/FlightDisplayWimaMenu.qml index 7fd514b70620331dc5f936795e6f48831df86ee0..35c1333e4c1f011812c5b57f3205e0991d0c9da7 100644 --- a/src/FlightDisplay/FlightDisplayWimaMenu.qml +++ b/src/FlightDisplay/FlightDisplayWimaMenu.qml @@ -301,12 +301,6 @@ Item { Layout.fillWidth: true } - FactCheckBox { - text: qsTr("Invert Phase") - fact: wimaController.reverse - Layout.fillWidth: true - } - } SectionHeader{ diff --git a/src/MissionManager/MissionController.cc b/src/MissionManager/MissionController.cc index 7fff83cef486457fc7f9a11e008aab61dc12a1e8..15c121f22cbf77bb8a76665f01f9b68f4b0afe7f 100644 --- a/src/MissionManager/MissionController.cc +++ b/src/MissionManager/MissionController.cc @@ -485,7 +485,7 @@ int MissionController::insertSimpleMissionItem(const MissionItem &missionItem, i return newItem->sequenceNumber(); } -int MissionController::insertSimpleMissionItem(SimpleMissionItem &missionItem, int i) +int MissionController::insertSimpleMissionItem(const SimpleMissionItem &missionItem, int i) { int sequenceNumber = _nextSequenceNumber(); SimpleMissionItem * newItem = new SimpleMissionItem(missionItem, _flyView, this); diff --git a/src/MissionManager/MissionController.h b/src/MissionManager/MissionController.h index 3763f12b1b1d47531c7249f8f1d0520f4e623160..aadbffc2df2c7be0373d1d7bd7a3a6fddfce31f4 100644 --- a/src/MissionManager/MissionController.h +++ b/src/MissionManager/MissionController.h @@ -124,7 +124,7 @@ public: /// Add a new simple mission item to the list /// @param i: index to insert at /// @return Sequence number for new item - int insertSimpleMissionItem(SimpleMissionItem &missionItem, int i); + int insertSimpleMissionItem(const SimpleMissionItem &missionItem, int i); /// Add a new ROI mission item to the list /// @param i: index to insert at diff --git a/src/Wima/Geometry/PolygonCalculus.cc b/src/Wima/Geometry/PolygonCalculus.cc index 0e28adc54e1e0bdc7b4b7d102dd7772214be73c5..a296ed1e98b74e23bef029f011e279f5e05d30ed 100644 --- a/src/Wima/Geometry/PolygonCalculus.cc +++ b/src/Wima/Geometry/PolygonCalculus.cc @@ -479,7 +479,7 @@ namespace PolygonCalculus { { using namespace PlanimetryCalculus; QPolygonF bigPolygon(polygon); - offsetPolygon(bigPolygon, 0.1); // solves numerical errors + offsetPolygon(bigPolygon, 0.5); // solves numerical errors if ( bigPolygon.containsPoint(startVertex, Qt::FillRule::OddEvenFill) && bigPolygon.containsPoint(endVertex, Qt::FillRule::OddEvenFill)) { diff --git a/src/Wima/WaypointManager/DefaultManager.cpp b/src/Wima/WaypointManager/DefaultManager.cpp index 8ec5ff3c848a4d9f8753754cef79fee7e1a863ff..07d3632d091ee58e0bb7705308e03bdfe581a840 100644 --- a/src/Wima/WaypointManager/DefaultManager.cpp +++ b/src/Wima/WaypointManager/DefaultManager.cpp @@ -4,57 +4,86 @@ #include "MissionSettingsItem.h" +WaypointManager::DefaultManager::DefaultManager(Settings &settings, + AreaInterface &interface) + : ManagerBase(settings) + , _areaInterface(&interface) +{ + +} + +void WaypointManager::DefaultManager::clear() +{ + _dirty = true; + _waypoints.clear(); + _currentWaypoints.clear(); + _missionItems.clearAndDeleteContents(); + _currentMissionItems.clearAndDeleteContents(); + _waypointsVariant.clear(); + _currentWaypointsVariant.clear(); +} + bool WaypointManager::DefaultManager::update() { // extract waypoints - _slice.clear(); - Slicer::update(_waypoints, _slice); + _currentWaypoints.clear(); + Slicer::update(_waypoints, _currentWaypoints); return _worker(); } bool WaypointManager::DefaultManager::next() { // extract waypoints - _slice.clear(); - Slicer::next(_waypoints, _slice); + _currentWaypoints.clear(); + Slicer::next(_waypoints, _currentWaypoints); return _worker(); } bool WaypointManager::DefaultManager::previous() { // extract waypoints - _slice.clear(); - Slicer::previous(_waypoints, _slice); + _currentWaypoints.clear(); + Slicer::previous(_waypoints, _currentWaypoints); return _worker(); } bool WaypointManager::DefaultManager::reset() { // extract waypoints - _slice.clear(); - Slicer::reset(_waypoints, _slice); + _currentWaypoints.clear(); + Slicer::reset(_waypoints, _currentWaypoints); return _worker(); } -bool WaypointManager::DefaultManager::_insertMissionItem(size_t index, const QGeoCoordinate &c, bool doUpdate) +bool WaypointManager::DefaultManager::_insertMissionItem(const QGeoCoordinate &c, + size_t index, + QmlObjectListModel &list, + bool doUpdate) { using namespace WaypointManager::Utils; if ( !insertMissionItem(c, index /*insertion index*/, - _missionItems, + list, _settings->vehicle(), _settings->isFlyView(), - &_missionItems /*parent*/, + &_currentMissionItems /*parent*/, doUpdate /*do update*/) ) { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): insertMissionItem failed."); return false; } return true; } +bool WaypointManager::DefaultManager::_insertMissionItem(const QGeoCoordinate &c, + size_t index, + bool doUpdate) +{ + return _insertMissionItem(c, index, _currentMissionItems, doUpdate); +} + bool WaypointManager::DefaultManager::_calcShortestPath( const QGeoCoordinate &start, const QGeoCoordinate &destination, @@ -77,33 +106,53 @@ bool WaypointManager::DefaultManager::_worker() { using namespace WaypointManager::Utils; - if (_waypoints.count() < 1) { + if (_waypoints.count() < 1 || !_settings->valid()) { return false; } - _missionItems.clearAndDeleteContents(); - initialize(_missionItems, _settings->vehicle(), _settings->isFlyView()); + if (_dirty) { + _missionItems.clearAndDeleteContents(); + _waypointsVariant.clear(); + initialize(_missionItems, _settings->vehicle(), _settings->isFlyView()); + for (size_t i = 0; i < size_t(_waypoints.size()); ++i) { + const QGeoCoordinate &c = _waypoints.at(i); + _insertMissionItem(c, _missionItems.count(), _missionItems, false /*update list*/); + _waypointsVariant.push_back(QVariant::fromValue(c)); + } + Q_ASSERT(_missionItems.value(0) != nullptr); + doUpdate(_missionItems); + + _dirty = false; + } + + _currentMissionItems.clearAndDeleteContents(); + initialize(_currentMissionItems, _settings->vehicle(), _settings->isFlyView()); // calculate path from home to first waypoint QVector arrivalPath; if (!_settings->homePosition().isValid()){ - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): home position invalid."); return false; } - if ( !_calcShortestPath(_settings->homePosition(), _slice.first(), arrivalPath) ) { - assert(false); + if ( !_calcShortestPath(_settings->homePosition(), _currentWaypoints.first(), arrivalPath) ) { + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): Not able to calc path from home position to first waypoint."); return false; } arrivalPath.removeFirst(); // calculate path from last waypoint to home + qDebug() << "_currentWaypoints.size(): " << _currentWaypoints.size(); + qDebug() << "_currentWaypoints.first(): " << _currentWaypoints.first(); + qDebug() << "_currentWaypoints.last(): " << _currentWaypoints.last(); + qDebug() << "_settings->homePosition(): " << _settings->homePosition(); QVector returnPath; - if ( !_calcShortestPath(_slice.last(), _settings->homePosition(), returnPath) ) { - assert(false); + //if ( !_calcShortestPath(_currentWaypoints.last(), _settings->homePosition(), returnPath) ) { + if ( !_calcShortestPath(_settings->homePosition(), _currentWaypoints.first(), returnPath) ) { + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): Not able to calc path from home position to last waypoint."); - return false; + //return false; } returnPath.removeFirst(); returnPath.removeLast(); @@ -112,29 +161,29 @@ bool WaypointManager::DefaultManager::_worker() // Create mission items. // Set home position of MissionSettingsItem. - MissionSettingsItem* settingsItem = _missionItems.value(0); + MissionSettingsItem* settingsItem = _currentMissionItems.value(0); if (settingsItem == nullptr) { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): nullptr."); return false; } settingsItem->setCoordinate(_settings->homePosition()); // Set takeoff position for first mission item (bug). - _insertMissionItem(1 /*insertion index*/, _settings->homePosition(), false /*do update*/); - SimpleMissionItem *takeoffItem = _missionItems.value(1); + _insertMissionItem(_settings->homePosition(), 1 /*insertion index*/, false /*do update*/); + SimpleMissionItem *takeoffItem = _currentMissionItems.value(1); if (takeoffItem == nullptr) { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): nullptr."); return false; } takeoffItem->setCoordinate(_settings->homePosition()); // Create change speed item. - _insertMissionItem(2 /*insertion index*/, _settings->homePosition(), false /*do update*/); - SimpleMissionItem *speedItem = _missionItems.value(2); + _insertMissionItem(_settings->homePosition(), 2 /*insertion index*/, false /*do update*/); + SimpleMissionItem *speedItem = _currentMissionItems.value(2); if (speedItem == nullptr) { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): nullptr."); return false; } @@ -145,57 +194,57 @@ bool WaypointManager::DefaultManager::_worker() // insert arrival path for (auto coordinate : arrivalPath) { - _insertMissionItem(_missionItems.count() /*insertion index*/, - coordinate, + _insertMissionItem(coordinate, + _currentMissionItems.count() /*insertion index*/, false /*do update*/); } // Create change speed item (after arrival path). - int index = _missionItems.count(); - _insertMissionItem(index /*insertion index*/, _slice.first(), false /*do update*/); - speedItem = _missionItems.value(index); + int index = _currentMissionItems.count(); + _insertMissionItem(_currentWaypoints.first(), index /*insertion index*/, false /*do update*/); + speedItem = _currentMissionItems.value(index); if (speedItem == nullptr) { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): nullptr."); return false; } speedItem->setCommand(MAV_CMD_DO_CHANGE_SPEED); // set coordinate must be after setCommand (setCommand sets coordinate to zero) - speedItem->setCoordinate(_slice.first()); + speedItem->setCoordinate(_currentWaypoints.first()); speedItem->missionItem().setParam2(_settings->flightSpeed()); // Insert slice. - for (auto coordinate : _slice) { - _insertMissionItem(_missionItems.count() /*insertion index*/, - coordinate, + for (auto coordinate : _currentWaypoints) { + _insertMissionItem(coordinate, + _currentMissionItems.count() /*insertion index*/, false /*do update*/); } // Create change speed item, after slice. - index = _missionItems.count(); - _insertMissionItem(index /*insertion index*/, _slice.last(), false /*do update*/); - speedItem = _missionItems.value(index); + index = _currentMissionItems.count(); + _insertMissionItem(_currentWaypoints.last(), index /*insertion index*/, false /*do update*/); + speedItem = _currentMissionItems.value(index); if (speedItem == nullptr) { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): nullptr."); return false; } speedItem->setCommand(MAV_CMD_DO_CHANGE_SPEED); // set coordinate must be after setCommand (setCommand sets coordinate to zero) - speedItem->setCoordinate(_slice.last()); + speedItem->setCoordinate(_currentWaypoints.last()); speedItem->missionItem().setParam2(_settings->arrivalReturnSpeed()); // Insert return path coordinates. for (auto coordinate : returnPath) { - _insertMissionItem(_missionItems.count() /*insertion index*/, - coordinate, + _insertMissionItem(coordinate, + _currentMissionItems.count() /*insertion index*/, false /*do update*/); } // Set land command for last mission item. - index = _missionItems.count(); - _insertMissionItem(index /*insertion index*/, _settings->homePosition(), false /*do update*/); - SimpleMissionItem *landItem = _missionItems.value(index); + index = _currentMissionItems.count(); + _insertMissionItem(_settings->homePosition(), index /*insertion index*/, false /*do update*/); + SimpleMissionItem *landItem = _currentMissionItems.value(index); if (landItem == nullptr) { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): nullptr."); return false; } @@ -204,24 +253,28 @@ bool WaypointManager::DefaultManager::_worker() if (_settings->vehicle()->firmwarePlugin()->supportedMissionCommands().contains(landCmd)) { landItem->setCommand(landCmd); } else { - assert(false); + Q_ASSERT(false); qWarning("WaypointManager::DefaultManager::next(): Land command not supported!"); return false; } // Prepend arrival path to slice. for ( long i = arrivalPath.size()-1; i >=0; --i ) - _slice.push_front(arrivalPath[i]); + _currentWaypoints.push_front(arrivalPath[i]); // Append return path to slice. for ( auto c : returnPath ) - _slice.push_back(c); + _currentWaypoints.push_back(c); + + _currentWaypointsVariant.clear(); + for ( auto c : _currentWaypoints) + _currentWaypointsVariant.push_back(QVariant::fromValue(c)); // Set altitude. - for (int i = 0; i < _missionItems.count(); ++i) { - SimpleMissionItem *item = _missionItems.value(i); + for (int i = 0; i < _currentMissionItems.count(); ++i) { + SimpleMissionItem *item = _currentMissionItems.value(i); if (item == nullptr) { - assert(false); + Q_ASSERT(false); qWarning("WimaController::updateAltitude(): nullptr"); return false; } diff --git a/src/Wima/WaypointManager/DefaultManager.h b/src/Wima/WaypointManager/DefaultManager.h index 19cd2e50487a35c5d9d418c70a92a750527adc90..ff0ee73c133e43f5d535e4bfdfe5f028ba742020 100644 --- a/src/Wima/WaypointManager/DefaultManager.h +++ b/src/Wima/WaypointManager/DefaultManager.h @@ -20,8 +20,10 @@ class DefaultManager : public ManagerBase { public: DefaultManager() = delete; - DefaultManager(Settings *settings, - AreaInterface *interface); + DefaultManager(Settings &settings, + AreaInterface &interface); + + void clear() override; virtual bool update() override; @@ -30,7 +32,13 @@ public: virtual bool reset() override; protected: - bool _insertMissionItem(size_t index, const QGeoCoordinate &c, bool doUpdate); + bool _insertMissionItem(const QGeoCoordinate &c, + size_t index, + QmlObjectListModel &list, + bool doUpdate); + bool _insertMissionItem(const QGeoCoordinate &c, + size_t index, + bool doUpdate); bool _calcShortestPath(const QGeoCoordinate &start, const QGeoCoordinate &destination, QVector &path); diff --git a/src/Wima/WaypointManager/GenericWaypointManager.h b/src/Wima/WaypointManager/GenericWaypointManager.h index f1e3e4b88beec85b0162b9039aa864c103e95dac..54a126ac6d69d59fb5824cfd959853d37575e466 100644 --- a/src/Wima/WaypointManager/GenericWaypointManager.h +++ b/src/Wima/WaypointManager/GenericWaypointManager.h @@ -16,21 +16,25 @@ public: typedef ContainerType WaypointList; GenericWaypointManager() = delete; - GenericWaypointManager(SettingsType *settings); + GenericWaypointManager(SettingsType &settings); // Waypoint editing. void setWaypoints(const WaypointList &waypoints); void push_back (const WaypointType &wp); void push_front (const WaypointType &wp); - void clear (); + virtual void clear (); void insert (std::size_t i, const WaypointType &wp); std::size_t size () const; WaypointType &at (std::size_t i); const WaypointList &waypoints() const; - const WaypointList &slice() const; + const WaypointList ¤tWaypoints() const; const MissionItemList &missionItems() const; + const MissionItemList ¤tMissionItems() const; + + const QVariantList &waypointsVariant() const; + const QVariantList ¤tWaypointsVariant() const; virtual bool update() = 0; virtual bool next() = 0; @@ -39,9 +43,13 @@ public: protected: WaypointList _waypoints; - WaypointList _slice; + WaypointList _currentWaypoints; + MissionItemList _currentMissionItems; MissionItemList _missionItems; SettingsType *_settings; + bool _dirty; + QVariantList _waypointsVariant; + QVariantList _currentWaypointsVariant; }; @@ -52,9 +60,10 @@ template::GenericWaypointManager(SettingsType *Settings - ) - : _settings(_settings) + SettingsType>::GenericWaypointManager(SettingsType &settings) + : Slicer() + , _settings(&settings) + , _dirty(true) {} template::push_back(const WaypointType &wp) { + _dirty = true; _waypoints.push_back(wp); } @@ -79,6 +89,7 @@ void GenericWaypointManager::push_front( const WaypointType &wp) { + _dirty = true; _waypoints.push_front(wp); } @@ -91,7 +102,13 @@ void GenericWaypointManager::clear() { + _dirty = true; _waypoints.clear(); + _currentWaypoints.clear(); + _missionItems.clear(); + _currentMissionItems.clear(); + _waypointsVariant.clear(); + _currentWaypointsVariant.clear(); } template::insert(std::size_t i, const WaypointType &wp) { + _dirty = true; _waypoints.insert(i, wp); } @@ -131,6 +149,30 @@ WaypointType & GenericWaypointManager class ContainerType, + class MissionItemList, + class SettingsType> +const QVariantList &GenericWaypointManager::waypointsVariant() const +{ + return _waypointsVariant; +} + +template class ContainerType, + class MissionItemList, + class SettingsType> +const QVariantList &GenericWaypointManager::currentWaypointsVariant() const +{ + return _currentWaypointsVariant; +} + template class ContainerType, class MissionItemList, @@ -150,9 +192,9 @@ template &GenericWaypointManager::slice() const + SettingsType>::currentWaypoints() const { - return _slice; + return _currentWaypoints; } template class ContainerType, + class MissionItemList, + class SettingsType> +const MissionItemList &GenericWaypointManager::currentMissionItems() const +{ + return _currentMissionItems; +} + template class ContainerType, class MissionItemList, diff --git a/src/Wima/WaypointManager/Settings.cpp b/src/Wima/WaypointManager/Settings.cpp index 80e0e1926bafb14d7d9c6c9c1068fb0eaa36b95d..0a7934be118a3a6fe02f22bc133299780f222f51 100644 --- a/src/Wima/WaypointManager/Settings.cpp +++ b/src/Wima/WaypointManager/Settings.cpp @@ -1,12 +1,34 @@ #include "Settings.h" -void WaypointManager::Settings::setHomePosition(QGeoCoordinate &c) +WaypointManager::Settings::Settings() + : _missionController(nullptr) + , _isFlyView(true) + , _arrivalReturnSpeed(5) + , _flightSpeed(2) + , _altitude(5) +{ + +} + +bool WaypointManager::Settings::valid() const +{ + return _missionController != nullptr + && _homePosition.isValid(); +} + +void WaypointManager::Settings::setHomePosition(const QGeoCoordinate &c) { _homePosition = c; } -void WaypointManager::Settings::setVehicle(Vehicle *vehicle) + +void WaypointManager::Settings::setMissionController(MissionController *controller) +{ + _missionController = controller; +} + +void WaypointManager::Settings::setMasterController(PlanMasterController *controller) { - _vehicle = vehicle; + _masterController = controller; } void WaypointManager::Settings::setIsFlyView(bool isFlyView) @@ -37,9 +59,24 @@ const QGeoCoordinate &WaypointManager::Settings::homePosition() const return _homePosition; } +QGeoCoordinate &WaypointManager::Settings::homePosition() +{ + return _homePosition; +} + +MissionController *WaypointManager::Settings::missionController() const +{ + return _missionController; +} + +PlanMasterController *WaypointManager::Settings::masterController() const +{ + return _masterController; +} + Vehicle *WaypointManager::Settings::vehicle() const { - return _vehicle; + return _masterController->managerVehicle(); } bool WaypointManager::Settings::isFlyView() const diff --git a/src/Wima/WaypointManager/Settings.h b/src/Wima/WaypointManager/Settings.h index 780ac1c943c5049102d191376f58d5941d262ca3..a9ce345e325146c50f096261643014f5a14497eb 100644 --- a/src/Wima/WaypointManager/Settings.h +++ b/src/Wima/WaypointManager/Settings.h @@ -2,6 +2,8 @@ #include +#include "MissionController.h" +#include "PlanMasterController.h" #include "Vehicle.h" namespace WaypointManager { @@ -11,14 +13,20 @@ class Settings public: Settings(); - void setHomePosition(QGeoCoordinate &c); - void setVehicle(Vehicle *vehicle); + bool valid() const; + + void setHomePosition(const QGeoCoordinate &c); + void setMissionController(MissionController *controller); + void setMasterController(PlanMasterController *controller); void setIsFlyView(bool isFlyView); void setArrivalReturnSpeed(double speed); void setFlightSpeed(double speed); void setAltitude(double altitude); const QGeoCoordinate &homePosition() const; + QGeoCoordinate &homePosition(); + MissionController *missionController() const; + PlanMasterController *masterController() const; Vehicle *vehicle() const; bool isFlyView() const; double arrivalReturnSpeed() const; @@ -26,12 +34,13 @@ public: double altitude() const; private: - QGeoCoordinate _homePosition; - Vehicle *_vehicle; - bool _isFlyView; - double _arrivalReturnSpeed; - double _flightSpeed; - double _altitude; + QGeoCoordinate _homePosition; + MissionController *_missionController; + PlanMasterController *_masterController; + bool _isFlyView; + double _arrivalReturnSpeed; + double _flightSpeed; + double _altitude; }; diff --git a/src/Wima/WaypointManager/Slicer.h b/src/Wima/WaypointManager/Slicer.h index d934f60f82c51693ba123650e7024a882c642a4f..f8f09f97bff71f8606420c50c692ba3d326e2e4e 100644 --- a/src/Wima/WaypointManager/Slicer.h +++ b/src/Wima/WaypointManager/Slicer.h @@ -5,7 +5,7 @@ #include "Utils.h" -//! @brief Base class for all waypoint managers. +//! @brief Helper class for slicing containers. class Slicer { public: @@ -67,14 +67,13 @@ private: template void Slicer::update(const Container1 &source, Container2 &slice){ - if ( !_idxValid) - _updateIdx(source.size()); - + _updateIdx(source.size()); WaypointManager::Utils::extract(source, slice, _idxStart, _idxEnd); } template void Slicer::next(const Container1 &source, Container2 &slice){ + _updateIdx(source.size()); setStartIndex(_idxNext); update(source, slice); } @@ -82,6 +81,7 @@ void Slicer::next(const Container1 &source, Container2 &slice){ template void Slicer::previous(const Container1 &source, Container2 &slice){ + _updateIdx(source.size()); setStartIndex(_idxPrevious); update(source, slice); } diff --git a/src/Wima/WaypointManager/Utils.cpp b/src/Wima/WaypointManager/Utils.cpp index 649cec9f5b1381d3700b1d174d8283411e39a1c5..39a17f1bd46f75ceba342b91e66187b5622bf4b5 100644 --- a/src/Wima/WaypointManager/Utils.cpp +++ b/src/Wima/WaypointManager/Utils.cpp @@ -48,7 +48,7 @@ bool WaypointManager::Utils::insertMissionItem(const QGeoCoordinate &coordinate, double altitude; int altitudeMode; - if (detail::previousAltitude(list, --index, altitude, altitudeMode)) { + if (detail::previousAltitude(list, index-1, altitude, altitudeMode)) { newItem->altitude()->setRawValue(altitude); newItem->setAltitudeMode( static_cast( @@ -153,10 +153,12 @@ bool WaypointManager::Utils::detail::updateHirarchy(QmlObjectListModel &list) bool WaypointManager::Utils::detail::updateHomePosition(QmlObjectListModel &list) { MissionSettingsItem *settingsItem = list.value(0); + assert(settingsItem); // list not initialized? - // Set the home position to be a delta from first coordinate + // Set the home position to be a delta from first coordinate. for (int i = 1; i < list.count(); ++i) { VisualMissionItem* item = list.value(i); + assert(item); if (item->specifiesCoordinate() && item->coordinate().isValid()) { QGeoCoordinate c = item->coordinate().atDistanceAndAzimuth(30, 0); diff --git a/src/Wima/WaypointManager/Utils.h b/src/Wima/WaypointManager/Utils.h index 96963aa15b8b9ae8c85287b8e2c33dca29bce6b8..afba6a9eb9fc6c01acb188336b307142ad050652 100644 --- a/src/Wima/WaypointManager/Utils.h +++ b/src/Wima/WaypointManager/Utils.h @@ -86,7 +86,7 @@ bool extract(const ContainerType &source, if ( !extract(source, destination, startIndex, - std::size_t(source.size()-1)) /*recursion*/) + std::size_t(long(source.size())-1)) /*recursion*/) return false; if ( !extract(source, destination, diff --git a/src/Wima/WimaController.cc b/src/Wima/WimaController.cc index d958dcd0b1cf94ef6db7bb5ba85527f60d53836a..dd057a1d3d00a7d20697f88e8387182294b48388 100644 --- a/src/Wima/WimaController.cc +++ b/src/Wima/WimaController.cc @@ -30,7 +30,6 @@ const char* WimaController::showCurrentMissionItemsName = "ShowCurrentMissionIte const char* WimaController::flightSpeedName = "FlightSpeed"; const char* WimaController::arrivalReturnSpeedName = "ArrivalReturnSpeed"; const char* WimaController::altitudeName = "Altitude"; -const char* WimaController::reverseName = "Reverse"; const char* WimaController::snakeTileWidthName = "SnakeTileWidth"; const char* WimaController::snakeTileHeightName = "SnakeTileHeight"; const char* WimaController::snakeMinTileAreaName = "SnakeMinTileArea"; @@ -43,10 +42,10 @@ using namespace snake_geometry; WimaController::WimaController(QObject *parent) : QObject (parent) , _container (nullptr) - , _joinedArea (this) - , _measurementArea (this) - , _serviceArea (this) - , _corridor (this) + , _joinedArea () + , _measurementArea () + , _serviceArea () + , _corridor () , _localPlanDataValid (false) , _metaDataMap (FactMetaData::createMapFromJsonFile(QStringLiteral(":/json/WimaController.SettingsGroup.json"), this)) , _enableWimaController (settingsGroup, _metaDataMap[enableWimaControllerName]) @@ -58,9 +57,11 @@ WimaController::WimaController(QObject *parent) , _flightSpeed (settingsGroup, _metaDataMap[flightSpeedName]) , _arrivalReturnSpeed (settingsGroup, _metaDataMap[arrivalReturnSpeedName]) , _altitude (settingsGroup, _metaDataMap[altitudeName]) - , _reverse (settingsGroup, _metaDataMap[reverseName]) - , _endWaypointIndex (0) - , _startWaypointIndex (0) + , _areaInterface(&_measurementArea, &_serviceArea, &_corridor, &_joinedArea) + , _managerSettings() + , _defaultManager(_managerSettings, _areaInterface) + , _snakeManager(_managerSettings, _areaInterface) + , _currentManager(_defaultManager) , _uploadOverrideRequired (false) , _measurementPathLength (-1) , _arrivalPathLength (-1) @@ -82,15 +83,19 @@ WimaController::WimaController(QObject *parent) , _snakeMinTransectLength (settingsGroup, _metaDataMap[snakeMinTransectLengthName]) , _pRosBridge (new ROSBridge::ROSBridge()) { + // Set up facts. _showAllMissionItems.setRawValue(true); _showCurrentMissionItems.setRawValue(true); - connect(&_overlapWaypoints, &Fact::rawValueChanged, this, &WimaController::_updateNextWaypoint); - connect(&_maxWaypointsPerPhase, &Fact::rawValueChanged, this, &WimaController::_recalcCurrentPhase); + connect(&_overlapWaypoints, &Fact::rawValueChanged, this, &WimaController::_updateOverlap); + connect(&_maxWaypointsPerPhase, &Fact::rawValueChanged, this, &WimaController::_updateMaxWaypoints); connect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); connect(&_flightSpeed, &Fact::rawValueChanged, this, &WimaController::_updateflightSpeed); connect(&_arrivalReturnSpeed, &Fact::rawValueChanged, this, &WimaController::_updateArrivalReturnSpeed); connect(&_altitude, &Fact::rawValueChanged, this, &WimaController::_updateAltitude); - connect(&_reverse, &Fact::rawValueChanged, this, &WimaController::_reverseChangedHandler); + + _defaultManager.setOverlap(_overlapWaypoints.rawValue().toUInt()); + _defaultManager.setN(_maxWaypointsPerPhase.rawValue().toUInt()); + _defaultManager.setStartIndex(_nextPhaseStartWaypointIndex.rawValue().toUInt()); // setup low battery handling connect(&_eventTimer, &QTimer::timeout, this, &WimaController::_eventTimerHandler); @@ -120,15 +125,25 @@ MissionController *WimaController::missionController() { } QmlObjectListModel *WimaController::visualItems() { - return &_visualItems; + return &_areas; +} + +QmlObjectListModel *WimaController::missionItems() { + return const_cast(&_currentManager.missionItems()); +} + +QmlObjectListModel *WimaController::currentMissionItems() { + return const_cast(&_currentManager.currentMissionItems()); +} + +QVariantList WimaController::waypointPath() +{ + return const_cast(_currentManager.waypointsVariant()); } -QVariantList WimaController::waypointPath() const +QVariantList WimaController::currentWaypointPath() { - QVariantList list; - for ( auto wp : _waypoints) - list.append(QVariant::fromValue(wp)); - return list; + return const_cast(_currentManager.currentWaypointsVariant()); } //QStringList WimaController::loadNameFilters() const @@ -181,12 +196,14 @@ bool WimaController::snakeCalcInProgress() const void WimaController::setMasterController(PlanMasterController *masterC) { _masterController = masterC; + _managerSettings.setMasterController(masterC); emit masterControllerChanged(); } void WimaController::setMissionController(MissionController *missionC) { _missionController = missionC; + _managerSettings.setMissionController(missionC); emit missionControllerChanged(); } @@ -225,41 +242,34 @@ void WimaController::nextPhase() } void WimaController::previousPhase() -{ - bool reverseBool = _reverse.rawValue().toBool(); - if (!reverseBool){ - int startIndex = _nextPhaseStartWaypointIndex.rawValue().toInt(); - if (startIndex > 0) { - _nextPhaseStartWaypointIndex.setRawValue(1+std::max(_startWaypointIndex - - _maxWaypointsPerPhase.rawValue().toInt() - + _overlapWaypoints.rawValue().toInt(), 0)); - } - } - else { - int startIndex = _nextPhaseStartWaypointIndex.rawValue().toInt(); - if (startIndex <= _missionItems.count()) { - _nextPhaseStartWaypointIndex.setRawValue(1+std::min(_startWaypointIndex - + _maxWaypointsPerPhase.rawValue().toInt() - - _overlapWaypoints.rawValue().toInt(), _missionItems.count()-1)); - } +{ + if ( !_currentManager.previous() ) { + assert(false); } + + emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); } void WimaController::resetPhase() { - bool reverseBool = _reverse.rawValue().toBool(); - if (!reverseBool) { - _nextPhaseStartWaypointIndex.setRawValue(int(1)); - } - else { - _nextPhaseStartWaypointIndex.setRawValue(_missionItems.count()); + if ( !_currentManager.reset() ) { + assert(false); } + + emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); } bool WimaController::uploadToVehicle() { + auto ¤tMissionItems = _defaultManager.currentMissionItems(); if ( !_serviceArea.containsCoordinate(_masterController->managerVehicle()->coordinate()) - && _currentMissionItems.count() > 0) { + && currentMissionItems.count() > 0) { setUploadOverrideRequired(true); return false; } @@ -269,8 +279,9 @@ bool WimaController::uploadToVehicle() bool WimaController::forceUploadToVehicle() { + auto ¤tMissionItems = _defaultManager.currentMissionItems(); setUploadOverrideRequired(false); - if (_currentMissionItems.count() < 1) + if (currentMissionItems.count() < 1) return false; _missionController->removeAll(); @@ -278,30 +289,16 @@ bool WimaController::forceUploadToVehicle() QmlObjectListModel* visuals = _missionController->visualItems(); MissionSettingsItem* settingsItem = visuals->value(0); if (settingsItem == nullptr) { + assert(false); qWarning("WimaController::updateCurrentMissionItems(): nullptr"); return false; } - settingsItem->setCoordinate(_takeoffLandPostion); + settingsItem->setCoordinate(_managerSettings.homePosition()); - // copy mission items from _currentMissionItems to _missionController - for (int i = 0; i < _currentMissionItems.count(); i++){ - SimpleMissionItem *item = _currentMissionItems.value(i); + // Copy mission items to _missionController. + for (int i = 0; i < currentMissionItems.count(); i++){ + auto *item = currentMissionItems.value(i); _missionController->insertSimpleMissionItem(*item, visuals->count()); - if (item->command() == MAV_CMD_DO_CHANGE_SPEED) { - } - } - - for (int i = 0; i < _missionController->visualItems()->count(); i++){ - SimpleMissionItem *item = _missionController->visualItems()->value(i); - if (item == nullptr) - continue; - if (item->command() == MAV_CMD_DO_CHANGE_SPEED) { - } - } - for (int i = 0; i < _missionController->visualItems()->count(); i++){ - SimpleMissionItem *item = _missionController->visualItems()->value(i); - if (item == nullptr) - continue; } _masterController->sendToVehicle(); @@ -329,12 +326,12 @@ bool WimaController::checkSmartRTLPreCondition() bool WimaController::calcReturnPath() { QString errorString; - bool retValue = _calcReturnPath(errorString); - if (retValue == false) { - qgcApp()->showMessage(errorString); - return false; - } - return true; +// bool retValue = _calcReturnPath(errorString); +// if (retValue == false) { +// qgcApp()->showMessage(errorString); +// return false; +// } +// return true; } void WimaController::executeSmartRTL() @@ -408,11 +405,8 @@ bool WimaController::_fetchContainerData() // fetch only if valid, return true on success // reset visual items - _visualItems.clear(); - _missionItems.clearAndDeleteContents(); - _currentMissionItems.clearAndDeleteContents(); - _waypoints.clear(); - _currentWaypointPath.clear(); + _areas.clear(); + _defaultManager.clear(); _snakeTiles.polygons().clear(); _snakeTilesLocal.polygons().clear(); _snakeTileCenterPoints.clear(); @@ -420,6 +414,7 @@ bool WimaController::_fetchContainerData() emit visualItemsChanged(); emit missionItemsChanged(); emit currentMissionItemsChanged(); + emit waypointPathChanged(); emit currentWaypointPathChanged(); emit snakeTilesChanged(); emit snakeTileCenterPointsChanged(); @@ -428,6 +423,7 @@ bool WimaController::_fetchContainerData() if (_container == nullptr) { qWarning("WimaController::fetchContainerData(): No container assigned!"); + assert(false); return false; } @@ -437,14 +433,14 @@ bool WimaController::_fetchContainerData() QList areaList = planData.areaList(); int areaCounter = 0; - int numAreas = 4; // extract only numAreas Areas, if there are more they are invalid and ignored + const int numAreas = 4; // extract only numAreas Areas, if there are more they are invalid and ignored for (int i = 0; i < areaList.size(); i++) { const WimaAreaData *areaData = areaList[i]; if (areaData->type() == WimaServiceAreaData::typeString) { // is it a service area? _serviceArea = *qobject_cast(areaData); areaCounter++; - _visualItems.append(&_serviceArea); + _areas.append(&_serviceArea); continue; } @@ -452,7 +448,7 @@ bool WimaController::_fetchContainerData() if (areaData->type() == WimaMeasurementAreaData::typeString) { // is it a measurement area? _measurementArea = *qobject_cast(areaData); areaCounter++; - _visualItems.append(&_measurementArea); + _areas.append(&_measurementArea); continue; } @@ -468,7 +464,7 @@ bool WimaController::_fetchContainerData() if (areaData->type() == WimaJoinedAreaData::typeString) { // is it a corridor? _joinedArea = *qobject_cast(areaData); areaCounter++; - _visualItems.append(&_joinedArea); + _areas.append(&_joinedArea); continue; } @@ -477,45 +473,29 @@ bool WimaController::_fetchContainerData() break; } - // extract mission items - QList tempMissionItems = planData.missionItems(); - if (tempMissionItems.size() < 1) + if (areaCounter != numAreas) { + assert(false); return false; - - // create mission items - _missionController->removeAll(); - QmlObjectListModel* missionControllerVisualItems = _missionController->visualItems(); - - // create SimpleMissionItem by using _missionController - for ( int i = 0; i < tempMissionItems.size(); i++) { - _missionController->insertSimpleMissionItem(tempMissionItems[i], missionControllerVisualItems->count()); } - // copy mission items from _missionController to _missionItems - for ( int i = 1; i < missionControllerVisualItems->count(); i++) { - SimpleMissionItem *visualItem = qobject_cast((*missionControllerVisualItems)[i]); - if (visualItem == nullptr) { - qWarning("WimaController::fetchContainerData(): Nullptr at SimpleMissionItem!"); - return false; - } - SimpleMissionItem *visualItemCopy = new SimpleMissionItem(*visualItem, true, this); - _missionItems.append(visualItemCopy); - } - if (areaCounter != numAreas) - return false; - if (!_setTakeoffLandPosition()) + // extract mission items + QList tempMissionItems = planData.missionItems(); + if (tempMissionItems.size() < 1) { + assert(false); return false; + } - _updateWaypointPath(); + for (auto item : tempMissionItems) + _defaultManager.push_back(item.coordinate()); - // set _nextPhaseStartWaypointIndex to 1 - disconnect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - bool reverse = _reverse.rawValue().toBool(); - _nextPhaseStartWaypointIndex.setRawValue(reverse? _missionItems.count() : int(1)); - connect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); + _managerSettings.setHomePosition( QGeoCoordinate(_serviceArea.center().latitude(), + _serviceArea.center().longitude(), + 0) ); - if(!_calcNextPhase()) + if( !_defaultManager.update() ){ + assert(false); return false; + } // Initialize _scenario. Area mArea; @@ -545,6 +525,7 @@ bool WimaController::_fetchContainerData() // Check if scenario is defined. if ( !_verifyScenarioDefinedWithErrorMessage() ) + assert(false); return false; { @@ -585,8 +566,11 @@ bool WimaController::_fetchContainerData() } + emit visualItemsChanged(); emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); emit snakeTilesChanged(); emit snakeTileCenterPointsChanged(); @@ -596,325 +580,102 @@ bool WimaController::_fetchContainerData() bool WimaController::_calcNextPhase() { - if (_missionItems.count() < 1) { - _startWaypointIndex = 0; - _endWaypointIndex = 0; - return false; - } - - _currentMissionItems.clearAndDeleteContents(); - - bool reverse = _reverse.rawValue().toBool(); // Reverses the phase direction. Phases go from high to low waypoint numbers, if true. - int startIndex = _nextPhaseStartWaypointIndex.rawValue().toInt()-1; - if (!reverse) { - if (startIndex > _missionItems.count()-1) - return false; - } - else { - if (startIndex < 0) - return false; - } - _startWaypointIndex = startIndex; - - int maxWaypointsPerPhase = _maxWaypointsPerPhase.rawValue().toInt(); - // determine end waypoint index - bool lastMissionPhaseReached = false; - if (!reverse) { - _endWaypointIndex = std::min(_startWaypointIndex + maxWaypointsPerPhase - 1, _missionItems.count()-1); - if (_endWaypointIndex == _missionItems.count() - 1) - lastMissionPhaseReached = true; - } - else { - _endWaypointIndex = std::max(_startWaypointIndex - maxWaypointsPerPhase + 1, 0); - if (_endWaypointIndex == 0) - lastMissionPhaseReached = true; - } - - - // extract waypoints - QVector CSWpList; // list with potential waypoints (from _missionItems), for _currentMissionItems + bool value; + _currentManager.setStartIndex(_nextPhaseStartWaypointIndex.rawValue().toUInt(&value)); + Q_ASSERT(value); + (void)value; - if (!reverse) { - if (!getCoordinates(_missionItems, CSWpList, _startWaypointIndex, _endWaypointIndex)) { - qWarning("WimaController::calcNextPhase(): error on waypoint extraction."); - return false; - } - } else { - if (!getCoordinates(_missionItems, CSWpList, _endWaypointIndex, _startWaypointIndex)) { - qWarning("WimaController::calcNextPhase(): error on waypoint extraction."); - return false; - } - - // reverse path - QVector reversePath; - for (QGeoCoordinate c : CSWpList) - reversePath.prepend(c); - CSWpList.clear(); - CSWpList.append(reversePath); - } - - - // calculate phase length - _measurementPathLength = 0; - for (int i = 0; i < CSWpList.size()-1; ++i) - _measurementPathLength += CSWpList[i].distanceTo(CSWpList[i+1]); - - - // set start waypoint index for next phase - if (!lastMissionPhaseReached) { - disconnect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - if (!reverse) { - int untruncated = std::max(_endWaypointIndex + 1 - _overlapWaypoints.rawValue().toInt(), 0); - int truncated = std::min(untruncated , _missionItems.count()-1); - _nextPhaseStartWaypointIndex.setRawValue(truncated + 1); - } - else { - int untruncated = std::min(_endWaypointIndex - 1 + _overlapWaypoints.rawValue().toInt(), _missionItems.count()-1); - int truncated = std::max(untruncated , 0); - _nextPhaseStartWaypointIndex.setRawValue(truncated + 1); - } - connect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - } - - // calculate path from home to first waypoint - QVector arrivalPath; - if (!_takeoffLandPostion.isValid()){ - qWarning("WimaController::calcNextPhase(): _takeoffLandPostion not valid."); - return false; - } - if ( !calcShortestPath(_takeoffLandPostion, CSWpList.first(), arrivalPath) ) { - qWarning("WimaController::calcNextPhase(): Not able to calc path from home to first waypoint."); - return false; - } - - // calculate arrival path length - _arrivalPathLength = 0; - for (int i = 0; i < arrivalPath.size()-1; ++i) - _arrivalPathLength += arrivalPath[i].distanceTo(arrivalPath[i+1]); - - arrivalPath.removeFirst(); - - // calculate path from last waypoint to home - QVector returnPath; - if ( !calcShortestPath(CSWpList.last(), _takeoffLandPostion, returnPath) ) { - qWarning("WimaController::calcNextPhase(): Not able to calc path from home to last waypoint."); - return false; - } - - // calculate arrival path length - _returnPathLength = 0; - for (int i = 0; i < returnPath.size()-1; ++i) - _returnPathLength += returnPath[i].distanceTo(returnPath[i+1]); - - returnPath.removeFirst(); - returnPath.removeLast(); - - - - // create Mission Items - _missionController->removeAll(); - QmlObjectListModel* missionControllerVisuals = _missionController->visualItems(); - - // set homeposition of settingsItem - MissionSettingsItem* settingsItem = missionControllerVisuals->value(0); - if (settingsItem == nullptr) { - qWarning("WimaController::calcNextPhase(): nullptr"); - return false; - } - settingsItem->setCoordinate(_takeoffLandPostion); - - // set takeoff position for first mission item (bug) - missionController()->insertSimpleMissionItem(_takeoffLandPostion, 1); - SimpleMissionItem *takeoffItem = missionControllerVisuals->value(1); - if (takeoffItem == nullptr) { - qWarning("WimaController::calcNextPhase(): nullptr"); - return false; - } - takeoffItem->setCoordinate(_takeoffLandPostion); - - // create change speed item, after take off - _missionController->insertSimpleMissionItem(_takeoffLandPostion, 2); - SimpleMissionItem *speedItem = missionControllerVisuals->value(2); - if (speedItem == nullptr) { - qWarning("WimaController::calcNextPhase(): nullptr"); + if ( !_currentManager.next() ) { + assert(false); return false; } - speedItem->setCommand(MAV_CMD_DO_CHANGE_SPEED);// set coordinate must be after setCommand (setCommand sets coordinate to zero) - speedItem->setCoordinate(_takeoffLandPostion); - speedItem->missionItem().setParam2(_arrivalReturnSpeed.rawValue().toDouble()); - - // insert arrival path - for (auto coordinate : arrivalPath) - _missionController->insertSimpleMissionItem(coordinate, missionControllerVisuals->count()); - - // create change speed item, after arrival path - int index = missionControllerVisuals->count(); - _missionController->insertSimpleMissionItem(CSWpList.first(), index); - speedItem = missionControllerVisuals->value(index); - if (speedItem == nullptr) { - qWarning("WimaController::calcNextPhase(): nullptr"); - return false; - } - speedItem->setCommand(MAV_CMD_DO_CHANGE_SPEED); // set coordinate must be after setCommand (setCommand sets coordinate to zero) - speedItem->setCoordinate(CSWpList.first()); - speedItem->missionItem().setParam2(_flightSpeed.rawValue().toDouble()); - - // insert Circular Survey coordinates - for (auto coordinate : CSWpList) - _missionController->insertSimpleMissionItem(coordinate, missionControllerVisuals->count()); - - // create change speed item, after circular survey - index = missionControllerVisuals->count(); - _missionController->insertSimpleMissionItem(CSWpList.last(), index); - speedItem = missionControllerVisuals->value(index); - if (speedItem == nullptr) { - qWarning("WimaController::calcNextPhase(): nullptr"); - return false; - } - speedItem->setCommand(MAV_CMD_DO_CHANGE_SPEED); // set coordinate must be after setCommand (setCommand sets coordinate to zero) - speedItem->setCoordinate(CSWpList.last()); - speedItem->missionItem().setParam2(_arrivalReturnSpeed.rawValue().toDouble()); - - // insert return path coordinates - for (auto coordinate : returnPath) - _missionController->insertSimpleMissionItem(coordinate, missionControllerVisuals->count()); - - // set land command for last mission item - index = missionControllerVisuals->count(); - _missionController->insertSimpleMissionItem(_takeoffLandPostion, index); - SimpleMissionItem *landItem = missionControllerVisuals->value(index); - if (landItem == nullptr) { - qWarning("WimaController::calcNextPhase(): nullptr"); - return false; - } - _missionController->setLandCommand(*landItem); - - // copy to _currentMissionItems - for ( int i = 1; i < missionControllerVisuals->count(); i++) { - SimpleMissionItem *visualItem = missionControllerVisuals->value(i); - if (visualItem == nullptr) { - qWarning("WimaController::calcNextPhase(): Nullptr at SimpleMissionItem!"); - _currentMissionItems.clear(); - return false; - } - - SimpleMissionItem *visualItemCopy = new SimpleMissionItem(*visualItem, true, this); - _currentMissionItems.append(visualItemCopy); - } - double dist = 0; - double time = 0; - if (!_missionController->distanceTimeToMissionEnd(dist, time, 1, false)) - qWarning("WimaController::calcNextPhase: distanceTimeToMissionEnd returned false!"); - _setPhaseDistance(dist); - _setPhaseDuration(time); - _missionController->removeAll(); // remove items from _missionController, will be added on upload - _updateAltitude(); - - _updateCurrentPath(); + emit missionItemsChanged(); emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); return true; } -void WimaController::_updateWaypointPath() +void WimaController::_recalcCurrentPhase() { - _waypoints.clear(); - getCoordinates(_missionItems, - _waypoints, - 0, - std::size_t( std::max(_missionItems.count()-1,0) ) - ); + if ( !_currentManager.update() ) { + assert(false); + } + emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); emit waypointPathChanged(); } -void WimaController::_updateCurrentPath() + +void WimaController::_updateOverlap() { - _currentWaypointPath.clear(); - getCoordinates(_currentMissionItems, _currentWaypointPath, 0, _currentMissionItems.count()-1); + bool value; + _currentManager.setOverlap(_overlapWaypoints.rawValue().toUInt(&value)); + Q_ASSERT(value); + (void)value; + if ( !_currentManager.update() ) { + assert(false); + } + + emit missionItemsChanged(); + emit currentMissionItemsChanged(); emit currentWaypointPathChanged(); + emit waypointPathChanged(); } -void WimaController::_updateNextWaypoint() +void WimaController::_updateMaxWaypoints() { - if (_endWaypointIndex < _missionItems.count()-2) { - disconnect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - _nextPhaseStartWaypointIndex.setRawValue(1 + std::max(_endWaypointIndex + 1 - _overlapWaypoints.rawValue().toInt(), 0)); - connect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - } -} + bool value; + _currentManager.setN(_maxWaypointsPerPhase.rawValue().toUInt(&value)); + Q_ASSERT(value); + (void)value; -void WimaController::_recalcCurrentPhase() -{ - disconnect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - _nextPhaseStartWaypointIndex.setRawValue(_startWaypointIndex + 1); - connect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - _calcNextPhase(); -} + if ( !_currentManager.update() ) { + assert(false); + } -bool WimaController::_setTakeoffLandPosition() -{ - _takeoffLandPostion.setAltitude(0); - _takeoffLandPostion.setLongitude(_serviceArea.center().longitude()); - _takeoffLandPostion.setLatitude(_serviceArea.center().latitude()); + emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); - return true; } void WimaController::_updateflightSpeed() { - int speedItemCounter = 0; - for (int i = 0; i < _currentMissionItems.count(); i++) { - SimpleMissionItem *item = _currentMissionItems.value(i); - if (item != nullptr && item->command() == MAV_CMD_DO_CHANGE_SPEED) { - speedItemCounter++; - if (speedItemCounter == 2) { - item->missionItem().setParam2(_flightSpeed.rawValue().toDouble()); - } - } - } + _managerSettings.setFlightSpeed(_flightSpeed.rawValue().toDouble()); + _currentManager.update(); - _setPhaseDuration(_phaseDistance/_flightSpeed.rawValue().toDouble() - + (_arrivalPathLength + _returnPathLength) - / _arrivalReturnSpeed.rawValue().toDouble()); - - if (speedItemCounter != 3) - qWarning("WimaController::updateflightSpeed(): internal error."); + emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); } void WimaController::_updateArrivalReturnSpeed() { - int speedItemCounter = 0; - for (int i = 0; i < _currentMissionItems.count(); i++) { - SimpleMissionItem *item = _currentMissionItems.value(i); - if (item != nullptr && item->command() == MAV_CMD_DO_CHANGE_SPEED) { - speedItemCounter++; - if (speedItemCounter != 2) { - item->missionItem().setParam2(_arrivalReturnSpeed.rawValue().toDouble()); - } - } - } - - _setPhaseDuration(_phaseDistance/_flightSpeed.rawValue().toDouble() - + (_arrivalPathLength + _returnPathLength) - / _arrivalReturnSpeed.rawValue().toDouble()); - - if (speedItemCounter != 3) - qWarning("WimaController::updateArrivalReturnSpeed(): internal error."); + _managerSettings.setArrivalReturnSpeed(_arrivalReturnSpeed.rawValue().toDouble()); + _currentManager.update(); + emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); } void WimaController::_updateAltitude() { - for (int i = 0; i < _currentMissionItems.count(); i++) { - SimpleMissionItem *item = _currentMissionItems.value(i); - if (item == nullptr) { - qWarning("WimaController::updateAltitude(): nullptr"); - return; - } - item->altitude()->setRawValue(_altitude.rawValue().toDouble()); - } + _managerSettings.setAltitude(_altitude.rawValue().toDouble()); + _currentManager.update(); + + emit missionItemsChanged(); + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); } void WimaController::_checkBatteryLevel() @@ -986,18 +747,18 @@ void WimaController::_eventTimerHandler() void WimaController::_smartRTLCleanUp(bool flying) { - if ( !flying) { // vehicle has landed - if (_executingSmartRTL) { - _executingSmartRTL = false; - _loadCurrentMissionItemsFromBuffer(); - _setPhaseDistance(_phaseDistanceBuffer); - _setPhaseDuration(_phaseDurationBuffer); - _showAllMissionItems.setRawValue(true); - _missionController->removeAllFromVehicle(); - _missionController->removeAll(); - disconnect(masterController()->managerVehicle(), &Vehicle::flyingChanged, this, &WimaController::_smartRTLCleanUp); - } - } +// if ( !flying) { // vehicle has landed +// if (_executingSmartRTL) { +// _executingSmartRTL = false; +// _loadCurrentMissionItemsFromBuffer(); +// _setPhaseDistance(_phaseDistanceBuffer); +// _setPhaseDuration(_phaseDurationBuffer); +// _showAllMissionItems.setRawValue(true); +// _missionController->removeAllFromVehicle(); +// _missionController->removeAll(); +// disconnect(masterController()->managerVehicle(), &Vehicle::flyingChanged, this, &WimaController::_smartRTLCleanUp); +// } +// } } void WimaController::_enableDisableLowBatteryHandling(QVariant enable) @@ -1009,15 +770,6 @@ void WimaController::_enableDisableLowBatteryHandling(QVariant enable) } } -void WimaController::_reverseChangedHandler() -{ - disconnect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - _nextPhaseStartWaypointIndex.setRawValue(_endWaypointIndex+1); - connect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - - _calcNextPhase(); -} - void WimaController::_setPhaseDistance(double distance) { if (!qFuzzyCompare(distance, _phaseDistance)) { @@ -1056,119 +808,6 @@ bool WimaController::_checkSmartRTLPreCondition(QString &errorString) return true; } -bool WimaController::_calcReturnPath(QString &errorSring) -{ - // it is assumed that checkSmartRTLPreCondition() was called first and true was returned - - - Vehicle *managerVehicle = masterController()->managerVehicle(); - - QGeoCoordinate currentVehiclePosition = managerVehicle->coordinate(); - // check if vehicle inside _joinedArea, this statement is not inside checkSmartRTLPreCondition() because during checkSmartRTLPreCondition() vehicle is not paused yet - if (!_joinedArea.containsCoordinate(currentVehiclePosition)) { - errorSring.append(tr("Vehicle not inside joined area. Action not supported.")); - return false; - } - - // calculate return path - QVector returnPath; - calcShortestPath(currentVehiclePosition, _takeoffLandPostion, returnPath); - // successful? - if (returnPath.isEmpty()) { - errorSring.append(tr("Not able to calculate return path.")); - return false; - } - // qWarning() << "returnPath.size()" << returnPath.size(); - - _saveCurrentMissionItemsToBuffer(); - _phaseDistanceBuffer = _phaseDistance; - _phaseDurationBuffer = _phaseDuration; - - - // create Mission Items - removeFromVehicle(); - QmlObjectListModel* missionControllerVisuals = _missionController->visualItems(); - - // set homeposition of settingsItem - MissionSettingsItem* settingsItem = missionControllerVisuals->value(0); - if (settingsItem == nullptr) { - qWarning("WimaController: nullptr"); - return false; - } - settingsItem->setCoordinate(_takeoffLandPostion); - - // copy from returnPath to _missionController - QGeoCoordinate speedItemCoordinate = returnPath.first(); - for (auto coordinate : returnPath) { - _missionController->insertSimpleMissionItem(coordinate, missionControllerVisuals->count()); - } - //qWarning() << "missionControllerVisuals->count()" << missionControllerVisuals->count(); - - // create speed item - int speedItemIndex = 1; - _missionController->insertSimpleMissionItem(speedItemCoordinate, speedItemIndex); - SimpleMissionItem *speedItem = missionControllerVisuals->value(speedItemIndex); - if (speedItem == nullptr) { - qWarning("WimaController: nullptr"); - return false; - } - speedItem->setCommand(MAV_CMD_DO_CHANGE_SPEED); - speedItem->setCoordinate(speedItemCoordinate); - speedItem->missionItem().setParam2(_arrivalReturnSpeed.rawValue().toDouble()); - - // set second item command to ordinary waypoint (is takeoff) - SimpleMissionItem *secondItem = missionControllerVisuals->value(2); - if (secondItem == nullptr) { - qWarning("WimaController: nullptr"); - return false; - } - secondItem->setCoordinate(speedItemCoordinate); - secondItem->setCommand(MAV_CMD_NAV_WAYPOINT); - - - // set land command for last mission item - SimpleMissionItem *landItem = missionControllerVisuals->value(missionControllerVisuals->count()-1); - if (landItem == nullptr) { - qWarning("WimaController: nullptr"); - return false; - } - _missionController->setLandCommand(*landItem); - - // copy to _currentMissionItems - //qWarning() << "_currentMissionItems.count()" << _currentMissionItems.count(); - for ( int i = 1; i < missionControllerVisuals->count(); i++) { - SimpleMissionItem *visualItem = missionControllerVisuals->value(i); - if (visualItem == nullptr) { - qWarning("WimaController: Nullptr at SimpleMissionItem!"); - _currentMissionItems.clear(); - return false; - } - - SimpleMissionItem *visualItemCopy = new SimpleMissionItem(*visualItem, true, this); - _currentMissionItems.append(visualItemCopy); - } - //qWarning() << "_currentMissionItems.count()" << _currentMissionItems.count(); - - double dist = 0; - double time = 0; - if (!_missionController->distanceTimeToMissionEnd(dist, time, 1, false)) - qWarning("WimaController::calcNextPhase: distanceTimeToMissionEnd returned false!"); - _setPhaseDistance(dist); - _setPhaseDuration(time); - _missionController->removeAll(); // remove items from _missionController, will be added on upload - _updateAltitude(); - - _updateCurrentPath(); - emit currentMissionItemsChanged(); - - - //qWarning() << "_currentMissionItems.count()" << _currentMissionItems.count(); - _showAllMissionItems.setRawValue(false); - managerVehicle->trajectoryPoints()->clear(); - - return true; -} - void WimaController::_setVehicleHasLowBattery(bool batteryLow) { if (_vehicleHasLowBattery != batteryLow) { @@ -1180,36 +819,36 @@ void WimaController::_setVehicleHasLowBattery(bool batteryLow) void WimaController::_initSmartRTL() { - QString errorString; - static int attemptCounter = 0; - attemptCounter++; - - if (_checkSmartRTLPreCondition(errorString) == true) { - _masterController->managerVehicle()->pauseVehicle(); - connect(masterController()->managerVehicle(), &Vehicle::flyingChanged, this, &WimaController::_smartRTLCleanUp); - if (_calcReturnPath(errorString)) { - _executingSmartRTL = true; - attemptCounter = 0; - - switch(_srtlReason) { - case BatteryLow: - emit returnBatteryLowConfirmRequired(); - break; - case UserRequest: - emit returnUserRequestConfirmRequired(); - break; - } - - return; - } - } - if (attemptCounter > SMART_RTL_MAX_ATTEMPTS) { // try 3 times, somtimes vehicle is outside joined area - errorString.append(tr("Smart RTL: No success after maximum number of attempts.")); - qgcApp()->showMessage(errorString); - attemptCounter = 0; - } else { - _smartRTLAttemptTimer.singleShot(SMART_RTL_ATTEMPT_INTERVAL, this, &WimaController::_initSmartRTL); - } +// QString errorString; +// static int attemptCounter = 0; +// attemptCounter++; + +// if (_checkSmartRTLPreCondition(errorString) == true) { +// _masterController->managerVehicle()->pauseVehicle(); +// connect(masterController()->managerVehicle(), &Vehicle::flyingChanged, this, &WimaController::_smartRTLCleanUp); +// if (_calcReturnPath(errorString)) { +// _executingSmartRTL = true; +// attemptCounter = 0; + +// switch(_srtlReason) { +// case BatteryLow: +// emit returnBatteryLowConfirmRequired(); +// break; +// case UserRequest: +// emit returnUserRequestConfirmRequired(); +// break; +// } + +// return; +// } +// } +// if (attemptCounter > SMART_RTL_MAX_ATTEMPTS) { // try 3 times, somtimes vehicle is outside joined area +// errorString.append(tr("Smart RTL: No success after maximum number of attempts.")); +// qgcApp()->showMessage(errorString); +// attemptCounter = 0; +// } else { +// _smartRTLAttemptTimer.singleShot(SMART_RTL_ATTEMPT_INTERVAL, this, &WimaController::_initSmartRTL); +// } } void WimaController::_executeSmartRTL() @@ -1255,7 +894,8 @@ bool WimaController::_verifyScenarioDefinedWithErrorMessage() void WimaController::_snakeStoreWorkerResults() { auto start = std::chrono::high_resolution_clock::now(); - _missionItems.clearAndDeleteContents(); + _snakeManager.clear(); + const WorkerResult_t &r = _snakeWorker.getResult(); _setSnakeCalcInProgress(false); if (!r.success) { @@ -1266,56 +906,20 @@ void WimaController::_snakeStoreWorkerResults() // create Mission items from r.waypoints long n = r.waypoints.size() - r.returnPathIdx.size() - r.arrivalPathIdx.size() + 2; assert(n >= 1); - QVector missionItems; - missionItems.reserve(int(n)); - - // Remove all items from mission controller. - _missionController->removeAll(); - QmlObjectListModel* missionControllerVisualItems = _missionController->visualItems(); // Create QVector containing all waypoints; unsigned long startIdx = r.arrivalPathIdx.last(); unsigned long endIdx = r.returnPathIdx.first(); - QVector waypoints; for (unsigned long i = startIdx; i <= endIdx; ++i) { - QGeoCoordinate wp{r.waypoints[int(i)].value()}; - waypoints.append(wp); - } - - // create SimpleMissionItem by using _missionController - long insertIdx = missionControllerVisualItems->count(); - for (auto wp : waypoints) - _missionController->insertSimpleMissionItem(wp, insertIdx++); - SimpleMissionItem *takeOffItem = missionControllerVisualItems->value(1); - if (takeOffItem == nullptr) { - qWarning("WimaController::_snakeStoreWorkerResults(): Nullptr at SimpleMissionItem!"); - return; - } - takeOffItem->setCommand(MAV_CMD_NAV_WAYPOINT); - takeOffItem->setCoordinate(waypoints[0]); - - // copy mission items from _missionController to _missionItems - for ( int i = 1; i < missionControllerVisualItems->count(); i++) { - SimpleMissionItem *visualItem = qobject_cast((*missionControllerVisualItems)[i]); - if (visualItem == nullptr) { - qWarning("WimaController::_snakeStoreWorkerResults(): Nullptr at SimpleMissionItem!"); - return; - } - SimpleMissionItem *visualItemCopy = new SimpleMissionItem(*visualItem, true, this); - _missionItems.append(visualItemCopy); + _snakeManager.push_back(r.waypoints[int(i)].value()); } - _updateWaypointPath(); - - // set _nextPhaseStartWaypointIndex to 1 - disconnect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); - bool reverse = _reverse.rawValue().toBool(); - _nextPhaseStartWaypointIndex.setRawValue(reverse? _missionItems.count() : int(1)); - connect(&_nextPhaseStartWaypointIndex, &Fact::rawValueChanged, this, &WimaController::_calcNextPhase); + _snakeManager.update(); - _calcNextPhase(); emit missionItemsChanged(); - + emit currentMissionItemsChanged(); + emit currentWaypointPathChanged(); + emit waypointPathChanged(); auto end = std::chrono::high_resolution_clock::now(); double duration = std::chrono::duration_cast(end-start).count(); @@ -1352,25 +956,6 @@ void WimaController::_initStartSnakeWorker() _snakeWorker.start(); } -void WimaController::_loadCurrentMissionItemsFromBuffer() -{ - _currentMissionItems.clear(); - int numItems = _missionItemsBuffer.count(); - for (int i = 0; i < numItems; i++) - _currentMissionItems.append(_missionItemsBuffer.removeAt(0)); - - _updateCurrentPath(); -} - - -void WimaController::_saveCurrentMissionItemsToBuffer() -{ - _missionItemsBuffer.clear(); - int numCurrentMissionItems = _currentMissionItems.count(); - for (int i = 0; i < numCurrentMissionItems; i++) - _missionItemsBuffer.append(_currentMissionItems.removeAt(0)); -} - void WimaController::_progressFromJson(JsonDocUPtr pDoc, QNemoProgress &progress) { diff --git a/src/Wima/WimaController.h b/src/Wima/WimaController.h index 791a22e8b9fa0bbc0da0427a3ff4b4f2db237532..c1339e51817bc099c46365d3ee1ccce6956c1262 100644 --- a/src/Wima/WimaController.h +++ b/src/Wima/WimaController.h @@ -35,6 +35,8 @@ #include "ros_bridge/include/ROSBridge.h" +#include "WaypointManager/DefaultManager.h" + #define CHECK_BATTERY_INTERVAL 1000 // ms #define SMART_RTL_MAX_ATTEMPTS 3 // times #define SMART_RTL_ATTEMPT_INTERVAL 200 // ms @@ -136,10 +138,6 @@ public: READ arrivalReturnSpeed CONSTANT ) - Q_PROPERTY(Fact* reverse - READ reverse - CONSTANT - ) Q_PROPERTY(bool uploadOverrideRequired READ uploadOverrideRequired WRITE setUploadOverrideRequired @@ -216,10 +214,10 @@ public: // QString fileExtension (void) const { return wimaFileExtension; } QGCMapPolygon joinedArea (void) const; WimaDataContainer* dataContainer (void) { return _container; } - QmlObjectListModel* missionItems (void) { return &_missionItems; } - QmlObjectListModel* currentMissionItems (void) { return &_currentMissionItems; } - QVariantList waypointPath (void) const; - QVariantList currentWaypointPath (void) { return _currentWaypointPath; } + QmlObjectListModel* missionItems (void); + QmlObjectListModel* currentMissionItems (void); + QVariantList waypointPath (void); + QVariantList currentWaypointPath (void); Fact* enableWimaController (void) { return &_enableWimaController; } Fact* overlapWaypoints (void) { return &_overlapWaypoints; } Fact* maxWaypointsPerPhase (void) { return &_maxWaypointsPerPhase; } @@ -229,7 +227,6 @@ public: Fact* flightSpeed (void) { return &_flightSpeed; } Fact* arrivalReturnSpeed (void) { return &_arrivalReturnSpeed; } Fact* altitude (void) { return &_altitude; } - Fact* reverse (void) { return &_reverse; } Fact* enableSnake (void) { return &_enableSnake; } Fact* snakeTileWidth (void) { return &_snakeTileWidth;} @@ -291,7 +288,6 @@ public: static const char* flightSpeedName; static const char* arrivalReturnSpeedName; static const char* altitudeName; - static const char* reverseName; static const char* snakeTileWidthName; static const char* snakeTileHeightName; static const char* snakeMinTileAreaName; @@ -330,11 +326,13 @@ private: private slots: bool _fetchContainerData(); bool _calcNextPhase(void); - void _updateWaypointPath (void); - void _updateCurrentPath (void); - void _updateNextWaypoint (void); + //void _updateWaypointPath (void); + //void _updateCurrentPath (void); + //void _updateNextWaypoint (void); void _recalcCurrentPhase (void); - bool _setTakeoffLandPosition (void); + //bool _setTakeoffLandPosition (void); + void _updateOverlap (void); + void _updateMaxWaypoints (void); void _updateflightSpeed (void); void _updateArrivalReturnSpeed (void); void _updateAltitude (void); @@ -342,7 +340,6 @@ private slots: void _eventTimerHandler (void); void _smartRTLCleanUp (bool flying); // cleans up after successfull smart RTL void _enableDisableLowBatteryHandling (QVariant enable); - void _reverseChangedHandler (); void _initSmartRTL (); void _executeSmartRTL (); void _setSnakeConnectionStatus (SnakeConnectionStatus status); @@ -369,19 +366,27 @@ private: MissionController *_missionController; // QString _currentFile; // file for saveing WimaDataContainer *_container; // container for data exchange with WimaController - QmlObjectListModel _visualItems; // contains all visible areas + QmlObjectListModel _areas; // contains all visible areas WimaJoinedAreaData _joinedArea; // joined area fromed by opArea, serArea, _corridor WimaMeasurementAreaData _measurementArea; // measurement area WimaServiceAreaData _serviceArea; // area for supplying WimaCorridorData _corridor; // corridor connecting opArea and serArea bool _localPlanDataValid; - QmlObjectListModel _missionItems; // all mission itmes (Mission Items) generaded by wimaPlaner, displayed in flightView - QmlObjectListModel _currentMissionItems; // contains the current mission items, which are a sub set of _missionItems, - // _currentMissionItems contains a number of mission items which can be worked off with a single battery chrage - QmlObjectListModel _missionItemsBuffer; // Buffer to store mission items, e.g. for storing _currentMissionItems when smartRTL() is invoked - QVector _waypoints; // path connecting the items in _missionItems - QVariantList _currentWaypointPath; // path connecting the items in _currentMissionItems - QGeoCoordinate _takeoffLandPostion; + + + WaypointManager::AreaInterface _areaInterface; + WaypointManager::Settings _managerSettings; + WaypointManager::DefaultManager _defaultManager; + WaypointManager::DefaultManager _snakeManager; + WaypointManager::ManagerBase &_currentManager; + +// QmlObjectListModel _missionItems; // all mission itmes (Mission Items) generaded by wimaPlaner, displayed in flightView +// QmlObjectListModel _currentMissionItems; // contains the current mission items, which are a sub set of _missionItems, +// // _currentMissionItems contains a number of mission items which can be worked off with a single battery chrage +// QmlObjectListModel _missionItemsBuffer; // Buffer to store mission items, e.g. for storing _currentMissionItems when smartRTL() is invoked +// QVector _waypoints; // path connecting the items in _missionItems +// QVariantList _currentWaypointPath; // path connecting the items in _currentMissionItems +// QGeoCoordinate _takeoffLandPostion; QMap _metaDataMap; @@ -395,13 +400,12 @@ private: SettingsFact _flightSpeed; // mission flight speed SettingsFact _arrivalReturnSpeed; // arrival and return path speed SettingsFact _altitude; // mission altitude - SettingsFact _reverse; // Reverses the phase direction. Phases go from high to low waypoint numbers, if true. SettingsFact _enableSnake; // Enable Snake (see snake.h) - int _endWaypointIndex; // index of the mission item stored in _missionItems defining the last element - // (which is not part of the return path) of _currentMissionItem - int _startWaypointIndex; // index of the mission item stored in _missionItems defining the first element - // (which is not part of the arrival path) of _currentMissionItem +// int _endWaypointIndex; // index of the mission item stored in _missionItems defining the last element +// // (which is not part of the return path) of _currentMissionItem +// int _startWaypointIndex; // index of the mission item stored in _missionItems defining the first element +// // (which is not part of the arrival path) of _currentMissionItem bool _uploadOverrideRequired; // Is set to true if uploadToVehicle() did not suceed because the vehicle is not inside the service area. // The user can override the upload lock with a slider, this will reset this variable to false. double _measurementPathLength; // the lenght of the phase in meters