Refer to this post for up to date instructions: Kuna Surveillance Camera Support
@HITChris @TarheelGrad1998 @radiationnow @Corey_Maxim @jlax47 @GuitarSkater
New version of the component is up: v6.
Major feature of this version is two new services: kuna.enable_notifications and kuna.disable_notifications, which you can use to enable or disable notifications for just one camera or all cameras in an account. I also added a couple of device state attributes to the camera.
Timeouts are nothing more than the request to the Kuna APIā¦ timing out. Shouldnāt be a sign of anything bad going on with the component, just that your connection to the Kuna server is a bit flaky.
Iām going to look into this!
@marthocoo - Thanks. I updated by running a git pull
on the custom_components/kuna
folder and restarting HA.
Whatās the point of the new services? Does it change the setting in the app for āReceive Alertsā? I guess itās not clear to me what a notification is in this context.
Also thank you again, this is great!
The services disable/enable whether or not Kuna motion detection will trigger an alert to clients (e.g. the Android Kuna app).
Good work @marthocoo
Can you speak to the specific steps if one is running hassio on the RPi3? Thanks for your help
To install on Hass.io:
- Install the ssh Add-on.
- ssh into the Hass.io system.
cd /config
mkdir custom_components
cd custom_components
git clone https://github.com/marthoc/kuna
- Add the required configuration to configuration.yaml.
- Restart Home Assistant.
- Enjoy!
Iām currently looking into:
- Supporting the actual camera stream in Home Assistant.
- Whether we can create a basic media_player platform for Kuna that would let it function as a tts endpoint in Home Assistant - this will depend on how sound data is sent from the Kuna app to its remote servers, which I still need to investigate.
Other than these features, are there any other features that anyone would like to see as part of this component? Iām trying to get it to be as feature complete as possible before trying to get it incorporated into Home Assistant.
Any chance that you could give me an example of the action to turn on/off these notifications? I would like to append this to and already existing automation. Thanks
Sure thing, hereās a simple automation that turns notifications off on all cameras at sunset:
- alias: Notifications off at sunset - all cameras
trigger:
- platform: sun
event: sunset
action:
- service: kuna.disable_notifications
Hereās another one to turn notifications on for one camera when a device tracker leaves home:
- alias: Notifications on when Mark leaves home
trigger:
- platform: state
entity_id: device_tracker.marks_iphone
from: home
to: not_home
action:
- service: kuna.enable_notifications
data:
serial_number: '0000000000'
To find the serial number, you can either use the Kuna app, or go to the entities page, find the camera entity, and one of the state attributes will be the serial number.
Not sure how it would be represented in HASS, but itād be really nice to be able to interact with recordings - if only to automatically save clips, or do things with clips when certain criteria are met.
im on .88 and I know theres a new structure for custom components
config/custom_components/kuna/ (kuna files)
but Im getting a error in my configuration.yaml
Component not found: kuna
Am I doing something wrong?
I donāt think youāre doing anything wrongā¦ Iām on 88.1 and currently developing on 89dev and the component is working on both. Might be worth deleting the kuna directory in custom_components, restarting HA, then doing a fresh git clone of the kuna repo, then restarting again.
Iāll second the recordings. It would be great to access those that are in the Kuna app and save them off somewhere. Again it gets around their closed system that is really the biggest downside of their product.
If you could get the live stream to show and save into a remote repository (FTP/NAS, etc) would be awesome.
thanks for all the work youve done so far. I will second being able to save the live stream to a remote location or even just the motion events.
Anyone have Kuna block access to the api yet?
@radiationnow @Corey_Maxim @TarheelGrad1998 @GuitarSkater @HITChris @Martso @Nico74350 @jlax47 @DKrics @berniebl
New release uploaded to GitHub. Mostly stuff under the hood (component and underlying library are now completely async), but there is also a new feature that will allow you to automatically download recordings. See the GitHub repo for instructions, and let me know if anything isnāt clear or not working.
As always, update by cdāing into the custom_components/kuna directory and doing git pull
.
Thanks for the notification, very nice of you. Doing a pull now!
Thanks for the update! I will check it out now!
Thanks. Iāve got it up and running now. I changed the automation download to have a folder per camera (folder name is the SN) and the download filename to the label.
- alias: Download Kuna recordings
trigger:
platform: event
event_type: kuna_event
event_data:
category: recording
action:
service: downloader.download_file
data_template:
url: '{{ trigger.event.data.url }}'
subdir: '{{ trigger.event.data.serial_number }}'
filename: '{{ trigger.event.data.label }}'