forked from AlfredoSystems/PestoLink-Online
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
177 lines (151 loc) · 8.07 KB
/
index.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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline';">
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico">
<meta name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no">
<title>PestoLink-Basil</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<div id="user-container">
<div class="container mobile-only" id="mobile-joystick">
<div id="joystick-background">
<div id="joystick-container"></div>
</div>
</div>
<div>
<div class="container desktop-only" id="desktop-axis">
<div class="slider-non">Axis 0</div>
<div class="slider-non" id="0axisValue0">127</div>
<div class="slider-bar" id="0bar0"></div>
<div class="slider-non">Axis 1</div>
<div class="slider-non" id="0axisValue1">127</div>
<div class="slider-bar" id="0bar1"></div>
<div class="slider-non">Axis 2</div>
<div class="slider-non" id="0axisValue2">127</div>
<div class="slider-bar" id="0bar2"></div>
<div class="slider-non">Axis 3</div>
<div class="slider-non" id="0axisValue3">127</div>
<div class="slider-bar" id="0bar3"></div>
</div>
<div class="container desktop-only" id="desktop-axis1">
<div class="slider-non">Axis 0</div>
<div class="slider-non" id="1axisValue0">127</div>
<div class="slider-bar" id="1bar0"></div>
<div class="slider-non">Axis 1</div>
<div class="slider-non" id="1axisValue1">127</div>
<div class="slider-bar" id="1bar1"></div>
<div class="slider-non">Axis 2</div>
<div class="slider-non" id="1axisValue2">127</div>
<div class="slider-bar" id="1bar2"></div>
<div class="slider-non">Axis 3</div>
<div class="slider-non" id="1axisValue3">127</div>
<div class="slider-bar" id="1bar3"></div>
</div>
</div>
<div class="container" id="interface">
<button id="ble-button">🔗</button>
<button id="telemetry">no data</button>
<button id="ble-status">not connected</button>
<div id="settings-grid">
<div class="settings-label">Mobile Layout</div>
<div class="settings-toggle">
<div id="toggle-mobile-layout" class="toggle-round"><div class="toggle-nub"></div></div>
</div>
<div class="settings-label help-row">Override axes <br> with WASD</div>
<div class="settings-toggle help-row">
<div id="toggle-keyboard-style" class="toggle-round"><div class="toggle-nub"></div></div>
</div>
<div class="settings-label help-row">Help/Info!</div>
<div class="settings-toggle help-row">
<div id="toggle-info" class="toggle-round"><div class="toggle-nub"></div></div>
</div>
<div class="settings-label help-row">Dual Input</div>
<div class="settings-toggle help-row">
<div id="toggle-dual-controllers" class="toggle-round"><div class="toggle-nub"></div></div>
</div>
</div>
</div>
<div class="container mobile-only" id="mobile-button">
<div></div>
<button id="button-3">3</button>
<div></div>
<button id="button-2">2</button>
<div></div>
<button id="button-1">1</button>
<div></div>
<button id="button-0">0</button>
<div></div>
</div>
<div>
<div class="container desktop-only" id="desktop-button">
<button id="0buttonDesktop0">0</button>
<button id="0buttonDesktop1">1</button>
<button id="0buttonDesktop2">2</button>
<button id="0buttonDesktop3">3</button>
<button id="0buttonDesktop4">4</button>
<button id="0buttonDesktop5">5</button>
<button id="0buttonDesktop6">6</button>
<button id="0buttonDesktop7">7</button>
<button id="0buttonDesktop8">8</button>
<button id="0buttonDesktop9">9</button>
<button id="0buttonDesktop10">10</button>
<button id="0buttonDesktop11">11</button>
<button id="0buttonDesktop12">12</button>
<button id="0buttonDesktop13">13</button>
<button id="0buttonDesktop14">14</button>
<button id="0buttonDesktop15">15</button>
</div>
<div class="container desktop-only" id="desktop-button1" >
<button id="1buttonDesktop0">0</button>
<button id="1buttonDesktop1">1</button>
<button id="1buttonDesktop2">2</button>
<button id="1buttonDesktop3">3</button>
<button id="1buttonDesktop4">4</button>
<button id="1buttonDesktop5">5</button>
<button id="1buttonDesktop6">6</button>
<button id="1buttonDesktop7">7</button>
<button id="1buttonDesktop8">8</button>
<button id="1buttonDesktop9">9</button>
<button id="1buttonDesktop10">10</button>
<button id="1buttonDesktop11">11</button>
<button id="1buttonDesktop12">12</button>
<button id="1buttonDesktop13">13</button>
<button id="1buttonDesktop14">14</button>
<button id="1buttonDesktop15">15</button>
</div>
</div>
</div>
<div id="info-container">
<p>
<u>PestoLink Basil</u>
<br>
An all new version of PestoLink made by Kavin from team 5338 Roboloco!
Featuring:
<br>
-Better keyboard controls that allow for use of all buttons(not just the first few)
<br>
-Dual Controller Support to emulate FRC better
<br><br>
<u>Embedded Platform Support</u>
<br> <a href="https://github.com/AlfredoSystems/PestoLink-MicroPython">PestoLink</a> currently supports two embedded platforms, MicroPython and Arduino
(designed for <a href="https://www.sparkfun.com/products/22230">RP2040 on XRP Kits</a> and <a href="https://www.alfredosys.com/products/alfredo-nou2/">ESP32</a> respectively).
<br> MicroPython based robots use the module <a href="https://github.com/AlfredoSystems/PestoLink-MicroPython/tree/main">PestoLink-MicroPython</a>.
,Arduino based robots use the library <a href="https://github.com/AlfredoSystems/PestoLink-Receive">PestoLink-Receive</a>.
<br><br> <u>Browser Support</u>
<br> PestoLink works with Google Chrome on Windows, Android, Mac, Linux, and ChromeOS.
<br>On iOS very few web browsers support webBluetooth. Google Chrome has worked for some people, but <a href="https://apps.apple.com/us/app/bluefy-web-ble-browser/id1492822055">Bluefy</a> is the best option found so far.
<br><br> <u>What does "Override axes with WASD" do?</u>
<br> By default, keyboard data is sent seperatly from axis/button data. If you would like to drive your robot using your keyboard,
you can enable this switch to override the axis/button data with keyboard input. 'WASD' will override Axis 0 and Axis 1. 'IJKL' will override Axis 2 and Axis 3.
'QERTYUOPZXCVBNM,' will override the number buttons. Currently, a way to change button maps is in progress.
<br><br> If you have any questions, feel free to reach out to me at [email protected]!
</p>
</div>
<div id="hack-spacer"></div>
<script src="index.js"></script>
</body>
</html>