2020-11-29 18:30:27 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
2021-11-14 14:06:48 +00:00
|
|
|
source config.sh $@
|
2020-11-29 18:30:27 +00:00
|
|
|
|
|
|
|
echo "Installing on internal flash..."
|
2020-12-02 04:14:00 +00:00
|
|
|
if ! ${OPENOCD} -f openocd/interface_"${ADAPTER}".cfg \
|
2020-11-29 18:30:27 +00:00
|
|
|
-c "init;" \
|
|
|
|
-c "halt;" \
|
|
|
|
-c "program prebuilt/gw_retrogo_nes.elf;" \
|
2021-11-14 14:06:48 +00:00
|
|
|
-c "program prebuilt/gw_retrogo_nes_extflash.bin 0x90000000"
|
2020-11-29 18:30:27 +00:00
|
|
|
-c "exit;" >>logs/5_openocd.log 2>&1; then
|
|
|
|
echo "Installing on flash failed."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
echo "Success!"
|