#define FREQUENCY_HZ 50 // how many samples per second #define COLLECTION_SECONDS 2 // how many seconds to collect samples
Original Demo from Google Developers codelabs.