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

Alexa Presets not workong #4204

Open
1 task done
nmeliasp opened this issue Oct 18, 2024 · 30 comments
Open
1 task done

Alexa Presets not workong #4204

nmeliasp opened this issue Oct 18, 2024 · 30 comments
Labels
enhancement fixed in source This issue is unsolved in the latest release but fixed in master help wanted

Comments

@nmeliasp
Copy link

What happened?

When adding WLED to Alexa, presets are making it into Alexa

To Reproduce Bug

When configuring Alexa voice assistant in sync interfaces and configure 1 or more presets, nothing makes it into Alexa.

Expected Behavior

All presets appear as lights in Alexa and can be toggled to turn on and off

Install Method

Binary from WLED.me

What version of WLED?

0.15.0-b6

Which microcontroller/board are you seeing the problem on?

ESP8266

Relevant log/trace output

No response

Anything else?

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@dosipod
Copy link
Contributor

dosipod commented Oct 18, 2024

After testing with you in discord I could see this issue with the presets as far back as 0.14.2-b2 build . Since I have saved a pic of older setups testing on 0.14.2-b2 which showed the presets working correctly I am thinking that could be related to Alexa updates.

The below is old picture but when i tested now on 0.14.2-b2 i faced the issue with presets
image

Please test on 0.14.2-b2 to see if that is also broken on ESP8266 ( this should not work in theory so just to confirm )

@dosipod
Copy link
Contributor

dosipod commented Oct 18, 2024

I could not track the Alexa updates and only found a list deprecated features last was on July 2024 for the List API ( this impacted others like HA )
https://developer.amazon.com/en-US/docs/alexa/ask-overviews/deprecated-features.html
Not really sure any is used by wled Alexa code or any of the dependencies .

Might be contacting Alexa Developer Support is an option but I am not the right person to do that :)

@dosipod
Copy link
Contributor

dosipod commented Oct 18, 2024

Found undocumented build flag that would do Alexa debug ( -D ESPALEXA_DEBUG ) and I could see some errors when trying to add the light to Alexa not sure that was there as I only used it now but I think at this point it might be related to the same list of deprecated apis or other updates that might need a wled code update to match or other workaround

[18:57:58]Not-Found HTTP call: /api/2BLEDHardQrI3WHYTHoMcXHgEspsM8ZZRpSKtBGr/lights/1275707904
[18:57:58]application/json
[18:57:58]FinalBody:
[18:57:58]URL: /api/2BLEDHardQrI3WHYTHoMcXHgEspsM8ZZRpSKtBGr/lights/1275707904
[18:57:58]AlexaApiCall
[18:57:58]ok
[18:57:58]l1275707904
[18:57:58]1275707904
[18:57:58]Not-Found HTTP call: /api/2BLEDHardQrI3WHYTHoMcXHgEspsM8ZZRpSKtBGr/lights/1275707904
[18:57:58]application/json
[18:57:58]FinalBody:
[18:57:58]URL: /api/2BLEDHardQrI3WHYTHoMcXHgEspsM8ZZRpSKtBGr/lights/1275707904
[18:57:58]AlexaApiCall
[18:57:58]ok
[18:57:58]l1275707904
[18:57:58]1275707904
[18:57:58]Not-Found HTTP call: /api/2BLEDHardQrI3WHYTHoMcXHgEspsM8ZZRpSKtBGr/lights/1275707904
[18:57:58]application/json
[18:57:58]FinalBody:

@nmeliasp
Copy link
Author

i have confirmed the same behavior on 0.14.2-b2 with my ESP8266. Where do we go from here?

@dosipod
Copy link
Contributor

dosipod commented Oct 18, 2024

WLED Alexa related coding was only done by AC who maybe busy with other things at the moment ,
Since your issue is still open then you would have to wait as this might be a minor issue .
I do not use Alexa with wled personally so I am just helping log the details with you but have no real interest in the outcome other then reporting bugs details in a manner that may help others to fix it , cheers

@dosipod
Copy link
Contributor

dosipod commented Oct 19, 2024

image
This was reported a long time ago , i will try to fix that
Unfortunately the log error might be just because of the use of static username ( hard-coded in Espalexa.h) and that is just a strange coincidence that the word "LEDHARD" is used in the api call . I could use another Alexa which I will try to borrow from a friend to do more destructive testing

@Svennte
Copy link
Contributor

Svennte commented Oct 22, 2024

Had the same problem.
I just created a pull request that should solve this issue.

Edit: This is the pull request: #4214

@nmeliasp
Copy link
Author

Awesome! Looking forward to the fix.. As a side note I was able to get around this by exposing scenes I created in home assistant to Alexa but still looking forward to this fix

@dosipod
Copy link
Contributor

dosipod commented Oct 22, 2024

@nmeliasp Yes it is working and I can see the expected behavior with presets

image

Change based on 0.15.0-b6 and bins are here
https://github.com/dosipod/WLED_alexa_Oct_2024_ps_fix/actions/runs/11456536731
Please try it out on esp8266

@Svennte Thank you , can you re-base the PR on 0.15.0-b6 as I did in above repo

@Svennte
Copy link
Contributor

Svennte commented Oct 22, 2024

