Node Red + Home Assistant Masterclass 3 - iPhone iOS Notifications with CCTV capture and stream
Vložit
- čas přidán 7. 09. 2024
- In this video I'll show you how to setup node red to send notifications to your phone with custom sounds, voices and CCTV imagery; both still snapshots, and live streams from your cameras.
Really want to show your appreciation? You can always "Buy me a beer"...
www.buymeacoff...
Find all of the JSON, Starting and ending flows here:
homesight.tech/...
Music: www.bensound.com
Video: Free Stock Video Footage by Videezy!
I was puling my hair for a few months just for this... amazing video, thank you
Awesome videos! I’ve had 7 months of headache and frustration before stumbling across your Master class series! Thank you for your time and dedication in sharing this information for aspiring DIY home automation noobs like me. Keep Charging!
Hi, I had the same thing! Was searching for videos to find solutions, but in the end had to work it out by myself in most cases. I’m glad you found them helpful!
Thank you. I was struggling trying to get notifications to my iPhone from Node Red and you cleared it up for me in just a few minutes. Great Job
Easy when you know how! Glad to help!
Hey my family uses iPhone mainly except my dad and I’d Iove to set this up for my dad on his android phone. Thanks for the vid btw
Thanks for watching!
Hassio and nodered are amazing, so easy to use that even people who dont know how to normalize an audio can do things like this
Thank you very much for sharing this well made tutorial with us.
Though I do not use an IOS device, I was able to use you example as a starting point to make the same work on my Android device. Took my quite a few hours, though BOY did it feel good when I got it working :D
Worked without a hitch on the Android cell thank you.
Intensive production here !
Thank you!
Great series, it works perfectly on android as well
Thanks, I'm working on another at the moment.
Another great video! Helped me a lot further. Very nice.😀
really loving this series. Great work.
Thanks Jim!
@@HomeSight how can I create a state that understands if I’m coming home? I’ve created an MQTT speaker and using door sensors to announce door openings and closings. I would like to change the opening tts to a welcome home tts. But can’t figure out how to create a state transition like that.
I have the app (with outside dns) and google wifi.
Hi Jim, yes. You might want to look at life360 and the associated integration. I found it very relive for location tracking for multiple people. Personally I would use it to to set a geofence area around the house, start a flow in node red, but use a wait node to watch for a door open, then play a .mp3 out of my Sonos speakers… does that help? Sounds like a good video actually!
Thank you so much for this! As much as I love Node-RED it has been downright near impossible to find working NR JSON to do stuff like this in Home Assistant Call Service nodes
You’re very welcome! Glad it’s helped!
Great Video - saved me heaps of time -Have you or are doing you one with actionable notifications?
I haven’t yet, but I’ll put it on the list! I’m glad you found it helpful.
That was awesome, massive help, thanks!
You are most welcome!
Nice video! Just one question, would be possible rotate the snapshot by 90 degree?
Love your master classes I am a bit of a newbie is their a tutorial you have done that is using Mqtt and node red to give feedback to my iOS. Once I have done this I’m going to watch your 3D lace videos can’t wait
Thanks Matthew!
I would have loved to test your flow, but I get a error copying and pasting it in Node-Red import: SyntaxError: JSON Parse error: Unrecognized token '“'
What am I doing wrong?
congratulations for the video. How do I add critical: 1 in notifications?
Great Video, however having issue receiving image. just get Failed to load attachment. Response status code was unacceptable: 404. The file isn't showing in the www folder. If i manually put a jpeg file named cam03_snapshot in the folder then it sends ok. Also i had to manually populate the Domain, service and entity in the call service properties. Any idea what could be the issue?
just need to reboot HA and everythings start to work
Very good, thanks.
Great Video! On the Android front, The client does not have the same audio Notification support. I can get the notification text working but no images or video but I think its due to the client..
Hi Bob, thanks for the feedback. I’ll may have to borrow an android phone and see how I get on one day!
How you made and install Home-Assistant mobile app?
My test one looks like it's sending and says sent, however, I never get a notification on my iphone. I have notifications for the companion app enabled in iphone settings
Hi, That's a bit odd. When you entered your device name into the "service" box did it auto populate? It should show something like "mobile_app_YourPhoneName". If you go to Configuration and Integrations, you should see "Mobile App" in there with a your device listed there, can you see that? Have you tried the "IT guy" response and restarted?
@@HomeSight Yes, it auto populated my iphone as well as my wife's until I picked the specific one (mine). If I go to Integration and mobile app I see two of my iphones in there. I did switch to a new iphone recently, however, there is only one of my iphones selected in service box. I think I narrowed down which one is my old phone and deleted it. Rebooting HA now. Both phones had the same name.
That's what it was, I think since I had two iphones in there as the same name it didn't know which one to default to. It now works after removing my old phone. Thank you for your help!
Since you're storing the snapshot using the same file name, does each snapshot overwrite the previous?
Great video, can you point me towards something that solves this one? I am sending a notification via iOS based on a flow where humidity sensor turns on a switch for a bathroom extractor fan. After one hour, if the humidity is still above 70% I get a warning to my phone to see if I need to open a window as the humidity is still high. I have it all working fine except I want the message to include the value from the humidity sensor. How can I do it? I got it working as a HASS automation but want it to be from Node Red instead. Thanks!
Hi, you can add the payload into the message fairly simply. I have shown it in one of my other node red masterclasses, but can’t remember which off the top of my head. From memory it’s a fairly simple case of adding in {{payload}}…
any idea how to limit the notification ? I received to many for the same events
Have you ever tried to capture a 10 second GIF and send it through as a push notification?
I can’t say I have…
Something is missing as I am not hearing any sounds on my phone. Seems we need to do more in the actual Home Assistant App to get this to work. I have never used this feature before and even though Notifications are on for the App in the iOS settings as well as Notifications within the App itself, no sound seems to play that I choose? I am running the latest version of Home Assistant as well as the App on my iPhone.
I assume your phone is not on silent. Do you also have an Apple Watch by any chance?
@@HomeSight ahh yes I have a watch. I’ll have to check if my phone was on silent. Will try again later today... as it’s past the night of mid... what would having a watch do?
If you have a watch and the notifications were coming up on there; that’ll be the reason. To show the sounds I had to turn off notifications for home assistant within the Apple Watch app
@@HomeSight That was it... as well as I had silence switch on... THANKS!!
Android is easy to use, its similar to your setup
Thank you very much for your excellent Node Red videos! For some reason the Morgan Freeman sounds do not work for me. The Swish.caf sound works but when i exchange that with your Morgan Freeman example I get the message but no sound. Is there some sort of activation that is needed to use the bundled sounds? They work ok when I click on them in the HA app.
Hi, thank you. I didn’t have to do anything different, no.
Thanks Simon, really useful to get started in the Node Red world. I have it working perfectly on iPhone but when I copy the node and set IPad as the device I am unable to press on the notification to see either the snapshot or live stream. Any idea what might be different between two? I have checked app settings are same on both. Keep them coming.
Hi, thanks for watching. What generation iPad do you have?
@@HomeSight It is an iPad Pro 11” so a couple of years old?
I’ve just tried it on my iPad to refresh my
Memory. Mine is a 7th Gen iPad running iOS 14. I just pressed and held for a sec and the stream came up...
@@HomeSight strange, I will keep fiddling with the notifications and see if I can solve it, thanks
I solved it, it requires a down swipe on the pop up notification not a long press. Feel a bit silly but I can now move onto next challenge, how to get Tuya smart life controlled bulbs to trigger different colours using HA automations. Also, which video of yours shows RTSP and other format camera set-ups?
Great video series! I learn a lot.
I have a question is there a way to put a sensor value in the notification? I am able to do it via mail, but I get an error if I do the same in the push notification. ("message": msg.payload,)
Put msg.payload in braces like this: {{msg.payload}} or I think you can actually just put {{payload}}. Give it a try! Thanks
@@HomeSight No luck, In the main time I will use a switch node and put a fixed message "Pressure under 0.6B" for example. It will do the trick. And I will search the net if I can find a nicer way.
Export your flow and put it on here, I’ll take a look
Make sure you put the {{payload}} in quotes too. i.e.: "message":"Your pressure is {{payload}}"
For a working example try importing this:
[{"id":"fc3305b1.298938","type":"inject","z":"3e0c8c1c.f98664","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"012345","payloadType":"str","x":110,"y":2560,"wires":[["99a3a2ea.aa9b7"]]},{"id":"99a3a2ea.aa9b7","type":"api-call-service","z":"3e0c8c1c.f98664","name":"Send","server":"22f5da40.d3e236","version":1,"debugenabled":false,"service_domain":"notify","service":"mobile_app_siphone11","entityId":"","data":"{\"title\":\"Sending a Value!\",\"message\":\"Here is your value: {{payload}}.\"}","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":250,"y":2560,"wires":[[]]},{"id":"22f5da40.d3e236","type":"server","name":"Home Assistant","legacy":false,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true}]
@@HomeSight You Rock! My mistake was that I Put "message": {{payload}} instat of "message": "{{payload}}" Now it is working like a charm!
My flow:
[{"id":"37445c76.7a5a74","type":"api-call-service","z":"ed5d4896.735648","name":"Test Notify","server":"61a49d1e.6492a4","version":1,"debugenabled":false,"service_domain":"notify","service":"mobile_app_iphone_nicolas","entityId":"","data":"{\"title\":\"Alarm Low Pressure\",\"message\":\"{{payload}}\",\"data\":{\"subtitle\":\"\"}}","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":1190,"y":420,"wires":[[]]},{"id":"49f6d1ec.12871","type":"inject","z":"ed5d4896.735648","name":"","props":[{"p":"payload.pressure","v":"0.5","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":830,"y":420,"wires":[["1e01ffa2.f8fed"]]},{"id":"1e01ffa2.f8fed","type":"function","z":"ed5d4896.735648","name":"Create Notification","func":"msg ={
payload : \"Low Press at \" + Date().toString() + \", Pressure: \" + msg.payload.pressure ,
topic : \"Low Pressure Chaudière\"
};
return msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":1010,"y":420,"wires":[["37445c76.7a5a74"]]},{"id":"61a49d1e.6492a4","type":"server","name":"Home Assistant","addon":true}]
Hi, What camera do you use for live stream with home assistant integrated? thanks
Hi, the one I’ve shown is a Hikvision IPC-B120
Turn down the intro music. Lol.
Hi John, sorry! It’s sorted on the later videos
I’m happy it was sorted out. I was racing to my stereo to turn the music down. Great videos. Keep them coming nice to be walked through node red.
iPhone meh.
Each to their own...
Bro can you PLEASE normalize your intro audio vs. your voice? I can hardly hear you then the music blasts my ears off.
Sorry Adam! It’s better on the later videos!