Let's build a visual aid where we display the number of steps taken in a given day using an LED strip. The LED strip would light up like a progress bar based on the daily physical activity.
- The first step is importing the requisite libraries while building the visual aid. This includes the fitbit and blinkt libraries. We will also import some additional libraries:
import blinkt import datetime import fitbit import time import schedule
- Make sure that you have the requisite tokens discussed earlier in this section:
CONSUMER_KEY = "INSERT_KEY" CONSUMER_SECRET = "INSERT_SECRET" ACCESS_TOKEN = "INSER_TOKEN" REFRESH_TOKEN = "INSERT_TOKEN"
- A new refresh token is needed every 8 hours. This is a feature of the ...