sinricpro / esp8266-esp32-sdk

Library for https://sinric.pro - simple way to connect your device to Alexa, Google Home, SmartThings and cloud
https://sinric.pro
228 stars 121 forks source link

Support lights with effects #148

Closed SamueldaCostaAraujoNunes closed 3 years ago

SamueldaCostaAraujoNunes commented 3 years ago

Hello, I use Sinric Pro, to control an addressable led strip, through the WS2812FX library. I can change the colors, brightness and status without problems, but I would like to switch between the effects through web triggers. I currently use Blynk to control the effects (only sending integer values between 0 ~ 60). However with Sinric and Blynk connected at the same time, the Nodemcu 1.0 card repeatedly loses the connection. I wonder if you want to support lights with effects?

kakopappa commented 3 years ago

Yes. We will release a new feature called "custom devices" somewhere in the coming week. With this, you will be able to create your own LED Strip device and define "effects" that can be control via Alexa.

SamueldaCostaAraujoNunes commented 3 years ago

Thanks!

sivar2311 commented 3 years ago

Preview for such a custom device

image

So, stay tuned for the next big update :)

sivar2311 commented 3 years ago

Custom device feature is now available

I would be pleased to see your device in action :)

SamueldaCostaAraujoNunes commented 3 years ago

Hello @ sivar2311, I love this update! It added a lot of value to Sinric Pro. I already did some tests this morning, I really liked what I saw. I recorded a video, because of the size I preferred to publish it on YouTube: https://youtu.be/ZRydZ0-r9ic . Some doubts arose in my tests, if you prefer I can open separate issues for each one.

1- Is there a call responsible for synchronizing the state of the real device with the cloud data? Something to be done only once, during Setup ();

2- I use a Google Home as a personal assistant. When trying to synchronize my SinricPro devices, my custom device does not appear. I understand that there is a limitation on the part of Google, as it does not support effects. But would it be possible to use the basic functions of the device? and control customized behaviors by Sinric's own App or Website?

3- I have a project ( https://github.com/SamueldaCostaAraujoNunes/ColorWindowsLed ), which captures the standard Windows color, and sends it to my led strip. Today, I use the Blynk API to make requests, I would like to know if SinricPro allows calls to "actions" through an API?

But overall, I loved the update!

sivar2311 commented 3 years ago

This is just the beginning of custom devices - there are a lot of todo's for us - not all part's are finished yet.

Regarding your questions:

  1. Basically SinricPro.restoreDeviceStates() (but this is not yet implemented for custom devices)
  2. When you create a custom template on page one you will see "* Supports only Amazon Alexa. Sinric Pro app, Google Home and SmartThings support coming soon!"
  3. Those data should be sent from your PC to the ESP directly (inside your local network) - makes no sense to me to send it via a cloud service.

Edit: Sorry, I forgot to thank you for sharing the video! Great job!! How many modes did you implement? Looks like 30 to 50? (Very long list :)

SamueldaCostaAraujoNunes commented 3 years ago

In fact, I loved the update! I had understood with the information on the page, that the functions of calling the modes would only be supported by Amazon Alexa, in this case, I understood that Google Home would recognize the devices, but would not be able to handle all the actions! But thanks for the clarification! In relation to sending the data from the PC directly to ESP, I already tried to apply this to the project, but maintaining a WebServer, the library that controls the LED strip and the connection with Sinric, made him lose the connection repeatedly.

I implemented 55 kkk functions

sivar2311 commented 3 years ago

Because you need "realtime" data i would use websocket server. But i dont know if all this can run on a single ESP chip (there are limitations - it's not a powerful PC ;)

SamueldaCostaAraujoNunes commented 3 years ago

exactly why I want to use sinric exclusively!