This is how i start the script from CMD on my windows machine after ssh to RPi2
The first time I started, I wrote like this:
sudo bash monitor.sh -x -b -tdr -u
and now like this:
sudo bash monitor.sh
automation:
- initial_state: 'on'
alias: 'Front door open/closed BT helper atm'
trigger:
- platform: state
entity_id: binary_sensor.pi3_front_door_sensor
to: 'off'
action:
- service: script.scan_bt_depart
- service: script.scan_bt_arrive
im going to split them up to two automatins like your guide. one when i unlock door from inside (depart) and the other when unlocking with tag/code from outside.
EDIT
now i see i have wrong entity in that automation :'D
changing to this for now:
- initial_state: 'on'
alias: 'Front door open/closed BT helper atm'
trigger:
- platform: state
entity_id: lock.dorrlaset
to: 'unlocked'
action:
- service: script.scan_bt_depart
- service: script.scan_bt_arrive
This is just a short version, you should really read up on how to work on ubuntu-like systems that use systemd.
monitor.sh is the file, that does the work. If you setup a monitor.service file, this is the one that is needed to autostart the monitor.sh file, eg. after a restart. This service file is for the OS to know, how to handle this āautostartā. As this service is controlled by the OS, you can enable, disable, start or stop this service.
So after setting up monitor.sh you have to make it autostart. Setup the file monitor.service and check the contents. After that enable the service and you are good to go.
Did you find a app with a -dBm meter? Hold your Tile against your phone while scanning. Then it should get lowest dBm. mMaybe try press the button on the tile to āwake upā i dunno
That app is for android correct? I use apple. The app I use for my iphone, I can see the Tile, but the data info does not show the mac address. Just bunch of useless info I donāt need.
Ok. I finally managed to find the Tile Mate mac address after many failed attempts using various scripts and ios mobile apps by using this Switchbot-MQTT-ESP32 code tweaking it along with the help from its author.
Plug the ESP32 into the pc after uploading the code and using the monitor serial console to look for all scanned devices. You will need to change this line in the code before uploading it.
# find
pScan->start(initialScan, scanEndedCB, true);
# change to
pScan->start(initialScan, scanEndedCB);
It will scan for 300 seconds. If you are lucky, not like me, you should see in the log Tile next to name. That will be the mac you are seeking.
If there is no Tile next to name, compare this UUID as it is from a Tile Mate (removable battery model) non Pro version.
Iām sorry as Iām sure this has been asked already. I use the appdeamon script with monitot but what would be the optimal monitor arguments for a single node that is placed at the front door and a contact sensor
at the front door being the only gateway sensor. We only ever leave/enter through the front door.
I struggle to understand how -tad or -tdr works (especially with 1 node).
My Monitor on my rpi0 suddenly stopped working. I keep getting:
ā[CMD-MQTT] warning: issue connecting to mqtt server (lookup error). enqueuing command to try again after a delayā
ā[CMD-ERRO] fatal mqtt error - messages may not be delivered as intended (issue connecting to mqtt server (lookup error). enqueuing command to try again after a delay / 4)ā.
I am running HA broker add-on with password. I can ping the broker IP.
First of all, thank you so much for building this, I really appreciate it!
Iām having a weird issue where the Pi zeros I have around our house have a much harder time picking up my wifeās phone versus mine. Iāve attached some example graphs so you can see what I mean.
We have identical iPhone 11s, so Iām struggling to see what could be leading to the differenceā¦ I have 4 Pi zeros around the house - they all reflect a similar difference in sensitivity, and it occurs even when weāre sitting next to each other with our phones essentially equidistant from the sensors.
Any idea what could cause her iphone 11 to be so much harder to pick up than mine?
There are a couple things you could do to try and get more detail on this problem. Are the phones paired to the nodes? So you can get a reading of the rssi signal of each phone.
You could also enable the ibeacon in the HA mobile app and see if you get the same result when tracking that.
Got this working today and it seems to solve most of my presence detection problems. Need to distribute this further around the house, but I can already say this is very promising! BIG THANKS @andrewjfreyer and to others who have contributed to this project!