Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Schedule display
#1
Hello,
is there someone that show me how to use Schedule Display with code example?

Thanks
Reply
#2
Hi,
the "Schedule Display" reads a Json text that contains information about the schedule.
Every time the user changes the schedule the widget sends the schedule as Json to the Variable.
The Virtuino 6 contains a similar widget. This is the tutorial this widget.
In the Arduino side  you have to install a Josn library because you need to convert the Json text to time, days  etc.

https://youtu.be/t4kfmzGrOoU
Reply
#3
Thanks a lot,
but i don't use MQTT Broker, i use WebSocket and i don't know how to send information to schedule widget
Reply
#4
Hi, I have created a video about the widget "Schedule display"
https://youtu.be/P9ij0S0gABs

You can download the arduino code from the description of the video or from here:
https://virtuino.com/downloads/virtuino_...xample.zip
Reply
#5
(07-15-2023, 07:39 PM)iliaslamprou Wrote: Hi, I have created a video about the widget "Schedule display"
https://youtu.be/P9ij0S0gABs

You can download the arduino code from the description of the video or from here:
https://virtuino.com/downloads/virtuino_...xample.zip

It's OK
Thanks
Reply
#6
(07-18-2023, 06:43 AM)marcopc Wrote:
(07-15-2023, 07:39 PM)iliaslamprou Wrote: Hi, I have created a video about the widget "Schedule display"
https://youtu.be/P9ij0S0gABs

You can download the arduino code from the description of the video or from here:
https://virtuino.com/downloads/virtuino_...xample.zip

It's OK
Thanks
Hello
i have tried many, many time your sketch but not work, i received json from schedule widget and stored value in a string scheduleHolder, then when i connect the app nothing happen, esp32 send a command in correct format but the app nothing display.
Where is a mistake?

Hello
i think that i find the problem, i try to explain.
When i send a new schedule i receive a string below
Code:
{
value={"ID":"schedule","date":"Fri 2023-07-21 02:07:05","state":1,"items":[{"D":"1111111","H":8,"M":0,"S":0,"ST":1}]}

Send: {"schedule":"{"ID":"schedule","date":"Fri 2023-07-21 02:07:05","state":1,"items":[{"D":"1111111","H":8,"M":0,"S":0,"ST":1}]}"} // Work
Send: {"scheduleA":"{"ID":"schedule","date":"Fri 2023-07-21 02:07:05","state":1,"items":[{"D":"1111111","H":8,"M":0,"S":0,"ST":1}]}"} // NOT work
}
Well the id schedule what is? is the name of tag variable and is not possible to change(i think) because if i insert two o more schedule widget and i assign tag name different from "schedule" not work.

I have 2 schedule display and i have called scheduleA and scheduleB but nothing work, but when i changed scheduleA in schedule, wow it's work!!!!

If i send value with "ID":"schedule" and tag=schedule it's work, if i send value with "ID":"schedule" with tag=scheduleA not work, but i don't know how change "ID":"schedule".
Reply
#7
Hi,
what do you mean "not work"?
Can you receive the schedule on esp device?
Can you see the received schedule on the serial monitor?
Could you upload the code changes?
Reply
#8
(07-25-2023, 01:43 AM)iliaslamprou Wrote: Hi,
what do you mean "not work"?
Can you receive the schedule on esp device?
Can you see the received schedule on the serial monitor?
Could you upload the code changes?

Hi,
I already tested your sketch called Virtuino_IoT_esp32_schedule_example.ino, i receive the schedule and displayed on serial monitor.
I have created a new project with only one schedule display widget, then i uploaded your sketch on esp32.
When i connect and add a new schedule i received:
Code:
[0] Received: {"schedule":"{"ID":"schedule","date":"Fri 2023-07-28 08:06:27","state":1,"items [{"D":"1111111","H":8,"M":0,"S":0,"ST":1}]}"}

Received: tag=schedule  value={"ID":"schedule","date":"Fri 2023-07-28 08:06:27","state":1,"items":[{"D":"1111111","H":8,"M":0,"S":0,"ST":1}]}

then i disconnect and close the app, when i restart the app and connect esp32 send:

Code:
[0] New client connected - IP: 10.50.50.66
Send: {"schedule":"{"ID":"schedule","date":"Fri 2023-07-28 08:06:27","state":1,"items":[{"D":"1111111","H":8,"M":0,"S":0,"ST":1}]}"}

but the app nothing show on schedule display
Reply
#9
Hi,
I checked it but in the end it ιs a very serious bug and it will require changes to both the application and the ESP code.
I'll include the fix in the next update in a few days.
I will update this discussion when I am ready
Reply
#10
(07-29-2023, 01:58 AM)iliaslamprou Wrote: Hi,
I checked it but in the end it ιs a very serious bug and it will require changes to both the application and the ESP code.
I'll include the fix in the next update in a few days.
I will update this discussion when I am ready

Thanks.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)