@dosipod
You mean rebase to 0_15 and add the Version tag, right?
Sorry, relatively new to GitHub features.
Will test on esp8266 later. Esp32 worked fine with Echo 4, Echo dot 5 and the new echo spot.

@dosipod
Copy link
Contributor

dosipod commented Oct 22, 2024

@Svennte Sure , all I did is import 15 and copy the change to Espalexa.h here https://github.com/dosipod/WLED_alexa_Oct_2024_ps_fix/commit/6a8ae07a0fdc7f40cc7e1e7e44bc5e37dab407a7 , if you also enable github action then PlatformIO CI will auto generate the bins

@Norm71
Copy link

Norm71 commented Nov 13, 2024

I installed the latest Binary (0.15.0-b7) but Alexa still not recognizing the presets.

@Svennte
Copy link
Contributor

Svennte commented Nov 13, 2024

You sure you activated it in the Sync Settings?
Working flawlessly for me, even in Alexa routines.

@Norm71
Copy link

Norm71 commented Nov 13, 2024

image
image

Worked until Alexa was updated 2 weeks ago. Updated to the new version but Presets do not appear on Alexa.
I do have 4 Presets defined:
image

In Alexa i do find one Device called "Arbeit" (preset 4) but if look into the details its calle "Ambiente" (preset 3)

@Norm71
Copy link

Norm71 commented Nov 13, 2024

20241113_125157000_iOS

20241113_125204000_iOS

@Svennte
Copy link
Contributor

Svennte commented Nov 14, 2024

Working just fine for me. Did you try delete all Devices from the Alexa app and then rediscover?

Screenshot_2024-11-14-12-09-40-206_com aircoookie WLED-edit
IMG_20241114_121222
IMG_20241114_121303

Edit: Meant delete all WLED Devices, not all devices in general.

@Norm71
Copy link

Norm71 commented Nov 14, 2024

Yes i did delete the devices and only the one is coming back all the time

@Svennte
Copy link
Contributor

Svennte commented Nov 14, 2024

And why do you setup 5 presets when you only have four? Maybe this is the confusing thing for Alexa

@Norm71
Copy link

Norm71 commented Nov 14, 2024

It was just a test and its back to 4

@Norm71
Copy link

Norm71 commented Nov 14, 2024

I currently try the following:
Disable sync in WLED
Reboot WLED
Delete devices in Alexa (currenty did 15 times but it still appears)

@Svennte
Copy link
Contributor

Svennte commented Nov 14, 2024

Sorry, maybe a dumb question, but did you also look under Device settings in Alexa and if they appear there?

@Norm71
Copy link

Norm71 commented Nov 14, 2024

Now for the first time the device is called "Arbeitsplatte" as defined.
Will enable synch now again

@Norm71
Copy link

Norm71 commented Nov 14, 2024

Nothing changed. :(
Devices appear also not in Device Settings

@Svennte
Copy link
Contributor

Svennte commented Nov 14, 2024

Do you have other WLED devices, that may inferences with this one? Like Wled Küche?
Maybe the code won't work with multiple devices the way its structured right now and some things have to be changed for it

@Norm71
Copy link

Norm71 commented Nov 14, 2024

WLEDKueche is the same device but from Home Assistant. This was the same all the time.
Do have one other WLED which does not have Segments and the Alexa Synch is off for that device.

@Norm71
Copy link

Norm71 commented Nov 14, 2024

If i want to trace the call with Wireshark to get the information how the call to Alexa looks like what do i need to lokk for?
I disabled the publish to Alexa in Home Assistant but its still enabled in WLED and now there is coming NO device to Alexa

@ChristianBracket
Copy link

Having the same issue… I’ve tried deleting them, remaking them, rebooting the ESP 32 board, and manually resetting the board. However, every time I search for devices in the Alexa app, it only finds one device. The name is always random. It’s either one of the presets or the name of the device. I’ve tried and tested, but it only works with the one preset or name of the device. When deleting them from the Alexa app, it will be gone and reappear with another random preset name. It will cycle through this until I’ve deleted every single preset. It used to import as separate devices, but this is weird. Any fix?

IMG_0587

IMG_0585
IMG_0586

@Svennte
Copy link
Contributor

Svennte commented Nov 19, 2024

@ChristianBracket you have version v14.04
Is it already fixed there? Sounds exactly like the problem before the update.

@ChristianBracket
Copy link

ChristianBracket commented Nov 19, 2024

I don’t know if this is just the problem I’m having. Here’s a video to show it better. It sucks cause it was working about a year ago when I installed lights in my own room, but not now that I’m trying it in my brother’s…
https://github.com/user-attachments/assets/93fb18ad-0d22-4cfd-9611-c1b6ab646f89

@Svennte
Copy link
Contributor

Svennte commented Nov 19, 2024

Please do the update first. You are using an old version which is not working anymore for amazon alexa.
Get the latest version of v15 and you should be fine.

@softhack007 softhack007 added the fixed in source This issue is unsolved in the latest release but fixed in master label Dec 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement fixed in source This issue is unsolved in the latest release but fixed in master help wanted
Projects
None yet
Development

No branches or pull requests

7 participants