0 votes
in ESPaper by (150 points)
I’ve recently bought the ESPaper Plus Kit to display my calendar on it. Unfortunately, I can not connect it to my Google calendar. My calendar is public (it needs to be, doesn’t it?).
Can anyone please tell me, which one of the following 4 URLs I have to use in order to make the display work (screenshot from my Google Calendar Account)? Or is there another URL I should use?
Thanks,
Ramun

1 Answer

0 votes
by (19.9k points)
selected by
 
Best answer
Option 4 is what you are looking for. The address is something like this: https://calendar.google.com/calendar/ical/EMAIL-ADDRESS/private-SOME-CODE/basic.ics (derived from our test calendar).

The calendar has to be accessible from the internet without any authentication i.e. not behind some corporate firewall. The calendar doesn't need to be public as per Google's definition above.
by (150 points)
Thanks for the quick reply! I've tried again with Option 4: It has exactly the pattern you mentioned:
https://calendar.google.com/calendar/ical/MYEMAIL/private-SOMEDIGITS/basic.ics

But it keeps saying "Could not load calendar. Please check your settings." (see screenshot https://ramun.ch/squix.jpg).

Is there any way I can activate/see some debugging?
by (19.9k points)
We didn't see any errors on the server this weekend. Hence, I suspect the requests from your device never even made it to our servers.

You can debug this over the Serial-to-USB connector that came with your Plus Kit with any terminal at 115'200 baud. Precondition is that you have the driver(s) for the TTL chip installed.

If your system is not set up for this yet I propose the following:

- Install drivers as per https://docs.thingpulse.com/how-tos/install-drivers/
- As you may or may not have a suitable terminal / serial console yet install the Arduino IDE as per the first paragraph on https://docs.thingpulse.com/how-tos/Arduino-IDE-for-ESP8266/
- Hook up your device to a USB port with the programmer and the cable provided
- Start the Arduino IDE
- Select the serial port in Tools > Port. On macOS the serial devices are called /dev/cu.xxx. On a PC it should be listed as a COM port labelled COM# (where # is some number).
- Start the terminal with Tools > Serial Monitor
- Press the reset button on the device

The device will connect to https://calendar.espaper.com/filter/index.php?cal=<your-Google-URL>. You can also test this a browser beforehand; it will download an index.ics file.
by (150 points)
Debugging output works. Hope that helps...

***********set register Start**********
***********set register  end**********
Loading config
WIFI_SSID = [***]
9
WIFI_PASS = [***]
9
CALENDAR_URL = [https://calendar.google.com/calendar/ical/*****basic.ics]
12
RESOURCE_NAME = [Ramun]
13
LANGUAGE = [1]
8
UPDATE_INTERVAL_MINS = [20]
20
TIMEZONE_KEY = [Europe/Zurich CET-1CEST,M3.5.0,M10.5.0/3]
12
NTP_SERVERS = [0.europe.pool.ntp.org,1.europe.pool.ntp.org,2.europe.pool.ntp.org]
11
CAL_PROXY_HOST = []
14
CAL_PROXY_PORT = [0]
14
CAL_PROXY_PATH = []
14
Loaded config
State: 1
Connecting WiFi: ***
........
WiFi connected
IP address:
192.168.1.113
.
Current time: 1552335675
Time difference between local timezone and UTC: 3600
Connecting to: :0
Connection failed
Writing buffer
full init
***********set register Start**********
***********set register  end**********
Going to sleep for 1200sec

Any hints?
by (19.9k points)
Those CAL_PROXY_xxx values shouldn't be empty. The effect is "Connecting to: :0". The device should instead talk to our server.

Several months ago we had another case just like that. We worked intensively with the customer on that issue but we weren't able to find the root cause. No other customer has since reported something similar.

There are two options:
° Reset the application to factory settings
  - Transfer the app to the device again and select "Erase memory = yes"
  - You will have to configure WiFi and calendar URL again in the config portal.
° Re-add the missing values
  - Put the device into config mode.
  - After you load the config portal in the browser click the "Configuration" heading. Three extra fields become visible at the end of the form (we use those for testing and debugging).
  - Enter the values as follows: host → 'calendar.espaper.com', port → 443,  path → '/filter/index.php?cal=' (omit the '')
by (150 points)
ok, great, I see some progress here ;-) I've reset the application to factory settings. Funny enough, the NTP servers were empty in the beginning. Fortunately I had the above thread. So that's where I stand now:

***********set register Start**********
***********set register  end**********
Loading config
WIFI_SSID = [***]
9
WIFI_PASS = [***]
9
CALENDAR_URL = [https://calendar.google.com/calendar/ical/***/basic.ics]
12
RESOURCE_NAME = [Ramun]
13
LANGUAGE = [1]
8
UPDATE_INTERVAL_MINS = [20]
20
TIMEZONE_KEY = [UTC GMT0]
12
NTP_SERVERS = [0.europe.pool.ntp.org,1.europe.pool.ntp.org,2.europe.pool.ntp.org]
11
CAL_PROXY_HOST = [calendar.espaper.com]
14
CAL_PROXY_PORT = [443]
14
CAL_PROXY_PATH = [/filter/index.php?cal=]
14
Loaded config
State: 1
Connecting WiFi: ***
........
WiFi connected
IP address:
192.168.1.113
.
Current time: 1552339100
Time difference between local timezone and UTC: 0
Connecting to: calendar.espaper.com:443
Connected to calendar.espaper.com:443
GETting /filter/index.php?cal=https://calendar.google.com/calendar/ical/***/basic.ics
Socket timeout, no content within ms
Writing buffer
full init
***********set register Start**********
***********set register  end**********
Going to sleep for 1200sec

Do you see something on your side now?
by (150 points)
And sorry, on the screen it still says "Could not load calendar. Please check your settings"
by (19.9k points)
"Funny enough, the NTP servers were empty in the beginning." - that is by design. The NTP servers are derived from the time zone you select. However, in corporate environments users may have to overwrite this and, therefore, the field is editable.

"Do you see something on your side now?"

Yes, indeed. I see that our script, triggered by an IP address from the same country as you,  downloaded a giant calendar from Google. I suspect it must have been yours. It then exhausted the available memory parsing it.
iCalendar format is a bit*** to parse due to the recurrence rules. Hence, even if you look for just a tiny window into the entire calendar, our app just cares about today's events, you still need to parse the entire calendar. Of course that can be done more efficiently - or less. We use an established open-source library for that but we had to pimp it quite a bit because the parser wasn't optimized.

I'm afraid that without getting access to your giant calendar it will be very hard to guess what effectively tripped the parser. Yours must obviously be far beyond even the large corporate meeting room calendars we tested against.
by (150 points)
Yes, that might be indeed. My iCal also crashes from time to time...
Good thing: I don't want to have my personal cal shown on the meeting room door - I just used it because it's easier to play around with than the planned calender. I'll try again tomorrow with the real calendar - which is almost empty :-)
Thanks so far and good night!
by (150 points)
...and now it works like a charm! See debug output below. Thanks for your help!

Another question: Is it possible to configure the screen to show more following meetings on the right side? Because this meeting room is normally empty and we have just about 2-3 meetings per week.

------------------------------------------------------------------------------------------------
(skipping the first lines)
WiFi connected
IP address:
192.168.90.77
.
Current time: 1552375050
Time difference between local timezone and UTC: 3600
Connecting to: calendar.espaper.com:443
Connected to calendar.espaper.com:443
GETting /filter/index.php?cal=https://calendar.google.com/calendar/ical/***/basic.ics
Header: HTTP/1.1 200 OK
Header: Date: Tue, 12 Mar 2019 07:17:30 GMT
Header: Server: Apache/2.4
Header: Upgrade: h2,h2c
Header: Connection: Upgrade, close
Header: Content-Length: 350
Header: Content-Type: text/calendar;charset=UTF-8
Parsed content Length: 350
Parsed event 'X Daily
' from 1552387500 - 1552388400 by ''
-----
Found future event 'X Daily
'.
HTTP content-length: 350, total received bytes: 535

Current meeting: '', epoch: 0
Next meeting: 'X Daily
', epoch: 1552387500
Date 1: 2019/02/12
Date 2: 2019/02/12
Is same day: true
Writing buffer
full init
***********set register Start**********
***********set register  end**********
Going to sleep for 2400sec

Welcome to ThingPulse Q&A, where you can ask questions and receive answers from other members of the community.

https://thingpulse.com

...