autoverse-cli 0.15.6__py3-none-any.whl → 0.15.7__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {autoverse_cli-0.15.6.dist-info → autoverse_cli-0.15.7.dist-info}/METADATA +1 -1
- {autoverse_cli-0.15.6.dist-info → autoverse_cli-0.15.7.dist-info}/RECORD +9 -9
- avrs/app_version.py +1 -1
- avrs/race_cloud.py +4 -2
- avrs/race_cloud_util.py +44 -0
- {autoverse_cli-0.15.6.dist-info → autoverse_cli-0.15.7.dist-info}/LICENSE +0 -0
- {autoverse_cli-0.15.6.dist-info → autoverse_cli-0.15.7.dist-info}/WHEEL +0 -0
- {autoverse_cli-0.15.6.dist-info → autoverse_cli-0.15.7.dist-info}/entry_points.txt +0 -0
- {autoverse_cli-0.15.6.dist-info → autoverse_cli-0.15.7.dist-info}/top_level.txt +0 -0
@@ -1,5 +1,5 @@
|
|
1
1
|
avrs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
-
avrs/app_version.py,sha256=
|
2
|
+
avrs/app_version.py,sha256=OkKjPWlmlP2YbrQFrBiiISJSD6XC0MvhEekaXX6ak7Y,856
|
3
3
|
avrs/argparse_help.py,sha256=EoEaohGXZXqJvs1dFEzbo9vh47CYdHdSY2Im2Ps2iFo,945
|
4
4
|
avrs/avrs.py,sha256=bGF35a72MZU41OVWnFHmchqmgKXBKh9djokzGA_4pL4,4621
|
5
5
|
avrs/can_tool.py,sha256=IBoctKobBJ3wCq4ZdtuXuXH4AMEUxazCfYT6YP0Luw8,7161
|
@@ -7,10 +7,10 @@ avrs/can_tool_util.py,sha256=G3q21dTGMLc09SDq_RieoW7kSn-kXPkXxPDjavPh4hQ,7710
|
|
7
7
|
avrs/cfg.py,sha256=kMn08Z4Ms1PAu2-U1QI8weEJeIVEppP4A4_tFfwnjtg,2924
|
8
8
|
avrs/launcher.py,sha256=kk1lyHHLgFZ4zsFfa_zV5f1kYbUODT6wEILJ8TZ16rQ,9353
|
9
9
|
avrs/launcher_util.py,sha256=sO3k_z3A-HIQdJVkVXNXUAE_MGFwAYiZUqQBoFwOqew,5325
|
10
|
-
avrs/race_cloud.py,sha256=
|
10
|
+
avrs/race_cloud.py,sha256=pImJusZ4XCyl7tyt5Q5s69DjPxPvXfzWgkcRnzuWoeE,19119
|
11
11
|
avrs/race_cloud_cfg_util.py,sha256=H3MLxkb-PBwFVXdA5IBGzWGjLeD-uBvPqIgkh7RGjfo,7214
|
12
12
|
avrs/race_cloud_fwd_api.py,sha256=HuLE5kfmzVq08aP3tlEh3f8WNjGL5N3K5EbXg9uQomo,1506
|
13
|
-
avrs/race_cloud_util.py,sha256=
|
13
|
+
avrs/race_cloud_util.py,sha256=gpSHob0YA_ahFqqSFIKdi_3Jt36e1PF6oEEL-ni7el0,12343
|
14
14
|
avrs/simconfig.py,sha256=UZc4FrxVHUkk2e9IglSpuojXkaL_nPrJW7trbEGgOOo,2907
|
15
15
|
avrs/simconfig_util.py,sha256=1RmnmhK5C4HlCicTQeqn-1ORz3Xrku_QMt1Fqr9XjZs,4839
|
16
16
|
avrs/tests.py,sha256=3JeYBjn0tRqHXERDROfzmYuW1KXeCcKur5Bw-EIegto,153
|
@@ -37,9 +37,9 @@ avrs/requests/toggle_hud.py,sha256=sV5t5QZc4uvRihPVk8jEKZiQNsyF9tsUwq5b4jjZplc,3
|
|
37
37
|
avrs/requests/vd.py,sha256=gdt5XCdCCVdECL3qt8y-PKDrlArjeY_lxtT4VpZmAJo,1804
|
38
38
|
avrs/requests/vehicle_input.py,sha256=R1b1xkRtOBkwyU6OSN4bWVlYsIUroZG0WKbYbc4pEH8,729
|
39
39
|
avrs/requests/vehicle_replay.py,sha256=nCAE21VNyKoeIjjXBGAihgOLO7zYHcu-HWvPZYxdQ2c,11099
|
40
|
-
autoverse_cli-0.15.
|
41
|
-
autoverse_cli-0.15.
|
42
|
-
autoverse_cli-0.15.
|
43
|
-
autoverse_cli-0.15.
|
44
|
-
autoverse_cli-0.15.
|
45
|
-
autoverse_cli-0.15.
|
40
|
+
autoverse_cli-0.15.7.dist-info/LICENSE,sha256=d4eWXho-u18HkBsX4K21uHX_bBb2UXZSrJdsb7Z_JlM,2647
|
41
|
+
autoverse_cli-0.15.7.dist-info/METADATA,sha256=B_0s8ztA6rnRhd_9s-GnmuZgOm1FXrTe1JFjB-1Pm14,3342
|
42
|
+
autoverse_cli-0.15.7.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
|
43
|
+
autoverse_cli-0.15.7.dist-info/entry_points.txt,sha256=Cb9qsUyU5AKkklehCcvtfT0-N3SXbUEqvjze4iEU5kE,40
|
44
|
+
autoverse_cli-0.15.7.dist-info/top_level.txt,sha256=-AJO2e4MCVej6hY0U84pu5NfMeMW5qaAPSMisDT5rmA,5
|
45
|
+
autoverse_cli-0.15.7.dist-info/RECORD,,
|
avrs/app_version.py
CHANGED
avrs/race_cloud.py
CHANGED
@@ -430,11 +430,13 @@ class AvrsRaceCloud(AvrsApiRequest):
|
|
430
430
|
def enable_peer_qos(self, args):
|
431
431
|
print('enabling peer qos for id {} using ip address {}'.format(
|
432
432
|
args.peer_id, args.ip))
|
433
|
-
enable_peer_qos(args.peer_id, args.ip)
|
433
|
+
out = enable_peer_qos(args.peer_id, args.ip)
|
434
|
+
print('{} {}'.format(out.out, out.err))
|
434
435
|
|
435
436
|
def disable_peer_qos(self, args):
|
436
437
|
print('disabling peer qos for id {}'.format(args.peer_id))
|
437
|
-
disable_peer_qos(args.peer_id)
|
438
|
+
out = disable_peer_qos(args.peer_id)
|
439
|
+
print('{} {}'.format(out.out, out.err))
|
438
440
|
|
439
441
|
def fwd_api(self, args):
|
440
442
|
# start a server that listens for http on some port and forwards
|
avrs/race_cloud_util.py
CHANGED
@@ -62,11 +62,37 @@ DEFAULT_RMW_QOS = '''
|
|
62
62
|
</profiles>
|
63
63
|
'''
|
64
64
|
|
65
|
+
DEFAULT_RMW_CYCLONE = '''
|
66
|
+
<?xml version="1.0" encoding="UTF-8" ?>
|
67
|
+
<CycloneDDS>
|
68
|
+
<Domain id="any">
|
69
|
+
<Discovery>
|
70
|
+
<ParticipantIndex>auto</ParticipantIndex>
|
71
|
+
<Peers>
|
72
|
+
<Peer address='127.0.0.1'/>
|
73
|
+
<!--<Peer address='PEER_0'/>PEER0-->
|
74
|
+
<!--<Peer address='PEER_1'/>PEER1-->
|
75
|
+
<!--<Peer address='PEER_2'/>PEER2-->
|
76
|
+
<!--<Peer address='PEER_3'/>PEER3-->
|
77
|
+
<!--<Peer address='PEER_4'/>PEER4-->
|
78
|
+
<!--<Peer address='PEER_5'/>PEER5-->
|
79
|
+
</Peers>
|
80
|
+
</Discovery>
|
81
|
+
</Domain>
|
82
|
+
</CycloneDDS>
|
83
|
+
'''
|
84
|
+
|
65
85
|
DISABLE_PEER_QOS_SCRIPT = '''
|
66
86
|
QOS_FILE_PATH={qos_path}
|
87
|
+
CYCLONE_PATH={cyclone_path}
|
67
88
|
PEER_ID={peer_id}
|
89
|
+
|
90
|
+
# for the origin rmw qos file
|
68
91
|
sed -i -E "s,(<locator> <udpv4> <address>)(.+)(</address> </udpv4> </locator>)<!--(PEER$PEER_ID-->),<!--\\1PEER$PEER_ID\\3\\4,g" $QOS_FILE_PATH
|
69
92
|
|
93
|
+
# for the cyclone file
|
94
|
+
sed -i -E "s,(<Peer address=')(.+)('/>)<!--(PEER$PEER_ID-->),<!--\\1PEER$PEER_ID\\3\\4,g" $CYCLONE_PATH
|
95
|
+
|
70
96
|
VCAN_NAME=vcan$PEER_ID
|
71
97
|
if [[ -e $VCAN_NAME.lock ]]; then
|
72
98
|
echo "stopping existing cannelloni connection with pid $(cat $VCAN_NAME.lock)"
|
@@ -77,9 +103,15 @@ DISABLE_PEER_QOS_SCRIPT = '''
|
|
77
103
|
|
78
104
|
ENABLE_PEER_QOS_SCRIPT = '''
|
79
105
|
QOS_FILE_PATH={qos_path}
|
106
|
+
CYCLONE_PATH={cyclone_path}
|
80
107
|
PEER_ID={peer_id}
|
81
108
|
PEER_ADDRESS={peer_ip}
|
109
|
+
|
110
|
+
# for the origin rmw qos file
|
82
111
|
sed -i -E "s,(<!--?)(<locator> <udpv4> <address>)(.+)(</address> </udpv4> </locator>)(PEER$PEER_ID-->),\\2$PEER_ADDRESS\\4<!--\\5,g" $QOS_FILE_PATH
|
112
|
+
|
113
|
+
# for the cyclone file
|
114
|
+
sed -i -E "s,(<!--?)(<Peer address=')(.+)('/>)(PEER$PEER_ID-->),\\2$PEER_ADDRESS\\4<!--\\5,g" $CYCLONE_PATH
|
83
115
|
'''
|
84
116
|
|
85
117
|
CONNECT_PEER_VCAN_SCRIPT = '''
|
@@ -166,15 +198,25 @@ def get_sim_exe_path():
|
|
166
198
|
def get_rmw_qos_path():
|
167
199
|
return os.path.join(os.environ['HOME'], '.rmw_qos.xml')
|
168
200
|
|
201
|
+
def get_rmw_cyclone_qos_path():
|
202
|
+
return os.path.join(os.environ['HOME'], '.cyclone.xml')
|
203
|
+
|
169
204
|
def reset_rmw_qos():
|
170
205
|
with open(get_rmw_qos_path(), 'w', encoding='utf-8') as f:
|
171
206
|
f.write(DEFAULT_RMW_QOS)
|
172
207
|
|
208
|
+
def reset_rmw_cyclone_qos():
|
209
|
+
with open(get_rmw_cyclone_qos_path(), 'w', encoding='utf-8') as f:
|
210
|
+
f.write(DEFAULT_RMW_CYCLONE)
|
211
|
+
|
173
212
|
def disable_peer_qos(peer_id):
|
174
213
|
if not os.path.isfile(get_rmw_qos_path()):
|
175
214
|
reset_rmw_qos()
|
215
|
+
if not os.path.isfile(get_rmw_cyclone_qos_path()):
|
216
|
+
reset_rmw_cyclone_qos()
|
176
217
|
pargs = {
|
177
218
|
'qos_path': get_rmw_qos_path(),
|
219
|
+
'cyclone_path': get_rmw_cyclone_qos_path(),
|
178
220
|
'peer_id': peer_id
|
179
221
|
}
|
180
222
|
return run_process(['bash', '-c',
|
@@ -184,6 +226,7 @@ def enable_peer_qos(peer_id, peer_ip):
|
|
184
226
|
disable_peer_qos(peer_ip) # disable first
|
185
227
|
pargs = {
|
186
228
|
'qos_path': get_rmw_qos_path(),
|
229
|
+
'cyclone_path': get_rmw_cyclone_qos_path(),
|
187
230
|
'peer_id': peer_id,
|
188
231
|
'peer_ip': peer_ip
|
189
232
|
}
|
@@ -252,6 +295,7 @@ def get_local_instance_ip():
|
|
252
295
|
|
253
296
|
def reset_race_cloud_connection():
|
254
297
|
reset_rmw_qos()
|
298
|
+
reset_rmw_cyclone_qos()
|
255
299
|
run_process(['bash', '-c', 'rm ~/.simslot*']) # remove slot reservations
|
256
300
|
run_process(['bash', '-c', 'rm ~/.vcan*']) # remove lock files
|
257
301
|
bash_kill_process('cannelloni')
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|