Recently, I found about ANCS that enables BLE devices to receive iPhone's notifications.

And, I have BLE including development board M5StickC. That has a display and battery, etc. I only need to write code.

I decideed to make prototype. Just receive notifications and show them.

It will be something interesting, maybe...

Set RTC

UPDATE(2019-10-03): Not required to set RTC.

https://github.com/takeru/Arduino_ESP32_ANCS/commit/2ceb8445611ee356b184592afb69fe4d01e1c08a

(!!!Not required to do this!!!)

First, you need to set RTC.

Use your own tool or mine: https://gist.github.com/takeru/c2922ec229dcc9ad9fc3c601930160aa

You need to configure WiFi SSID & password. And ntp address, timezone, etc.

Code

https://github.com/takeru/Arduino_ESP32_ANCS/blob/M5StickC_Watch_Contest/Arduino_ESP32_ANCS.ino

Clone and open with Arduino IDE. And, write sketch to M5StickC.

Open iPhone's Bluetooth setting. Find device named "Watch".

Select it and do pairing. After that, you will be asked to allow "Watch" to use notification data.

If you have notifications. RED LED is notice every 10sec.

If you had called-in, LED will flick and show "Calling.." in display.

And if you misplaced your iPhone (BLE Connection is lost), Watch will alert you on LED and Display.

Ah, this is watch. You can see what time is it. Sometimes shows current time.

Customize

We can receive more contents from iPhone. Sender name, summary of message, etc... Filter notifications only you want to know.

Play sound from SPEAKER HAT. "Watch, Can you read a message ?"

Many interesting gadgets will be born from M5StickC🍊 & iPhone🍎

Links

I referenced many code from:

https://github.com/nkolban/esp32-snippets/issues/430

https://github.com/S-March/smarchWatch_PUBLIC/tree/master/Software/smarchWatch_DA14683/DA1468x_SDK_1.0.14.1081/DA1468x_DA15xxx_SDK_1.0.14.1081/projects/dk_apps/ble_profiles/smarchWatch

https://github.com/S-March/esp32_ANCS







