koush / scrypted

Scrypted is a high performance video integration and automation platform
https://scrypted.app
Other
3.9k stars 237 forks source link

Motion detection stopped working for specific Amcrest camera model #1475

Closed rsieiro closed 1 month ago

rsieiro commented 1 month ago

Describe the bug I'm using Scrypted with two Amcrest cameras. A newer model (IP3M-HX2W) and an older one (IPM-HX1B). Recently (I don't know exactly when) the native motion detector for the older camera stopped working, but just for the older one, it's still working on the newer camera.

To Reproduce Steps to reproduce the behavior:

  1. Open the newer camera inside 'Devices'
  2. Click on 'Events'
  3. All motion detection events are listed as expected
  4. Open the older camera inside 'Devices'
  5. Click on 'Events'
  6. No motion detection events are listed

Expected behavior Motion detection was working fine for both cameras until recently, and it stopped working for one of the cameras only. No hardware/software changes were made except for updating Scrypted as new versions become available. I can confirm that the motion detector for the camera itself is working -- if I enable that "Alarm" log in the Amcrest web interface for the camera, I can see the entries there when motion is detected. Those events are just not reaching Scrypted.

Server (please complete the following information):

Hardware Model (please complete the following information):

Client (please complete the following information, if applicable):

Additional context Not sure if it helps, but I've tried to enable "Debug" console for the camera. Cleared the console right before trying to trigger motion detection. I see the following messages in the Console after moving in front of the camera for a bit:


Headers {
  'cache-control': 'no-cache',
  pragma: 'no-cache',
  expires: 'Thu, 01 Dec 2099 16:00:00 GMT',
  connection: 'Keep-Alive',
  'content-type': 'multipart/x-mixed-replace; boundary=myboundary'
}
listen loop closed, restarting listener.
ignoring dahua http message [
  'Cache-Control: no-cache',
  'Pragma: no-cache',
  'Expires: Thu, 01 Dec 2099 16:00:00 GMT',
  'Connection: Keep-Alive',
  'Content-Type: multipart/x-mixed-replace; boundary=myboundary'
]
expected boundary but found -- myboundary
Headers {
  'cache-control': 'no-cache',
  pragma: 'no-cache',
  expires: 'Thu, 01 Dec 2099 16:00:00 GMT',
  connection: 'Keep-Alive',
  'content-type': 'multipart/x-mixed-replace; boundary=myboundary'
}
listen loop closed, restarting listener.
ignoring dahua http message [
  'Cache-Control: no-cache',
  'Pragma: no-cache',
  'Expires: Thu, 01 Dec 2099 16:00:00 GMT',
  'Connection: Keep-Alive',
  'Content-Type: multipart/x-mixed-replace; boundary=myboundary'
]
expected boundary but found -- myboundary
Headers {
  'cache-control': 'no-cache',
  pragma: 'no-cache',
  expires: 'Thu, 01 Dec 2099 16:00:00 GMT',
  connection: 'Keep-Alive',
  'content-type': 'multipart/x-mixed-replace; boundary=myboundary'
}
listen loop closed, restarting listener.
ignoring dahua http message [
  'Cache-Control: no-cache',
  'Pragma: no-cache',
  'Expires: Thu, 01 Dec 2099 16:00:00 GMT',
  'Connection: Keep-Alive',
  'Content-Type: multipart/x-mixed-replace; boundary=myboundary'
]
expected boundary but found -- myboundary
Headers {
  'cache-control': 'no-cache',
  pragma: 'no-cache',
  expires: 'Thu, 01 Dec 2099 16:00:00 GMT',
  connection: 'Keep-Alive',
  'content-type': 'multipart/x-mixed-replace; boundary=myboundary'
}
listen loop closed, restarting listener.
ignoring dahua http message [
  'Cache-Control: no-cache',
  'Pragma: no-cache',
  'Expires: Thu, 01 Dec 2099 16:00:00 GMT',
  'Connection: Keep-Alive',
  'Content-Type: multipart/x-mixed-replace; boundary=myboundary'
]
expected boundary but found -- myboundary
Headers {
  'cache-control': 'no-cache',
  pragma: 'no-cache',
  expires: 'Thu, 01 Dec 2099 16:00:00 GMT',
  connection: 'Keep-Alive',
  'content-type': 'multipart/x-mixed-replace; boundary=myboundary'
}
listen loop closed, restarting listener.
ignoring dahua http message [
  'Cache-Control: no-cache',
  'Pragma: no-cache',
  'Expires: Thu, 01 Dec 2099 16:00:00 GMT',
  'Connection: Keep-Alive',
  'Content-Type: multipart/x-mixed-replace; boundary=myboundary'
]
expected boundary but found -- myboundary
Headers {
  'cache-control': 'no-cache',
  pragma: 'no-cache',
  expires: 'Thu, 01 Dec 2099 16:00:00 GMT',
  connection: 'Keep-Alive',
  'content-type': 'multipart/x-mixed-replace; boundary=myboundary'
}
listen loop closed, restarting listener.
ignoring dahua http message [
  'Cache-Control: no-cache',
  'Pragma: no-cache',
  'Expires: Thu, 01 Dec 2099 16:00:00 GMT',
  'Connection: Keep-Alive',
  'Content-Type: multipart/x-mixed-replace; boundary=myboundary'
]```
koush commented 1 month ago

thanks, I can fix this

rsieiro commented 1 month ago

That's awesome! Thank you so much