-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbicycle_model.html
38 lines (24 loc) · 1.42 KB
/
bicycle_model.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<!doctype html>
<script src="https://code.jquery.com/jquery-3.5.1.min.js"></script>
<script src="https://openrtdynamics.github.io/openrtdynamics.js"></script>
<html>
<div id='simulator_gui_container' class="wrap5">
<plot type="plotly" x="x" y="y" title="x/y" xlabel="x" ylabel="y" width="800" height="200"></plot>
<div class='parameter_editor'></div>
<plot type="plotly" x="time" y="steering" title="steering" xlabel="time [s]" ylabel="value" width="400" height="200"></plot>
</div>
<script>
$(document).ready(function() {
// load the simulator and its interface
folder = 'generated/bicycle_model'
var files = { manifest : folder + '/simulation_manifest.json', wasm : folder + '/main.wasm', jscode : folder + '/main.js' }
var ret = openrtdynamics.loadCompiledSimulator(files);
simulator_gui_container = document.getElementById('simulator_gui_container')
openrtdynamics.setup_simulation_gui_from_promises( simulator_gui_container, ret, {number_of_samples : 2000, sampling_time : 0.01});
});
</script>
<link rel="stylesheet" href="css/input_gui.css">
<link rel="stylesheet" href="css/layout.css">
<script src="https://cdn.jsdelivr.net/npm/chart.js@2.9.4/dist/Chart.min.js"></script>
<script src="https://cdn.plot.ly/plotly-latest.min.js"></script>
</html>