Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Support devices without station #5

Closed
elo79 opened this issue Nov 1, 2020 · 53 comments
Closed

Feature request: Support devices without station #5

elo79 opened this issue Nov 1, 2020 · 53 comments
Assignees
Labels
enhancement New feature or request work in progress Working on it

Comments

@elo79
Copy link

elo79 commented Nov 1, 2020

Hi, thanks for your great work. I´m really looking forward for this adapter.
I own the wired doorbell: https://www.eufylife.com/products/variant/video-doorbell-2k-wired/T82001J1
and the indoor dome camera: https://www.eufylife.com/products/variant/indoor-cam-2k-pan-and-tilt/T8410121
I don´t have a homebase as theese devices don´t need one, which was the main reason I bought them.

Both devices show up with their attributes.
However there´s no option to change the guard mode or any other functionality.

Is this becuase of the missing homebase?

If you need any logs I´m happy to support you.

Best,
Bjoern

@bropat
Copy link
Owner

bropat commented Nov 2, 2020

Hi elo79,

the change of guard mode is only supported with a homebase at the moment.
Currently i'm working on the push notification integration needed by 2FA and for event notification (movement detection etc.).
Once this is complete, I can continue with other integrations. :)

@bropat bropat added the enhancement New feature or request label Nov 2, 2020
@bropat bropat self-assigned this Nov 2, 2020
@bropat
Copy link
Owner

bropat commented Nov 16, 2020

@elo79 Can you send me some debug logs to understand what the difference is between with station and without?

Thanks!

@elo79
Copy link
Author

elo79 commented Nov 17, 2020

Sure, I sent you the logs via E-Mail.

@bropat
Copy link
Owner

bropat commented Nov 21, 2020

Hi,

could you test the new released version (0.0.3) and tell me if there are any improvements?

Thanks!

@bropat
Copy link
Owner

bropat commented Dec 13, 2020

@elo79 Can you test the last version (0.0.8) and tell me if there are any improvements?

Thanks!

@bropat
Copy link
Owner

bropat commented Dec 14, 2020

@elo79 i would now implement support for devices without a station. But I need your help with that. Please let me know if you would be available. :)

@bropat bropat changed the title Eufy T8200 & T8410 working Feature request: Support devices without station Dec 14, 2020
@FuzzyMistborn
Copy link

I'm testing this myself and I can't update the guard mode or have the mode status updated when I change it in the app. Running the latest version (FYI I am a ioBroker newb, just trying this out)

@bropat
Copy link
Owner

bropat commented Dec 16, 2020

@FuzzyMistborn From what I have seen so far, when changing the Guard mode without a station, this is done via the HTTP interface and not the P2P interface.
I am trying to understand how to best understand when to use which interface. Changing the guard mode via the HTTP interface is relatively clear to me how it is done.
Updating the status of guard mode without a station is done by querying the HTTP interface every x minutes (default setting: 10 min.) or, if you have enabled push notification in the app, via it.

If you want to help me, please enable the debug mode of the adapter and test changing the guard mode. After that please send me the logs (attention: the logs contain sensitive data).

Any help is welcome :)

@FuzzyMistborn
Copy link

Gotcha, I upped the polling to 5 minutes and it picked up the change from the app. I'll get you a log later for changing from ioBroker.

@bropat
Copy link
Owner

bropat commented Dec 16, 2020

@FuzzyMistborn In the meantime I had an idea how to implement the change of guard mode in a transparent way also for devices without station (in fact they are a station themselves).
I think to release in the next days a new version with this support.

@bropat bropat added the work in progress Working on it label Dec 16, 2020
@FuzzyMistborn
Copy link

Ok logs sent via email.

