105 lines
4.1 KiB
Plaintext
105 lines
4.1 KiB
Plaintext
+ . /c/git/bt411/scratchpad/night6/bench_common.sh
|
|
++ BT_ROOT=/c/git/bt411
|
|
++ BT_EXE=/c/git/bt411/build/Release/btl4.exe
|
|
++ BT_PIDFILE=/tmp/bt_bench_pids.263
|
|
+ cd /c/git/bt411/content
|
|
+ taskkill //F //IM btl4.exe
|
|
+ sleep 2
|
|
+ rm -f mc_a.log
|
|
+ bt_expert_egg MP.EGG MC.EGG
|
|
+ sed 's/^experience=.*/experience=expert/' MP.EGG
|
|
+ sed -i 's/^map=.*/map=grass/; s/^time=.*/time=day/; s/^vehicle=.*/vehicle=madcat/' MC.EGG
|
|
+ export BT_MODECYCLE_EVERY=400
|
|
+ BT_MODECYCLE_EVERY=400
|
|
+ export BT_TORSO_LOG=1 BT_KEY_NOFOCUS=1 BT_KEY_BRIDGE=1
|
|
+ BT_TORSO_LOG=1
|
|
+ BT_KEY_NOFOCUS=1
|
|
+ BT_KEY_BRIDGE=1
|
|
+ bt_launch mc_a.log MC.EGG 0x03
|
|
+ local log=mc_a.log egg=MC.EGG aff=0x03
|
|
+ shift 3
|
|
+ bt_player_env
|
|
+ export BT_PLATFORM=glass
|
|
+ BT_PLATFORM=glass
|
|
+ export BT_START_INSIDE=1
|
|
+ BT_START_INSIDE=1
|
|
+ export BT_DEV_GAUGES=1
|
|
+ BT_DEV_GAUGES=1
|
|
+ export BT_LOG=mc_a.log BT_AFFINITY=0x03
|
|
+ BT_LOG=mc_a.log
|
|
+ BT_AFFINITY=0x03
|
|
+ for _i in 1 2 3 4 5
|
|
+ '[' -f /proc/271/winpid ']'
|
|
+ /c/git/bt411/build/Release/btl4.exe -egg MC.EGG
|
|
+ cat /proc/271/winpid
|
|
+ break
|
|
+ sleep 150
|
|
+ bt_kill_ours
|
|
+ '[' -f /tmp/bt_bench_pids.263 ']'
|
|
+ read -r pid
|
|
+ '[' -n 17164 ']'
|
|
+ taskkill //F //PID 17164
|
|
+ read -r pid
|
|
+ rm -f /tmp/bt_bench_pids.263
|
|
+ sleep 2
|
|
+ taskkill //F //IM btl4.exe
|
|
+ sleep 3
|
|
+ echo '=================== CONTROL-MODE TORSO STATE ==================='
|
|
=================== CONTROL-MODE TORSO STATE ===================
|
|
+ echo '--- the mode cycles that happened ---'
|
|
--- the mode cycles that happened ---
|
|
+ grep -a '\[mode\] control mode' mc_a.log
|
|
+ head -10
|
|
[mode] control mode -> 1 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 2 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 0 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 1 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 2 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 0 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 1 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 2 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 0 (0=Basic 1=Standard 2=Veteran)
|
|
[mode] control mode -> 1 (0=Basic 1=Standard 2=Veteran)
|
|
+ echo
|
|
|
|
+ echo '--- centerCommand must NEVER latch (ctrCmd=1 with no button = the bug) ---'
|
|
--- centerCommand must NEVER latch (ctrCmd=1 with no button = the bug) ---
|
|
+ echo -n ' samples with ctrCmd=1 : '
|
|
samples with ctrCmd=1 : + grep -ao 'ctrCmd=[0-9]*' mc_a.log
|
|
+ grep -c ctrCmd=1
|
|
0
|
|
+ echo -n ' samples with ctrCmd=0 : '
|
|
samples with ctrCmd=0 : + grep -ao 'ctrCmd=[0-9]*' mc_a.log
|
|
+ grep -c ctrCmd=0
|
|
71
|
|
+ echo
|
|
|
|
+ echo '--- the elevation-limit SWAP (should differ between Basic and assisted) ---'
|
|
--- the elevation-limit SWAP (should differ between Basic and assisted) ---
|
|
+ grep -ao 'vLim=([^)]*)' mc_a.log
|
|
+ sort
|
|
+ uniq -c
|
|
+ sort -rn
|
|
+ head -5
|
|
46 vLim=(-0.698132..0.349066)
|
|
25 vLim=(-0.349066..0.349066)
|
|
+ echo
|
|
|
|
+ echo '--- torso state around each mode change ---'
|
|
--- torso state around each mode change ---
|
|
+ grep -aE '\[mode\] control mode|ctrCmd=' mc_a.log
|
|
+ grep -aA1 '\[mode\]'
|
|
+ head -12
|
|
[mode] control mode -> 1 (0=Basic 1=Standard 2=Veteran)
|
|
[torso] hmOff=0 elec=4 heatState=0 rate=0.872665 base=0.872665 hEn=1 limits=(-2.44346..2.44346) axis=0 twist=0 ctrCmd=0 recen=0 vLim=(-0.698132..0.349066) wIdx=15 w=0538D300 wElec=4 wSrc=0538CD78 gOut=10000 gRated=10000 minV=0.5
|
|
--
|
|
[mode] control mode -> 2 (0=Basic 1=Standard 2=Veteran)
|
|
[torso] hmOff=0 elec=4 heatState=0 rate=0.872665 base=0.872665 hEn=1 limits=(-2.44346..2.44346) axis=0 twist=0 ctrCmd=0 recen=0 vLim=(-0.698132..0.349066) wIdx=15 w=0538D300 wElec=4 wSrc=0538CD78 gOut=10000 gRated=10000 minV=0.5
|
|
--
|
|
[mode] control mode -> 0 (0=Basic 1=Standard 2=Veteran)
|
|
[torso] hmOff=0 elec=4 heatState=0 rate=0.872665 base=0.872665 hEn=1 limits=(-2.44346..2.44346) axis=0 twist=0 ctrCmd=0 recen=0 vLim=(-0.349066..0.349066) wIdx=15 w=0538D300 wElec=4 wSrc=0538CD78 gOut=10000 gRated=10000 minV=0.5
|
|
--
|
|
[mode] control mode -> 1 (0=Basic 1=Standard 2=Veteran)
|
|
[torso] hmOff=0 elec=4 heatState=0 rate=0.872665 base=0.872665 hEn=1 limits=(-2.44346..2.44346) axis=0 twist=0 ctrCmd=0 recen=0 vLim=(-0.698132..0.349066) wIdx=15 w=0538D300 wElec=4 wSrc=0538CD78 gOut=10000 gRated=10000 minV=0.5
|
|
--
|