-
Notifications
You must be signed in to change notification settings - Fork 2
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
unable to register device using echo #1
Comments
Hey @bamkrs , can you please assist with this issue. |
Hey @DavidHamburg please be Patient. I'll fire up the example on my machine again with newest Oat++ and report back shortly. But as a first try, have you set your IP-Address correclty?
Have you checked your device list in your Alexa app? I've noticed that some times the app tells you "nothing" but the device was silently registered anyhow. |
Thank you for your quick response!
yes, I have changed the IP address and double checked it in the swagger ui. The echo device also seems to call the proper routes from the HueDeviceController. What looks kinda strange is the second call of
No, unfortunately not. |
Hey @DavidHamburg I'll need a bit longer. I've updated my macOS to Big Sur and am unable to receive multicast messages anymore. I'll have to look into this before I can can start working on the actual problem. Sorry for that, I'll try my best tomorrow. |
Sure, there is no rush! |
Hey @DavidHamburg I'm working on the issue and can confirm your problem. It seems that in some unknown update to Alexa there were some silent changes to the discovery process (it seems to be unhappy about some parts of the response). |
Thank you for the hint. It seems that the unique id format has been changed in the last weeks (see bwssytems/ha-bridge#1272). I have updated the uniqueid in example-iot-hue-ssdp/src/db/Database.cpp Line 65 in ce533b6
Many thanks for your fast support! |
Hey @DavidHamburg awesome that you have created an PR! Are you sure that is the issue? I was already looking at the fauxmoESP and other sources and have seen this change. I Implemented it locally but I still have no luck finding new devices. |
Quite sure, I was able to find the devices with alexa several times after removing the "-". Maybe your string is too short? You must have an 0001 at the end of the device id. I have updated the pull request, can you try it again with my changes? Also ensure the port is 80, all others did not work for me. |
Hey @DavidHamburg yes I found the new id scheme and now it works for me, too. |
Sure, you can close my PR. |
Hey @DavidHamburg |
Thank you for the fixes. I have removed the device again from the alexa app and tried to re-register. With the latest commit alexa is not able to find the device again. Maybe the uniqueid (b97febe6d19c7d6e00000000) is too long? |
Thats odd. I double checked that it works on my Echo (Gen2). Maybe the Gen4 has other constraints. oatpp::Object<HueDeviceDto> Database::deserializeToDto(const HueDevice& hueDevice){
auto dto = HueDeviceDto::createShared();
size_t namehash = std::hash<std::string>{}(hueDevice.name->std_str());
char idstr[16] = {0};
snprintf(idstr, 16, "%08zx%04d", namehash & 0xffffffff, hueDevice.id);
dto->uniqueid = idstr;
dto->name = hueDevice.name;
dto->state->bri = hueDevice.bri;
dto->state->on = hueDevice.on;
dto->state->ct = hueDevice.ct;
dto->state->hue = hueDevice.hue;
dto->state->sat = hueDevice.sat;
dto->state->colormode = hueDevice.mode;
return dto;
} This would reduce the length to 12 characters like |
Hi,
I try to connect these example app running on a raspberry pi 3b+ with an echo v4. I can see some M-Search requests and calls in the HueDeviceController, but the echo always tells me that no device has been discovered. Also the alexa app (ios) is not able to find the example app. Do you have any idea?
The text was updated successfully, but these errors were encountered: