Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ dependencies = [
"uvicorn",
"streamlit",
"streamlit_autorefresh",
"websockets",
]

# Define optional dependencies like testing and CUDA support
Expand Down
41 changes: 41 additions & 0 deletions src/client/esp32-s3-eye-http/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Other files
.vscode/.browse.c_cpp.db*
.vscode/c_cpp_properties.json
.vscode/launch.json
.vscode/ipch
src/conf.h
.pio/
logs/

# Prerequisites
*.d

# Compiled Object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
*.gch
*.pch

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
*.mod
*.smod

# Compiled Static libraries
*.lai
*.la
*.a
*.lib

# Executables
*.exe
*.out
*.app
File renamed without changes.
29 changes: 29 additions & 0 deletions src/client/esp32-s3-eye-http/platformio.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
; PlatformIO Project Configuration File
;
; Build options: build flags, source filter
; Upload options: custom upload port, speed and extra flags
; Library options: dependencies, extra library storages
; Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[env:esp32dev]
platform = espressif32
board = esp32-s3-devkitc-1-n8r8
framework = arduino
monitor_speed = 115200
build_flags =
-DARDUINO_USB_CDC_ON_BOOT=1
-DBOARD_HAS_PSRAM
; -DCORE_DEBUG_LEVEL=5
; -mfix-esp32-psram-cache-issue
monitor_filters = default, log2file
lib_deps =
robtillaart/UUID@^0.1.5
bblanchon/ArduinoJson@^7.2.1
tanakamasayuki/TensorFlowLite_ESP32@^1.0.0
esp32-camera
khoih-prog/AsyncHTTPRequest_Generic@^1.13.0
WebServer
FS
56 changes: 56 additions & 0 deletions src/client/esp32-s3-eye-http/src/conf.template.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
#ifndef CONF_H_
#define CONF_H_

// ------------------------------------------------------------------------------------------------------------------------------------------------------
// WiFi Conf Hotspot
const char* SSID = "";
const char* PWD = "";
// ------------------------------------------------------------------------------------------------------------------------------------------------------
// HTTP Conf
const char* HTTP_SRV = "192.168.1.100"; // Replace with Edge's IP
const int HTTP_PORT = 8000;
// ------------------------------------------------------------------------------------------------------------------------------------------------------
// NTP Timer Configuration
const char* NTP_SRV = "0.it.pool.ntp.org";
const long NTP_GMT_OFFSET = 0;
const int NTP_DAYLIGHT_OFFSET = 0;
// ------------------------------------------------------------------------------------------------------------------------------------------------------
// Model Configuration
const int MAX_NUM_LAYER = 59;
constexpr int BATCH_SIZE = 1;
constexpr int IMAGE_HEIGHT = 96;
constexpr int IMAGE_WIDTH = 96;
constexpr int CHANNELS = 3;
constexpr int MAX_ELEMENTS_PER_MODEL_LAYER = 1*49*49*48;
constexpr int K_TENSOR_ARENA_SIZE = 1000*1024;
// timestamp + device_id + message_id + offloading_layer_index + layer_output_size + layer_output + layers_inference_time_size + layers_inference_time
constexpr int OUTPUT_MSG_SIZE = 1*sizeof(double) + 9*sizeof(char) + 4*sizeof(char) + 1*sizeof(int) + 1*sizeof(size_t) + 2*MAX_ELEMENTS_PER_MODEL_LAYER*sizeof(float) + 1*sizeof(int) + MAX_NUM_LAYER*sizeof(float);
#define WDT_TIMEOUT 15
#define FOMO // Comment for Sequential models / Uncomment for FOMO models
// ------------------------------------------------------------------------------------------------------------------------------------------------------
// Camera Configuration
#define CAMERA_PIN_PWDN -1
#define CAMERA_PIN_RESET -1

#define CAMERA_PIN_VSYNC 6
#define CAMERA_PIN_HREF 7
#define CAMERA_PIN_PCLK 13
#define CAMERA_PIN_XCLK 15

#define CAMERA_PIN_SIOD 4
#define CAMERA_PIN_SIOC 5

#define CAMERA_PIN_D0 11
#define CAMERA_PIN_D1 9
#define CAMERA_PIN_D2 8
#define CAMERA_PIN_D3 10
#define CAMERA_PIN_D4 12
#define CAMERA_PIN_D5 18
#define CAMERA_PIN_D6 17
#define CAMERA_PIN_D7 16

#define XCLK_FREQ_HZ 16000000
#define FRAMESIZE_CUSTOM FRAMESIZE_96X96
// ------------------------------------------------------------------------------------------------------------------------------------------------------

#endif // CONF_H
Loading