bropat pushed a commit that referenced this issue Dec 22, 2020
* Little progress for feature request: [#5](#5)
* Implemented set Guard Mode with CMD_SET_PAYLOAD for certain devices
* Added back USA ip addresses for P2P cloud discovery
* Using the correct local time zone for communication with the Eufy Cloud
* HUB filtering by device type 0 (station) removed
* Added documentation for 2FA
* Updated versions of the package dependencies
bropat pushed a commit that referenced this issue Dec 22, 2020
* Little progress for feature request: #5
* Implemented set Guard Mode with CMD_SET_PAYLOAD for certain devices
* Added back USA ip addresses for P2P cloud discovery
* Using the correct local time zone for communication with the Eufy Cloud
* HUB filtering by device type 0 (station) removed
* Added documentation for 2FA
* Updated versions of the package dependencies
@TechBrain64
Copy link

@bropat,
If you're needing some else to test code for T8200 doorbell, let me know. I've recently installed it and looking to integrate into HA.

@bropat
Copy link
Owner

bropat commented Dec 27, 2020

@TechBrain64
Since I don't have a doorbell, I need someone to do some testing, but also someone to invite me to their eufy security account as a "test person" for a few hours so I can track the original app's communication. Without this, it will take much longer to implement a good integration.
Let me know if you would be willing to do this :)

@TechBrain64
Copy link

@bropat

As stated I'm willing to help out, but being very security conscious as I am my help will have to come from your first option. Now I should clarify my config, due to the fact Eufy doesn't proxy the mobile app connection back to the doorbell, but rather expects users to allow any ip/port range into their network; I currently cannot use the app outside my network. I don't use their cloud storage (all managed/viewed locally only).

@bropat
Copy link
Owner

bropat commented Dec 28, 2020

@TechBrain64
I understand, you're welcome.
Please test the new version 0.0.9 in debug mode and then send me the logs after you have tested as much as possible on the doorbell (Attention: the logs contain sensitive data).

@FuzzyMistborn
Copy link

0.0.9 seems to be working to change guard mode from inside iobroker.

@TechBrain64
Copy link

How do I go about installing your code?

@FuzzyMistborn
Copy link

I'm not seeing motion events get detected though. Not sure if that's a separate issue.

@TechBrain64 install iobroker via docker. I installed this repo via the command line by using docker exec -it but i'm sure there are other ways (not very knowledgeable with all things iobroker).

@TechBrain64
Copy link

Thanks @FuzzyMistborn, I did see in the HA post someone mentioned docker. I've installed Ubuntu VM with docker and Portainer; which is up and running. But now I'm trying to figure out how to get ioBroker.eufy-security deployed. I'm trying to find the right path/entry point to pull in the container.

@FuzzyMistborn
Copy link

You can't deploy this repo independently. You need to run the iobroker docker container itself. Here is my docker-compose section for iobroker:

  iobroker:
    image: buanet/iobroker:latest
    container_name: iobroker
    ports:
      - "8081:8081" #Main
      - "8082:8082" # Web Interface
      - "8087:8087" # Rest API
    volumes:
      - /home/fuzzy/docker/iobroker:/opt/iobroker
    environment:
      - LANGUAGE="en_US:en"
    restart: always

@TechBrain64
Copy link

@FuzzyMistborn, why is your composer pulling the container from "buanet/iobroker:latest" instead of @bropat?

@FuzzyMistborn
Copy link

Because this isn't a docker container. It's an adapter/integration that runs via ioBroker. So first you need to install ioBroker, and the docker image to do that is buanet/iobroker:latest

@TechBrain64
Copy link

Alright, I have it running and can access with web interface. What now?

@FuzzyMistborn
Copy link

See the HASS Community forum page, I wrote up a blog post explaining what to do.

@bropat bropat added this to To do in Eufy Security Dec 29, 2020
@bropat bropat moved this from To do to In progress in Eufy Security Dec 29, 2020
@TechBrain64
Copy link

TechBrain64 commented Dec 29, 2020

@FuzzyMistborn,

I have the eufy.security adapter configured, but getting syntax errors for your blog examples; in particular the one for guard mode. I am however able to get the last picture event image, but it doesn't change.

What is the correct syntax and file these belong in?

Also, I wonder if these environment settings of the iobroker container may have some impact. I'm in the US and CST timezone.

LANG | de_DE.UTF-8
LC_ALL | de_DE.UTF-8
TZ | Europe/Berlin

@FuzzyMistborn
Copy link

Can you head over to the HASS forum to continue this? I'd rather not be filling up an issue thread with support on an unrelated issue.

@TechBrain64
Copy link

@bropat ,

Thought I'd share some observations I've found about the Eufy App/Camera workflow.

  • The camera reports the users internet IP address to Eufy cloud.
  • Launching the app initiates a call directly to reported internet IP address.
  • All app interactions appear to follow this same general flow (App --> Internet IP --> Local Camera IP --> Cloud)

@bropat
Copy link
Owner

bropat commented Dec 31, 2020

@TechBrain64
Thanks for the logs. This allowed me to fix some bugs, including fixing support for the doorbell push notifications. :)

@FuzzyMistborn
Could you please install the adapter version from develop branch and check if the doorbell push notifications work now?
To install the adapter version from the develop branch follow this guide.

@FuzzyMistborn
Copy link

Nope still no luck on the doorbell press.

Also not sure if you saw this: https://github.com/matijse/eufy-ha-mqtt-bridge . Might be useful?

@bropat
Copy link
Owner

bropat commented Dec 31, 2020

@FuzzyMistborn
eufy-ha-mqtt-bridge it's based on eufy-node-client, where I'm collaborating ;). At the moment my work is more advanced than eufy-node-client, because I don't have the time to continue both.

Can you send me the logs to identify the issue?

@bropat
Copy link
Owner

bropat commented Dec 31, 2020

@FuzzyMistborn
I think i found the issue. Try the last develop version :)

@FuzzyMistborn
Copy link

Bingo. Haven't had a chance to test motion but doorbell press worked.

@bropat
Copy link
Owner

bropat commented Dec 31, 2020

@FuzzyMistborn

