2020-01-02 15:58:28 -08:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
#set -x
|
|
|
|
#TS_PATH="/home/<user>/TunerStudioProjects/"
|
|
|
|
|
|
|
|
echo "This batch files reads rusefi_config.txt and produses firmware persistent configuration headers"
|
|
|
|
echo "the storage section of rusefi.ini is updated as well"
|
|
|
|
|
|
|
|
rm gen_config.log
|
|
|
|
rm gen_config_board.log
|
|
|
|
|
|
|
|
mkdir build
|
|
|
|
|
2020-06-19 07:10:17 -07:00
|
|
|
java $(< ../gen_config.conf)
|
2020-01-02 15:58:28 -08:00
|
|
|
|
|
|
|
[ $? -eq 0 ] || (echo "ERROR generating"; exit $?)
|
|
|
|
|
|
|
|
if [ -z "${TS_PATH}" ]; then
|
2020-06-19 07:10:17 -07:00
|
|
|
echo "TS_PATH not defined"
|
2020-01-02 15:58:28 -08:00
|
|
|
else
|
2020-06-19 07:10:17 -07:00
|
|
|
echo "This would automatically copy latest file to 'dev' TS project at ${TS_PATH}"
|
|
|
|
cp -v tunerstudio/rusefi.ini $TS_PATH/dev/projectCfg/mainController.ini
|
|
|
|
cp -v tunerstudio/rusefi_microrusefi.ini $TS_PATH/dev_mre/projectCfg/mainController.ini
|
2020-01-02 15:58:28 -08:00
|
|
|
fi
|
|
|
|
|
2020-06-19 07:10:17 -07:00
|
|
|
for BOARD in "microrusefi" "frankenso" "prometheus" "proteus"; do
|
|
|
|
sh gen_config_board.sh $BOARD
|
|
|
|
[ $? -eq 0 ] || (echo "ERROR generating $BOARD"; exit $?)
|
|
|
|
done
|
2020-01-02 15:58:28 -08:00
|
|
|
|
2020-06-19 07:10:17 -07:00
|
|
|
cd config/boards/kinetis/config
|
|
|
|
sh gen_config.sh
|
2020-01-02 15:58:28 -08:00
|
|
|
|
|
|
|
exit 0
|