mirror of
https://github.com/nasa/trick.git
synced 2024-12-25 07:41:08 +00:00
aed99ab1fd
* Set up a waypoint system that reads waypoints from an input file. On branch aircraftUpdate Changes to be committed: new file: trick_sims/SIM_aircraft/Modified_data/default.waypoints modified: trick_sims/SIM_aircraft/RUN_test/input.py modified: trick_sims/SIM_aircraft/models/Aircraft/include/Aircraft.hh modified: trick_sims/SIM_aircraft/models/Aircraft/src/Aircraft.cpp modified: trick_sims/SIM_aircraft/models/graphics/src/trick/AircraftDisplay.java * Fixed the Segmentation Fault and completed the waypoint configuration. On branch aircraftUpdate Changes to be committed: modified: trick_sims/SIM_aircraft/RUN_test/input.py modified: trick_sims/SIM_aircraft/models/Aircraft/include/Aircraft.hh modified: trick_sims/SIM_aircraft/models/Aircraft/src/Aircraft.cpp * Created README.md to document recent changes * Adding in ability to set icons for waypoints. On branch aircraftUpdate_WaypointIcons Changes to be committed: modified: trick_sims/SIM_aircraft/Modified_data/default.waypoints new file: trick_sims/SIM_aircraft/images/CompassRose.png new file: trick_sims/SIM_aircraft/images/Figure1.png new file: trick_sims/SIM_aircraft/images/Figure2.png new file: trick_sims/SIM_aircraft/images/cheese_64x64.png new file: trick_sims/SIM_aircraft/images/mouse_128x128.png new file: trick_sims/SIM_aircraft/images/strawberry_64x64.png new file: trick_sims/SIM_aircraft/images/twoWheelRover.png new file: trick_sims/SIM_aircraft/images/wp0.png new file: trick_sims/SIM_aircraft/images/wp1.png new file: trick_sims/SIM_aircraft/images/wp10.png new file: trick_sims/SIM_aircraft/images/wp11.png new file: trick_sims/SIM_aircraft/images/wp2.png new file: trick_sims/SIM_aircraft/images/wp3.png new file: trick_sims/SIM_aircraft/images/wp4.png new file: trick_sims/SIM_aircraft/images/wp5.png new file: trick_sims/SIM_aircraft/images/wp6.png new file: trick_sims/SIM_aircraft/images/wp7.png new file: trick_sims/SIM_aircraft/images/wp8.png new file: trick_sims/SIM_aircraft/images/wp9.png modified: trick_sims/SIM_aircraft/models/graphics/src/trick/AircraftDisplay.java * Reformatted the README file * Updating the build process to use Maven * Updating the README file * Finalized the implementation for adding icons for each waypoint. * Removed commented code that will not be used. * Updated the SIM_aircraft documentation to include the waypoint icon implementation. * Created a menu bar for the GUI * Minor README fix and file cleanup * Implemented a view menu to hide and show the info on the map * Cleared out commented code. * Last minute code cleanup and update of the documentation. * Updated the View menu with more options and updated documentation. * Testing basic Variable Server Client usage. * Waypoints shared from sim to graphics client. Need to use list and fix some formatting. * Refactored and simplified Waypoint implementation * Documentation and comment updates * Simplified waypoint structure Implemented file support in graphics client * Updated Documentation * Created a default waypoint icon when unspecified * Fixed privacy issues in the WaypointList class * Cleaned up unnecessary file and added comments
36 lines
1.3 KiB
Python
36 lines
1.3 KiB
Python
exec(open("Modified_data/realtime.py").read())
|
|
|
|
dyn_integloop.getIntegrator(trick.Runge_Kutta_4, 6)
|
|
dyn_integloop.set_integ_cycle(0.01)
|
|
|
|
dyn.aircraft.set_desired_compass_heading(45.0);
|
|
dyn.aircraft.autoPilot = True;
|
|
dyn.aircraft.desired_speed = 200 # meters per second
|
|
|
|
#==========================================
|
|
# Read the waypoints from the input file
|
|
#==========================================
|
|
|
|
waypoints_path = "Modified_data/default.wps"
|
|
dyn.aircraft.flightPath.load(waypoints_path)
|
|
|
|
#==========================================
|
|
# Start the Satellite Graphics Client
|
|
#==========================================
|
|
varServerPort = trick.var_server_get_port();
|
|
AircraftDisplay_path = "models/graphics/build/AircraftDisplay.jar"
|
|
|
|
if (os.path.isfile(AircraftDisplay_path)) :
|
|
AircraftDisplay_cmd = "java -jar " \
|
|
+ AircraftDisplay_path \
|
|
+ " -w " + waypoints_path \
|
|
+ " " + str(varServerPort) + " &" ;
|
|
print(AircraftDisplay_cmd)
|
|
os.system( AircraftDisplay_cmd);
|
|
else :
|
|
print('==================================================================================')
|
|
print('AircraftDisplay needs to be built. Please \"cd\" into ../models/graphics and type \"make\".')
|
|
print('==================================================================================')
|
|
|
|
trick.stop(5400);
|