bessarabov / mac2mqtt

View and control some aspects of macOS computer via MQTT
MIT License
68 stars 23 forks source link

unreliable #18

Open Fernando-Checa opened 1 year ago

Fernando-Checa commented 1 year ago

Hello, I don't know if anyone is having this issue. Here is a list of how mqtt alive property changes when my macmini is on:

21/6/2023, 9:18:17 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive: msg.payload : boolean true 21/6/2023, 9:18:30 node: ISOFF debug 117 mac2mgtt/Mac-mini-de-Fernando/status/alive msg.payload : boolean false 21/6/2023, 9:18:30 node: ISOFF debug 117 mac2mgtt/Mac-mini-de-Fernando/status/alive: msg.payload : boolean true 21/6/2023, 9:19:31 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive: msg.payload : boolean false 21/6/2023, 9:19:31 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive: msg.payload: boolean true

and here a list of when computer is off:

21/6/2023, 9:05:27 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive msg.payload: boolean false 21/6/2023, 9:09:45 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive mga. pavload : boolean true 21/6/2023, 9:11:09 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive msg.payload: boolean false 21/6/2023, 9:15:30 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive msg.payload : boolean true 21/6/2023, 9:15:32 node: ISOFF debug 117 mac2mgtt/Mac-mini-de-Fernando/status/alive msg.payload: boolean false 21/6/2023, 9:15:32 node: ISOFF debug 117 mac2mqtt/Mac-mini-de-Fernando/status/alive msg.payload: boolean true 21/6/2023, 9:16:51 node: ISOFF debug 117 mac2matt/Mac-mini-de-Fernando/status/alive msg.payload: boolean false

I don't know how this is so erratic for me. Any thoughts?

Thanks in advance

Fernando-Checa commented 1 year ago

I guess the computer just wakes up from time to time..

Any way of sending mqtt message only when logged in? Rather than all the time. That way even if the computer wakes up by itself, the user is not logged in so no message is sent.