bropat / eufy-security-ws

Small server wrapper around eufy-security-client library to access it via a WebSocket.
MIT License
184 stars 29 forks source link

[Bug]: Motion detection/ person detection not working #277

Closed pkarumugam closed 2 months ago

pkarumugam commented 1 year ago

Version

1.7.1

Node version

Docker

Operating System type

Docker

Operating system version

HAOS 11.1 / Eufy Security 7.7.3

Describe the bug

Motion detection and Person detection is always Clear. (No change in status to detected)

To reproduce

  1. Walk in front of the wired doorbell (T8200X)
  2. Go to Logbook or History
  3. Notice that nothing is registered against Doorbell Motion Detected or Doorbell Person Detected (binary sensors)

Screenshots & Logfiles

home-assistant_eufy_security_2023-11-08T01-46-05.507Z.log 402f1039_eufy_security_ws_2023-11-08T01-40-00.924Z.log

Additional context

Screenshot 2023-11-07 205758

See also issue noted with Eufy Security integration https://github.com/fuatakgun/eufy_security/issues/986

manlymgmt-anthony commented 1 year ago

I have the same issue, I don't appear to receive events from my 2C cameras. I need to restart the Add-on for any updates to be received.

pkarumugam commented 1 year ago

In my case, a restart does not solve the problem.  The sensors have never changed even with the numerous version updates.PremSent from my iPadOn Nov 14, 2023, at 3:15 AM, manlymgmt-anthony @.***> wrote: I have the same issue, I don't appear to receive events from my 2C cameras. I need to restart the Add-on for any updates to be received.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

Ascariota commented 12 months ago

Same issue for me I put a restart add on Eufy WS every hour but it's not a real solution

gpbenton commented 10 months ago

+1 using T8222 Door bell.

robinhood-code commented 9 months ago

I have the same issue for all my wired cameras.

Ascariota commented 8 months ago

Any update about this ? Version 1.8 not working also

therealhalifax commented 8 months ago

Same for me. No motion detection at all and some strange stuff in the logs of the addon:

524 ], errorCodes: [ 'ETIMEDOUT', 'ECONNRESET', 'EADDRINUSE', 'ECONNREFUSED', 'EPIPE', 'ENOTFOUND', 'ENETUNREACH', 'EAI_AGAIN' ], maxRetryAfter: undefined, calculateDelay: [Function: calculateDelay], backoffLimit: Infinity, noise: 100 }, localAddress: undefined, method: 'POST', createConnection: undefined, cacheOptions: { shared: undefined, cacheHeuristic: undefined, immutableMinTimeToLive: undefined, ignoreCargoCult: undefined }, https: { alpnProtocols: undefined, rejectUnauthorized: undefined, checkServerIdentity: undefined, certificateAuthority: undefined, key: undefined, certificate: undefined, passphrase: undefined, pfx: undefined, ciphers: undefined, honorCipherOrder: undefined, minVersion: undefined, maxVersion: undefined, signatureAlgorithms: undefined, tlsSessionLifetime: undefined, dhparam: undefined, ecdhCurve: undefined, certificateRevocationLists: undefined }, encoding: undefined, resolveBodyOnly: false, isStream: false, responseType: 'json', url: URL { href: 'https://firebaseinstallations.googleapis.com/v1/projects/batterycam-3250a/installations', origin: 'https://firebaseinstallations.googleapis.com', protocol: 'https:', username: '', password: '', host: 'firebaseinstallations.googleapis.com', hostname: 'firebaseinstallations.googleapis.com', port: '', pathname: '/v1/projects/batterycam-3250a/installations', search: '', searchParams: URLSearchParams {}, hash: '' }, pagination: { transform: [Function: transform], paginate: [Function: paginate], filter: [Function: filter], shouldContinue: [Function: shouldContinue], countLimit: Infinity, backoff: 0, requestLimit: 10000, stackAllItems: false }, setHost: true, maxHeaderSize: undefined, signal: undefined, enableUnixSockets: false } }, message: 'FidRegistrationFailedError: FID registration failed', context: { fid: 'ftCEprWMxxIbVTSO31BJEL' }, stacktrace: 'FidRegistrationFailedError: FID registration failed\n' + ' at PushNotificationService.registerFid (/usr/src/app/node_modules/eufy-security-client/build/push/service.js:136:19)\n' + ' at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n' + ' at async PushNotificationService.createPushCredentials (/usr/src/app/node_modules/eufy-security-client/build/push/service.js:200:16)\n' + ' at async PushNotificationService._open (/usr/src/app/node_modules/eufy-security-client/build/push/service.js:709:32)\n' + ' at async PushNotificationService.open (/usr/src/app/node_modules/eufy-security-client/build/push/service.js:771:13)\n' + ' at async Timeout._onTimeout (/usr/src/app/node_modules/eufy-security-client/build/push/service.js:781:21)' }, credentials: undefined, renew: false } 2024-03-14 15:20:30.562 INFO eufy-security-ws:eufy-security-client [main] Push notification connection closed 2024-03-14 15:20:30.563 ERROR eufy-security-ws:eufy-security-client [push] [PushNotificationService._open] Push notifications are disabled, because the registration failed! { credentials: undefined, renew: false } 2024-03-14 15:20:30.565 INFO eufy-security-ws:eufy-security-client [push] [PushNotificationService.open] Retry to register/login for push notification in 30 seconds...

Neuroquila-n8fall commented 4 months ago

My S330 detects motion but does not yield a persons name. Looking at the app though the person is being recognized. The battery powered cameras work just fine.

So the Data that is being received by the doorbell looks as follows:

{
  "message": {
    "name": "Doorbell",
    "event_time": 1720625450921,
    "type": 91,
    "station_sn": "T8030Pxx",
    "device_sn": "T8213Pxx",
    "push_time": 1720625454531,
    "title": "Eufy Security",
    "content": "Someone has been spotted",
    "channel": 2,
    "cipher": 0,
    "event_session": "20240710_173050",
    "event_type": 3102,
    "file_path": "/media/mmcblk0p1/Camera02//zx/hdd_data1/Camera02/202407/20240710173049/20240710173049.zxvideo.dat",
    "pic_url": "https://security-app-eu.eufylife.com/v1/s/g/REDACTED",
    "push_count": 2,
    "notification_style": 3
  }
}

The cameras however:

{
  "message": {
    "name": "Parking Lot",
    "event_time": 1720625404121,
    "type": 23,
    "station_sn": "T8030Pxxx",
    "device_sn": "T8161Pxxx",
    "push_time": 1720625406721,
    "title": "Eufy Security",
    "content": "Vehicle has been spotted",
    "channel": 0,
    "cipher": 0,
    "event_session": "20240710_173004",
    "event_type": 3107,
    "file_path": "/zx/hdd_data1/Camera00/202407/20240710173000/20240710173000.zxvideo",
    "pic_url": "https://security-app-eu.eufylife.com/v1/s/g/REDACTED",
    "push_count": 1,
    "notification_style": 2,
    "storage_type": 1,
    "msg_type": 18,
    "person_name": null,
    "person_id": null,
    "tfcard_status": null,
    "user_type": null,
    "user_name": null,
    "station_guard_mode": null,
    "station_current_mode": 1,
    "alarm_delay": null,
    "sound_alarm": null
  }
}

Note that it makes no difference if a vehicle, pet or person has been detected. The cameras will always yield the full info block with potential recognized persons but the door bell will never include such information in the push notification.

So the issue is that either the API does not send such information or the data model does not handle it. I also searched for the event id '3111' which is appearing when a person has been identified. The doorbell seems to never appear in the logs with such an event id.