Commit 8dd1a294 authored by Simon Gölzhäuser's avatar Simon Gölzhäuser
Browse files

Added comments & information

parent 591bdee9
Ball mount: https://www.thingiverse.com/thing:67911
ESP32-CAM case: https://www.thingiverse.com/thing:3708345
ESP32_CAM-Hardware: https://edistechlab.com/esp32-cam-pinout/?v=3a52f3c22ed6
ESP32_CAM-Pinout: https://edistechlab.com/esp32-cam-pinout/?v=3a52f3c22ed6
/*
This Arduino Sketch is used on an ESP32-CAM board. A time-of-flight distance sensor (VL53L1X) is connected via I2C.
Whenever the measured distance goes below a certain threshold, the ESP32-CAM starts recording a AVI video file.
The recording is stopped again when the measured distance is above the threshold for a certain time. An RTC (PCF8523),
also connected via I2C, is used to save the video files with a proper timestamp based name.
The code is based on the project ESP32-CAM-Video-Recorder-junior by jameszah. It can be found on GitHub with the
following link:
https://github.com/jameszah/ESP32-CAM-Video-Recorder-junior
*/
#include <stdio.h>
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
......@@ -57,8 +68,8 @@
// General
// --------------------------------------------------
#define RECORD_TRIGGERDISTANCE (5 * 10) // 5cm
#define RECORD_TURNOFFDELAY (10 * 60 * 1000) // 10min
#define RECORD_TRIGGERDISTANCE (90 * 10) // 90cm
#define RECORD_TURNOFFDELAY (1 * 60 * 1000) // 1min
RTC_PCF8523 g_rtc;
VL53L1X g_sensor;
......
"""
This script takes as input CSV files in the directory "timestamp_diff_input".
It expects the first column to be a timestamp. It then creates a new column
showing the difference to the timestamp of the previous row. The file with the
resulting new column appendes is saved with the same name plus "_with_diff".
"""
import os
import csv
import statistics
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment