- more changes from master repo
This commit is contained in:
parent
9e109f0b59
commit
9c0c2fd817
|
|
@ -0,0 +1,27 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
MAC_ADDRESS=""
|
||||||
|
read -p "Please enter MAC BT address: " MAC_ADDRESS
|
||||||
|
|
||||||
|
# Write the address into config file before
|
||||||
|
sed -i "s/MAC_ADDRESS/$MAC_ADDRESS/" config/config.yaml
|
||||||
|
|
||||||
|
|
||||||
|
bluetoothctl -- power on
|
||||||
|
bluetoothctl -- agent on
|
||||||
|
sleep 10 # Time to give BT to start
|
||||||
|
|
||||||
|
bluetoothctl -- default-agent
|
||||||
|
bluetoothctl -- discoverable on
|
||||||
|
bluetoothctl -- pairable on
|
||||||
|
|
||||||
|
# Try to pair now
|
||||||
|
bluetoothctl -- pair ${MAC_ADDRESS}
|
||||||
|
sleep 10
|
||||||
|
|
||||||
|
# Trust to device
|
||||||
|
bluetoothctl -- trust ${MAC_ADDRESS}
|
||||||
|
|
||||||
|
# Connect to device
|
||||||
|
bluetoothctl -- connect ${MAC_ADDRESS}
|
||||||
|
sleep 5
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
INSTALL_DIR=agent_gsm
|
INSTALL_DIR=agent_gsm
|
||||||
|
|
||||||
# Re
|
# Re
|
||||||
GIT_SOURCE=https://deploy:deploy@git.sevana.biz/agent_gsm_redist
|
GIT_SOURCE=https://git.sevana.biz/public/agent_gsm_redist
|
||||||
|
|
||||||
# Install prerequisites
|
# Install prerequisites
|
||||||
sudo apt install git mc python3 sox vim
|
sudo apt install git mc python3 sox vim
|
||||||
|
|
@ -19,9 +19,6 @@ git clone $GIT_SOURCE $INSTALL_DIR
|
||||||
# Go to cloned directory
|
# Go to cloned directory
|
||||||
cd $INSTALL_DIR
|
cd $INSTALL_DIR
|
||||||
|
|
||||||
# Run bootstrap app
|
|
||||||
./pi_bootstrap_bt.sh
|
|
||||||
|
|
||||||
# Update config file
|
# Update config file
|
||||||
BACKEND_URL=""
|
BACKEND_URL=""
|
||||||
PHONE_NAME=""
|
PHONE_NAME=""
|
||||||
|
|
@ -50,5 +47,12 @@ ABSOLUTE_INSTALL_DIR=`realpath $INSTALL_DIR`
|
||||||
|
|
||||||
sed -i "s/ABSOLUTE_INSTALL_DIR/$ABSOLUTE_INSTALL_DIR/" config/systemd/agent_gsm.service
|
sed -i "s/ABSOLUTE_INSTALL_DIR/$ABSOLUTE_INSTALL_DIR/" config/systemd/agent_gsm.service
|
||||||
|
|
||||||
echo Please run $INSTALL_DIR/run_node.sh to see if everything works ok.
|
echo "Now the remaining prerequisites will be installed and system will reboot."
|
||||||
echo After you can use $INSTALL_DIR/config/systemd/agent_gsm.service to enable this work with systemD.
|
echo "You can connect the phone via Bluetooth after the reboot."
|
||||||
|
echo "Use the connect_phone.sh to ease the connection process. This script will ask you about Bluetooth MAC address and make attempt to pair & connect the phone. "
|
||||||
|
echo "Please run $INSTALL_DIR/run_node.sh to see if everything works ok."
|
||||||
|
echo "After you can use $INSTALL_DIR/config/systemd/agent_gsm.service to enable this work with systemD."
|
||||||
|
|
||||||
|
# Run bootstrap app
|
||||||
|
./pi_bootstrap_bt.sh
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
adb shell input keyevent 6
|
|
||||||
|
|
@ -1,3 +1,3 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#
|
|
||||||
journalctl -u qualtest -f
|
journalctl -u agent_gsm -f
|
||||||
|
|
|
||||||
|
|
@ -1,3 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
adb shell dumpsys package biz.sevana.qualtestgsm
|
|
||||||
Loading…
Reference in New Issue