We have an extensive library of various bOS configuration examples. Select your heating pump, AC, TV or almost any other device and import it to your smart building configuration. We also encourage all system integrators and DIYs to add their own examples to ComfortClick library.
Recive Event informations from an iCal Web-Calendar
This example shows how to get Calendar information from an iCal Web Calendar like the Google Calendar into bOS. This example also shows in general how to build an simple API in Node-RED to get any information from Node-RED into bOS.
To use this example Node-RED Server needs to be running and running bOS server. Furthermore you need a link to your iCal Calendar like this Google Calendar link. https://calendar.google.com/calendar/ical/yyyyyyyyyyyyyyyyyyyyyyyyyy%40group.calendar.google.com/private-xxxxxxxxxxxxxxxxxxxxx/basic.ics.
The Calendar.bos contains a implied bOS Backup. We only need the Calendar device (based on the HTTP Driver) and some Color Templates.
With these Colors you can change the look of the Frames to your project.
As seen on Picture 3 and Picture 4 we have to change the number of the Cfg_DayNum for all Days. If you need the events from more than five day you can copy an existing Day, renamed it and set the Cfg_DayNum.
Cfg_DayNum = 0 -> is today
Cfg_DayNum = 1 -> is tomorrow
Cfg_DayNum = 2 -> is day after tomorrow
and so on.
This allows you to change the requested day at runtime. For Example you can display the next week.
Setup the Node-RED IP Address and Port
This can be found in the browser address line
Imput the Cfg_UpdateEvetnEndpoind = UpdateEvetns. And setup the Cfg_CalNum to 1.
This is used by the "UpdateDay" Command for each day. If you want to use more than one Calendar please count Cfg_CalNum to 2,3 and so on.
With the "Cfg_HoursOffest" we can adopt the Start and End time to our time zone if needed.
Firt we need to install the "node-red-contrib-ical-events" palette.
Importing the Flow with the .json you find in the downloaded *.zip file.
After importing the Flow we have to adopt some of the nodes. For every Calendar in bOS we need to configure the corresponding Calendar node.
Now we can run "UpdateAll" and the iCal is updated and the days are updated as well. The Node-RED Debug-Log should have message for everyday the message should look like in the picture.
Please login to post a comment.