This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo -e "${ylw}Спарить PS3 Bluetooth remote\n(y|n)?${rst}" | |
read btr | |
case "$btr" in | |
y) cd $PS3DIR | |
tar xvfz ps3pair.tar.gz | |
cd ps3pair | |
echo "${grn}Спариваем устройства...${rst}" | |
sudo python ps3_pair.py | |
#sudo bluez-test-input connect 00:24:33:A0:43:18 | |
sudo /usr/share/doc/bluez/examples/list-devices | grep Connected |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Скрипт следит за показаниями напряжения на ИБП через apcupsd, в случае, если напряжение выходит за нормы | |
#+отправляет обращение через личный кабинет | |
#+Для работы скрипта нужны учетные данные для доступа в личный кабинет и IDX устройств с показаниями напряжения | |
#======Задаем переменные | |
ROS_SITE="https://lk.mrsksevzap.ru/" | |
ROS_USERNAME='username' | |
ROS_PASSWORD='password' | |
USER_AGENT='Mozilla/5.0 (Windows NT 6.1; Win64; x86) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.2483.33 Safari/537.36' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import config | |
from requests.auth import HTTPBasicAuth | |
# Файл с настройками доступа к серверу и т.п. | |
conf = config.Config('config.cfg') | |
data = '"show interface ' + conf['keenetic_interface'] + '"' | |
params = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
domoticz_server = '10.0.0.1' | |
domoticz_port = '80' | |
domoticz_username = 'ivan' | |
domoticz_password = 'pechkin' | |
keenetic_server = 'fs-ns-vfnm-ndj.blablabla.keenetic.pro' | |
keenetic_username = 'api' | |
keenetic_password = 'jjjvjqgfhjkm' | |
keenetic_interface = 'CdcEthernet0' |