mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2025-12-12 01:00:29 +08:00
reset spi before uploading the firmware
This commit is contained in:
parent
fd7d17ad4a
commit
a3a17440dc
1
PKGBUILD
1
PKGBUILD
@ -63,6 +63,7 @@ depends=(
|
||||
openssl
|
||||
platformio
|
||||
avrdude-svn
|
||||
wiringpi
|
||||
make
|
||||
patch
|
||||
sudo
|
||||
|
||||
10
hid/Makefile
10
hid/Makefile
@ -12,7 +12,15 @@ _build:
|
||||
|
||||
install: upload
|
||||
upload:
|
||||
platformio run --environment $(shell cat .current) --target upload
|
||||
$(eval $@_CURRENT := $(shell cat .current))
|
||||
bash -ex -c " \
|
||||
current=`cat .current`; \
|
||||
if [ '$($@_CURRENT)' == 'spi' ] || [ '$($@_CURRENT)' == 'aum' ]; then \
|
||||
gpio -g write 25 1; \
|
||||
gpio -g write 25 0; \
|
||||
fi \
|
||||
"
|
||||
platformio run --environment '$($@_CURRENT)' --target upload
|
||||
|
||||
|
||||
bootloader-spi: install-bootloader-spi
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user