Can't get a simple notification to work, help?

I have my Tesla in Hubitat, and can see the state of the charge. I have Notifier setup to notify me when the battery gets low, and it is not working (or I am not getting the notifications, will have to look in the logs actually).
It was on once per day, but I have changed it to once per minute to try and troubleshoot.

Any ideas?
image
Dashboard showing the Tesla state of charge

I have no events in the App Event list, which makes it seem like it's not firing notifications

This is the status of the Charge Tesla Notifer

Should that be %device% ??

image

WOW I am going to feel like an IDIOT if that is what the problem was.
Thank you for that, I just changed it, and will report back.

Another set of eyes never hurts.

1 Like

That didn't work (still no notifications for battery being low)

It seems like it only reports when the threshold is crossed and the once per day or minute setting seems to be for subsequent notification on other devices that day. Did you have this setup when the charge was above 60% and it didn't notify when it went below?

1 Like

I have had this setup for a while and just forgot about it, since it never worked. Made it to work with 7% battery so this reminded me today that I wanted to get it working.

Hi.

I added this one now, I have a battery at 62% now, so let's see if it triggers here. Let you know if it works.
RogerThat

1 Like

Found this, Push Notifications not working and when I follow the steps to push notifications to my phone they work. So it appears to be an APP (notier) not sending the notifications.

Has the level changed at all since you put in the notification? The notification will only go out when the app receives an event, meaning an update to the battery level.

The battery level is still below the threshold. The car is charging now. I can raise the threshold so it's easier to test.

Can you show the edit device page for the device?

Sure can,

(just modified the VIN to hide that, but this is what I see from the edit device page)

Do you have a link to the driver you are using? I am suspecting that the battery level is being sent a string and not a number. That's why the notification app can't read it correctly.

App and driver I got from this post.

Try this....within the driver you will see these lines:

if (data.chargeState) {
        	sendEvent(name: "battery", value: data.chargeState.battery)

try changing it to this:

if (data.chargeState) {
            def batLevel = data.chargeState.battery.toInteger()
        	sendEvent(name: "battery", value: batLevel)

Give that a try and see what it does. I don't have a Tesla to try this with so you'll have to try it for me, unless you want to send me your Tesla. :wink:

1 Like

Thanks, I gave that a try and will see what happens. Going to drive the car in a few hours so will set the notification to be lower than whatever state of charge I have to see if I can get it to trigger and fire a notification.

Oh....one thing you might want to add also:

sendEvent(name: "battery", value: batLevel, unit: "%")

Don't know if that will make a difference but it might. Plus it will look a lot nicer.

2 Likes

Did this as well.
Car is at 51%, notification set for 50% to alert me and about to go for a drive.

image