I have revised push notification to properly support wired and battery doorbell notifications. Further it's saves the picture locally with state last_captured_pic_url / last_captured_pic_html.
Can you verify if there are no regressions? :)`
When you have time could you check out the other events as well?

Thanks!

@FuzzyMistborn
Copy link

Doorbell ring still works.
Didn't get a "motion_detected" event, but "person detected" went to "true" (and is now stuck at true).
No image located in "last_captured"

@bropat
Copy link
Owner

bropat commented Jan 2, 2021

@FuzzyMistborn

Doorbell ring still works.

That's good :)

Didn't get a "motion_detected" event, but "person detected" went to "true" (and is now stuck at true).

motion_detected is only triggered if no person_detected is triggered. Same as in the Eufy app (taken from the source code of the app). It shouldn't stuck, but reset itself after x seconds (configurable parameter in the adapter => Time in seconds before event reset; Default: 15 seconds).

No image located in "last_captured"

It depends on whether Eufy sends pic_url with a value in the push notification or not. ;) In this case, probably not. But I can understand it through the debug logs if you send them to me.

@Solilord
Copy link

Solilord commented Jan 2, 2021

Hey. Luckily i read through the open issues.
Ive also got an 2K Pan-Tilt and installed your adapter.

The camera is recognized and all states work EXCEPT livestream and event pics.
Unfortunately the impotant ones :D

If i can also help you with that just let me know :)

@FuzzyMistborn
Copy link

motion_detected is only triggered if no person_detected is triggered. Same as in the Eufy app (taken from the source code of the app). It shouldn't stuck, but reset itself after x seconds (configurable parameter in the adapter => Time in seconds before event reset; Default: 15 seconds).

Well that makes sense, except that my "person detected" has been "true" for 3 days 😆

@PrayerfulDrop
Copy link

Any update when the pan/tilt camera's guard/current mode code will be merged? I am currently on 0.1.3.

@bropat
Copy link
Owner

bropat commented Jan 4, 2021

@FuzzyMistborn

except that my "person detected" has been "true" for 3 days 😆

That's strange... Is it possible that you restarted the adapter after receiving the event? I ask because the event is reset after X seconds (adjustable in the settings; default: 15 seconds) and if within this time interval the adapter is restarted, then I can imagine this misbehavior.

@bropat
Copy link
Owner

bropat commented Jan 4, 2021

@PrayerfulDrop

I don't have a pan/tilt camera, so I can't integrate it without help.
If you want to help, please enable the debug mode of the adapter and send me the logs after you tried to change the guard mode.
Or maybe the Guard mode is not shown to you at all because this camera is not detected as a station? Unfortunately, I can only understand this on the basis of the debug logs...

Let me know.

@FuzzyMistborn
Copy link

That's strange... Is it possible that you restarted the adapter after receiving the event? I ask because the event is reset after X seconds (adjustable in the settings; default: 15 seconds) and if within this time interval the adapter is restarted, then I can imagine this misbehavior.

Possibly. How would I fix if I did? I've tried restarting ioBroker without luck.

Also @PrayerfulDrop changing guard mode with my pan/tilt just fine.

@PrayerfulDrop
Copy link

That's strange... Is it possible that you restarted the adapter after receiving the event? I ask because the event is reset after X seconds (adjustable in the settings; default: 15 seconds) and if within this time interval the adapter is restarted, then I can imagine this misbehavior.

Possibly. How would I fix if I did? I've tried restarting ioBroker without luck.

Also @PrayerfulDrop changing guard mode with my pan/tilt just fine.

How are you enabling this? What version of the adapter? I try to change it and it isn’t recognized.

@FuzzyMistborn
Copy link

How are you enabling this? What version of the adapter? I try to change it and it isn’t recognized.

Latest version of the adapter. And nothing special, it should just work. If it doesn't there's a bug and you need to provide some logs to figure out what's going on.

@bropat
Copy link
Owner

bropat commented Jan 5, 2021

@FuzzyMistborn

Possibly. How would I fix if I did? I've tried restarting ioBroker without luck.

A corrected version (0.1.4) has now been released. :)

@FuzzyMistborn
Copy link

Well we're not showing "true" anymore so progress! Will report back once I get some motion events.

@DieguitoCigala
Copy link

If you want I can share my logs with you. I have a 2K Pan-Tilt camera.

@bropat
Copy link
Owner

bropat commented Jan 27, 2021

Hi @DieguitoCigala,

gladly, once I get around to integrating the 2K pan-tilt camera, I'll get back to you on that :).

@DieguitoCigala
Copy link

Hi @DieguitoCigala,

gladly, once I get around to integrating the 2K pan-tilt camera, I'll get back to you on that :).

Perfect. Whenever you want

@alexispattein
Copy link

Same here got 2, pan and tilt so if you need logs in debug let me know.

As per my experience so far it s coming pretty good.
My issue at the moment is regarding sync/latencies, of the motion / person / pet / sound detectors status. I receive proper notification from the eufy app 'motion detected'' but ioBroker stay flat nothing changes. If i deactivate/reactivate the cam from the eufy app the motion status then properly change...

any ideas ? what are the correct settings in the adapter config ?

i have the following: 5 pulling / 30sec before reset

cheers for this great work

@bropat
Copy link
Owner

bropat commented Feb 1, 2021

Hi @alexispattein ,

there should be no latency problem between the eufy app and the adapter, as the latter receives the same push notifications. Unless there is a bug ;)
Can you please send me the debug logs (you can find my mail under license on the main page of the Github project.)? So I can have a look.

Regarding the 2K pan-tilt camera, the same applies as I wrote to DieguitoCigala. :)

@bropat bropat closed this as completed Mar 14, 2021
Eufy Security automation moved this from In progress to Done Mar 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request work in progress Working on it
Projects
Development

No branches or pull requests

8 participants