X-Git-Url: http://plrg.eecs.uci.edu/git/?p=pingpong.git;a=blobdiff_plain;f=automation%2Fclicker.sh;h=9316f3cb5fadaddee8b67088acca9d36688d751e;hp=28008c1478eb42d9706b13abac7bfcf79cffb29d;hb=bc0bb97f7e374a555240ed45f0da3242ab0ec235;hpb=6a5cb0f1f117c8c3628819643b73311d22237a05;ds=sidebyside diff --git a/automation/clicker.sh b/automation/clicker.sh index 28008c1..9316f3c 100755 --- a/automation/clicker.sh +++ b/automation/clicker.sh @@ -6,6 +6,7 @@ # Loop variables BEGIN=1 END=100 +#END=2 INC=1 # Range of random number (in seconds) @@ -17,18 +18,25 @@ do date +"%m/%d/%Y %r" #./adb shell getevent -l - use this command to get the position + # Click on screen + #./adb shell input tap 500 1500 # TP-Link switch #./adb shell input tap 1002 913 # TP-Link bulb on/off #./adb shell input tap 994 560 # D-Link switch #./adb shell input tap 987 346 - # SmartThings + # D-Link motion sensor + #./adb shell input tap 975 840 + # SmartThings plug #./adb shell input tap 921 1188 + #./adb shell input tap 533 653 + # WeMo, WeMo Insight, LiFX bulbs, Hue bulbs with ST-app + #./adb shell input tap 533 653 # WeMo #./adb shell input tap 981 532 # WeMo Insight - #./adb shell input tap 981 326 + ./adb shell input tap 981 326 # Kwikset doorlock #if (( $i % 2 )) #then @@ -40,6 +48,16 @@ do #fi # Hue bulb #./adb shell input tap 923 383 + #./adb shell input tap 900 550 + # Hue bulb intensity + #if (( $i % 2 )) + #then + # brighter + # ./adb shell input tap 100 650 + #else + # dimmer + # ./adb shell input tap 100 750 + #fi # Lifx bulb #./adb shell input tap 506 580 # Amcrest camera @@ -57,12 +75,16 @@ do #if (( $i % 2 )) #then # live view - # ./adb shell input tap 532 740 + #./adb shell input tap 532 740 + # ./adb shell input tap 533 653 #else # stop live view - # ./adb shell input tap 101 1012 + #./adb shell input tap 101 1012 + # ./adb shell input tap 533 653 + # ./adb shell input tap 533 653 + # ./adb shell input tap 533 653 #fi - # Blossom + # Blossom - turning on/off 1 zone #if (( $i % 2 )) #then # start watering @@ -71,25 +93,80 @@ do # stop watering # ./adb shell input tap 496 1533 #fi + # Blossom - change mode active/hibernate + #./adb shell input tap 1002 1176 # Dlink siren #./adb shell input tap 994 802 # Nest thermostat - if (( $i % 2)) - then + #if (( $i % 2)) + #then # start fan - ./adb shell input tap 524 1668 - ./adb shell input tap 936 1709 - else + # ./adb shell input tap 524 1668 + # ./adb shell input tap 936 1709 + #else # stop fan - ./adb shell input tap 524 1668 - ./adb shell input tap 679 1702 - fi + # ./adb shell input tap 524 1668 + # ./adb shell input tap 679 1702 + #fi + # Alexa + #if (( $i % 2)) + #then + # Using Google Translate and + # having her speak to Alexa + # Question 1 + # ./adb shell input tap 907 145 + # ./adb shell input tap 543 692 + # ./adb shell input tap 148 775 + #else + # Question 2 + # ./adb shell input tap 907 145 + # ./adb shell input tap 463 1668 + # ./adb shell input tap 148 775 + #fi #date +%r #RAND=$[( $RANDOM % $RAN_END ) + $RAN_STA] #RAND=$[`jot -r 1 $RAN_STA $RAN_END`] #echo "Delay: $RAND seconds" #sleep $[$RAND]s + + # TP-Link bulb - change colors & intensity + #if (( $i % 2 )) + #then + # color 1 - horizontal + #./adb shell input tap 250 1000 + # color 3 - vertical + #./adb shell input tap 500 1250 + # intensity change (vertical) + # ./adb shell input tap 250 1405 + #else + # color 2 - horizontal + #./adb shell input tap 750 1000 + # color 4 - vertical + #./adb shell input tap 500 750 + # intensity change (vertical) + # ./adb shell input tap 850 1405 + #fi + # Hue bulb - change intensity + #if (( $i % 2 )) + #then + # intensity change (bright) + # ./adb shell input tap 300 550 + #else + # intensity change (dimmed) + # ./adb shell input tap 800 550 + #fi + # Arlo camera - arm/disarm + #if (( $i % 2 )) + #then + # Arm + # ./adb shell input tap 500 500 + #else + # Disarm + # ./adb shell input tap 500 750 + #fi # pick a prime number > 120 seconds sleep 131s + #sleep 13s done +#ssh root@192.168.1.1 "kill -9 18572 18576"