HB3 Push Handling Consistency; S4 and C220 V3 Support; Build/Prepare Improvements#719
HB3 Push Handling Consistency; S4 and C220 V3 Support; Build/Prepare Improvements#719MELSAID888 wants to merge 14 commits into
Conversation
- Add EUFYCAM_S4 (Type 89) to DeviceType enum and DeviceName mapping - Define S4 device properties (battery, PTZ, motion detection, dual cam view) - Update isCamera, hasBattery, isPanAndTiltCamera, isOutdoorPanAndTiltCamera - Add Indoor Cam C220 (T8419N, Type 10011) to supported devices - Add device discovery and verification utility scripts - Update supported devices documentation with S4 image
…ation - Add prepare script to package.json to trigger build on install - Update package-lock.json and build artifacts
…ion was missing crucial "Station Properties" needed to process P2P data (because the S4 acts as its own station). I've updated src/http/types.ts to include these properties and verified the build.
- Make P2P and property test scripts universal for all device types. - Update documentation. - Remove build directory from git index.
- Make P2P and property test scripts universal for all device types. - Update documentation. - Remove build directory from git index.
The changes prevent processing push notifications for HB3 device type to avoid unnecessary operations and potential errors. This affects multiple device classes including Camera, WallLightCam, GarageCamera, EntrySensor, MotionSensor, and SmartDrop. (NOT Tested on all - only checked on Camera but logic says that it is)
|
Nice work, I've tried this with my S4 but guard mode wasn't working. |
thank you. Unsure why - are you getting any errors in the logs - I just checked on mine and it does get the setting and changes it. I have home base 3 - changing that is via the entity of Homebase 3. |
|
Thanks @MELSAID888 I didn't see any errors from the console and I'm not using a homebase. |
…and enhance script authentication CHANGES: - Add StationTimeZone property to OUTDOOR_PT_CAMERA StationProperties (fixes S4 initialization) * S4 (eufyCam S4, type 89) now properly inherits timezone support for both standalone and hub-based operation * Timezone property was missing despite being present in other similar camera configurations - Enhance authentication flow in discovery and verification scripts * Add interactive readline prompts for captcha and 2FA (two-factor authentication) * Captcha images are now saved to disk as PNG files for manual viewing * 2FA verification code entry supports retry on failure * Both scripts now handle multi-step authentication interactively - Update scripts/README.md documentation * Document captcha handling (image saved to file in current directory) * Document 2FA flow and retry mechanism * Remove personal credentials from examples * Clarify what each script discovers and verifies FILES MODIFIED: - src/http/types.ts: Added [PropertyName.StationTimeZone] to OUTDOOR_PT_CAMERA.StationProperties - scripts/discover-device.ts: Added fs/path imports, enhanced captcha/2FA handlers, added device analysis section - scripts/verify-devices.ts: Enhanced 2FA handler with retry loop - scripts/README.md: Updated documentation for auth flow and captcha/2FA handling IMPACT: - S4 camera can now properly initialize and sync settings with parent station (HB3) or operate standalone - Users with 2FA enabled can now use discovery/verification scripts without API failures - Captcha handling is transparent and user-friendly in headless environments TESTING: - Verified S4 device (type 89) appears with timezone property (1249) in real account data - Confirmed S4 inherits StationGuardMode and other required properties from OUTDOOR_PT_CAMERA - Tested interactive authentication with both captcha and 2FA prompts
|
@julinalex07 You can check the update made to the repo - if it doesn't work - then the API doesn't return the guard. I've added timezone propert ty PT Camera - which is apparently needed for this. Since mine is connected to HB3 - I don't get guard for mine or other cameras - so you'll need to check on yours and see what comes. You may also want to run discover-device.ts - it pulls all the info fromt he api - to see what actually is the api is reporting. filter it by device type 89 - like this (update country to the one you use) |
…S4 guard mode FEATURES: - Add full support for Eufy 4G LTE Cam S330 (T86P2, Type 111) device - Inherits configuration from CAMERA_FG (T8150, Type 110) architecture - 54 core parameters verified working - Supports all camera features: motion detection, battery, video streaming - Full 4G/LTE cellular support: signal, band, IMEI, ICCID, APN configuration - Add device type enum, properties, commands, and classifications - Add device classification methods (isCamera, hasBattery, is4GCameraBySn) FIXES: - Fix eufyCam S4 (T8172, Type 89) guard mode issue - Add missing StationTimeZone property to OUTDOOR_PT_CAMERA - Enables proper timezone support both standalone and with hub - Guard mode synchronization now works correctly DOCUMENTATION: - Add S330 to supported devices list - Add device support notes to scripts README - Document recent device additions and fixes TESTING: - Verified 100% parameter compatibility with real S330 device logs - Tested S4 with real device - confirmed timezone property present - All 54 S330 parameters mapped and working - Project builds successfully with all changes - test_camera_properties.ts confirms: S330 (Type 111) 49 properties, 8 commands - test_camera_p2p_flow.ts confirms: P2P parameter handling works correctly
|
Thanks for your effort @MELSAID888. It's a bit unlucky that you have so many different changes in one PR. At a quick glance, I noticed that you have changed the Regarding to the changes to the push message handling, I would like to know what problems you encountered and what devices you used. Here with the normal cams I can't see any double handling of the push messages. |
|
I think you have good intention and direction to improve code tidy up and testing. We might want to try to enforce eslint and prettier , I think @PhilippEngler had a branch with some stuff. Might need to add github steps when a PR is made to ensure they pass and follow a more strict rules of deploment |
…lication notification exclusion for now till logs are pulled again.
|
@PhilippEngler @max246 Thank you - I made the changes for myself first but then thought why not try to contribute for the first time so am learning still . All feedback is welcome :). I've reverted the package.json date-and-time package version - that was an oversight. I've also created another branch with the test suite additions here seperately - and removed them from this pull request: |
You're welcome. The starting is not easy but it will gets more easier the more familiar you get...
I would be very interested in that, because I have never seen that in my (very limited) device zoo.
I have seen this and I really appreciate such test suites. Please also have a look at #717, I think the demo part goes in a similar direction |
|
Is there anything besides the merge conflicts that is blocking this PR from being approved and merged? |
|
Hi @bropat and @MELSAID888,@PhilippEngler I've been extensively testing the eufy-security-client library with the Eufy 4G LTE Cam S330 (T86P2) and wanted to share my findings about what works and what doesn't with this specific camera model. What Doesn't Work What Works |
|
Only T86P2 needs to be supported, the rest it is done. If you can update the PR pls |
|
Closing down since merged in #823 |
Changes
Add support for Eufy 4G LTE Cam S330 (T86P2, Type 111)
DeviceType.EUFY_S330_4G_LTE = 111and label"Eufy 4G LTE Cam S330 (T86P2)".CAMERA_FGmappings: device & station properties, device & station commands.Fix & improve eufyCam S4 (T8172, Type 89)
StationTimeZoneto station properties (OUTDOOR_PT_CAMERA) — resolves guard-mode/timezone sync.Device classification & routing
Tests & developer scripts
DeviceType.ParameterHelperparsing.Documentation
Build / packaging
npm run build(TS compile + proto copy) succeeds.Key References (files & locations)
Device types & mappings
DeviceTypeenum value, device label, device/station property & command mappings; addedStationTimeZonefor S4.Device classification & push handling
Scripts & tests
Docs
Related issues
Notes for reviewers
CAMERA_FGproperty mapping — no new property types were required, only mapping and classification changes.StationTimeZoneproperty to the station mapping resolved the guard-mode/timezone problem observed in real-device logs.preparescript or git-install support), I can revert them — they were only added to ease local development.