Sunset/sunrise scenes triggering at wrong times (wrong time zone?)

I created 2 scenes meant to be triggered at sunrise and sunset, to auto-switch between Home and Night modes. The switching seems to work, but the times they get triggered are completely off. Sunrise got triggered at 3am and sunset at 4pm. These are not quite right for California.

Is there some setting I have to update to get that right? Location service is enabled in the app.

Which controller are you using?

Hello @mrbro,
There is a reported issue about the Ezlo controllers not setting up the correct location even if provided during the setup process, which is necessary for the controller to use sunset/sunrise scenes.
In the VeraMobile app, please go to “Settings” → “Unit Settings” → “Location” → make sure the location information is correct.
If the scenes continue to misbehave, please let us know.

Ezlo Plus, app is iOS.

Hi Oscar, I checked that and both timezone and location are correct.

Btw, if I may make a small suggestion, “Units and Location” would be more fitting for these settings :grinning:

Hello @mrbro

We’ve created a support ticket for further investigation.

Please check your email.

The issue has been solved by assigning the correct latitude and longitude to the controller.

In order to avoid this misconfiguration, it’s important to grant all access permissions to the phone’s location for the mobile app during the setup process.

1 Like

A couple of questions about the solution you listed:

  1. how does the latitude and longitude get updated?
  2. Why have a selection for the time zone in the setup if it is going to be ignored?

Just a guess here, but perhaps timezone is used only to determine current time, while sunrise/sunset time is calculated based on latitude/longitude? So the current time is correct (timezone), but because lat/lon are off, it thinks sunrise is at 7:12am when in fact it is not until 10:21AM? Just a thought :man_shrugging:

Edit: just to illustrate why I would think this, Juneau, AK and King Cove, AK are both in the same timezone (Alaska). However, sunrise in Juneau, AK this morning is at 8:30AM, while in King Cove it isn’t until 10:03 - so just using the timezone to determine sunrise/sunset time would be wildly inaccurate :slight_smile:

It’s not ignored, I used sunset/sunrise in Meshbots to drive various Christmas decorations this years. Worked okay for me!

1 Like

That’s a good point. I believe that China is all one time zone.

So how do you update the latitude and longitude?

Hello @adams2000,
You can change the latitude and longitude by changing the location on the VeraMobile app under “Settings” → “Unit settings” → “Location”. You can also send the call below with the right coordinates on the API tool.

{
    "id": "_ID_",
    "jsonrpc": "2.0",
    "method": "hub.coordinates.set",
    "params": {
          "latitude" :  49.9808100,
          "longitude" : 36.2527200
     }
}

Kind regards!

1 Like

I have an ezlo plus, I just got it 4/3/23 and the sunrise sunset isn’t working for me either. Worked fine on my Vera secure.

Where do you run this code snippet?

Hello @RonnieBoyOK ,
That code snippet runs in the API tool, you can access it by clicking on Ezlo API Tool then you must login with your credentials > select the controller > click connect > under “commands” select “custom” > paste the API call in the blank.
Please give it a try and let us know how it goes!

So here is what I found out. If you have problems with sunrise/set then use the map and enter your address using the map. Do NOT just type it in. Using the map gets everything set right.

1 Like

Ah ha! I had the same issue on my new Ezlo. Going to the Vera app and using the map to find my address worked. Even though I set the time to America/Denver yesterday, it still turned on 2 hours early, guessing it was using EST still.

Thank you for this tip, worked like a charm!