83 lines
2.7 KiB
Plaintext
83 lines
2.7 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.1244
|
|
+ cd /c/git/bt411/content
|
|
+ taskkill //F //IM btl4.exe
|
|
+ sleep 2
|
|
+ rm -f c42_a.log
|
|
+ bt_expert_egg MP.EGG C42.EGG
|
|
+ sed 's/^experience=.*/experience=expert/' MP.EGG
|
|
+ sed -i 's/^map=.*/map=grass/; s/^time=.*/time=day/; s/^vehicle=.*/vehicle=madcat/' C42.EGG
|
|
+ export BT_MODECYCLE_EVERY=400 BT_TWIST_PULSE=150
|
|
+ BT_MODECYCLE_EVERY=400
|
|
+ BT_TWIST_PULSE=150
|
|
+ export BT_BTNTEST=0x42,900,1150 BT_BTNTEST2=0x42,1500,1750
|
|
+ BT_BTNTEST=0x42,900,1150
|
|
+ BT_BTNTEST2=0x42,1500,1750
|
|
+ export BT_TORSO_LOG=1 BT_KEY_NOFOCUS=1 BT_KEY_BRIDGE=0
|
|
+ BT_TORSO_LOG=1
|
|
+ BT_KEY_NOFOCUS=1
|
|
+ BT_KEY_BRIDGE=0
|
|
+ bt_launch c42_a.log C42.EGG 0x03
|
|
+ local log=c42_a.log egg=C42.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=c42_a.log BT_AFFINITY=0x03
|
|
+ BT_LOG=c42_a.log
|
|
+ BT_AFFINITY=0x03
|
|
+ for _i in 1 2 3 4 5
|
|
+ '[' -f /proc/1252/winpid ']'
|
|
+ /c/git/bt411/build/Release/btl4.exe -egg C42.EGG
|
|
+ cat /proc/1252/winpid
|
|
+ break
|
|
+ sleep 130
|
|
+ bt_kill_ours
|
|
+ '[' -f /tmp/bt_bench_pids.1244 ']'
|
|
+ read -r pid
|
|
+ '[' -n 17048 ']'
|
|
+ taskkill //F //PID 17048
|
|
+ read -r pid
|
|
+ '[' -n 7508 ']'
|
|
+ taskkill //F //PID 7508
|
|
+ read -r pid
|
|
+ '[' -n 6636 ']'
|
|
+ taskkill //F //PID 6636
|
|
+ read -r pid
|
|
+ rm -f /tmp/bt_bench_pids.1244
|
|
+ sleep 2
|
|
+ taskkill //F //IM btl4.exe
|
|
+ sleep 3
|
|
+ echo '============ RESULT ============'
|
|
============ RESULT ============
|
|
+ grep -a '\[mode\] control mode' c42_a.log
|
|
+ head -4
|
|
[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 '--- ctrCmd seen (want some =1 during the 0x42 holds) ---'
|
|
--- ctrCmd seen (want some =1 during the 0x42 holds) ---
|
|
+ grep -ao 'ctrCmd=[01]' c42_a.log
|
|
+ sort
|
|
+ uniq -c
|
|
29 ctrCmd=0
|
|
+ echo '--- twist trajectory around the first hold ---'
|
|
--- twist trajectory around the first hold ---
|
|
+ grep -aE 'twistpulse|ctrCmd=1' c42_a.log
|
|
+ head -8
|
|
[twistpulse] phase=deflect axis=0.6 twist=0.372802 ctrCmd=0 recen=0
|
|
[twistpulse] phase=deflect axis=0.6 twist=0.639838 ctrCmd=0 recen=0
|
|
[twistpulse] phase=deflect axis=0.6 twist=0.9341 ctrCmd=0 recen=0
|
|
[twistpulse] phase=deflect axis=0.6 twist=1.20114 ctrCmd=0 recen=0
|
|
[twistpulse] phase=deflect axis=0.6 twist=1.46974 ctrCmd=0 recen=0
|
|
[twistpulse] phase=RELEASE axis=0 twist=1.47865 ctrCmd=0 recen=0
|
|
[twistpulse] phase=RELEASE axis=0 twist=1.47865 ctrCmd=0 recen=0
|
|
[twistpulse] phase=RELEASE axis=0 twist=1.47865 ctrCmd=0 recen=0
|