Accent is a smart picture frame with a pop of color and no cables. Read more about it on Medium.
The database backend uses Cloud Firestore. User-specific data is stored in the
users collection with each user identified by a key generated by the client to identify it.
/users/<USER_KEY>/home- The home address used for the local time, the weather, and the commute origin.
/users/<USER_KEY>/work- The work address used for the commute destination.
/users/<USER_KEY>/travel_mode- The commute travel mode.
/users/<USER_KEY>/schedule- The content schedule.
/users/<USER_KEY>/google_calendar_credentials- The OAuth credentials for Google Calendar.
To populate the cross-user data after setting up:
- Obtain an API key for Google Maps and add it the
/api_keys/google_maps/api_key. Ensure that the Maps Static API, Directions API, Geocoding API, Maps Elevation API, and Time Zone API are all enabled and added to the key's restrictions. The Cloud Vision API also needs to be enabled, but it doesn't need a key.
- Obtain an API key for OpenWeather and add it in the
- Obtain an OAuth client ID for the Google Calendar API with scope
To test and deploy the server:
- Install the Google Cloud SDK, create a project, and authenticate with a service account.
cd server && python3 -m venv venv && . venv/bin/activate.
pip install -r requirements.txt.
- Run the server locally with
export GOOGLE_CLOUD_PROJECT=$(gcloud config get-value project) && python main.py.
- Test the local server with:
- /hello/<USER_KEY> for the settings UI to edit user-specific data.
- /next?key=<USER_KEY> for the time in milliseconds until the next schedule entry.
- /epd?key=<USER_KEY> for the currently scheduled 2-bit image used by the e-paper display.
- /gif?key=<USER_KEY> for a GIF version of the currently scheduled image for testing.
- /artwork?key=<USER_KEY> to bypass the schedule and get the artwork image directly.
- /city?key=<USER_KEY> to bypass the schedule and get the city image directly.
- /commute?key=<USER_KEY> to bypass the schedule and get the commute image directly.
- /calendar?key=<USER_KEY> to bypass the schedule and get the calendar image directly.
- /everyone?key=<USER_KEY> to bypass the schedule and get the everyone image directly.
- Deploy the server with
gcloud app deploy.
To push the client code to the board:
- Add your server base URL to
- Use the board information in
Client.inoto set up the environment.
- Verify and upload the sketch.
Finally, follow the on-screen instructions to connect the client to a Wifi access point.
Files describing the Accent frame hardware include: