Skip to content

Commit

Permalink
V3.2 (#112)
Browse files Browse the repository at this point in the history
* Fix #110 by disabling face recognition for image captures while a stream is running
* update some comments in the myconfig sample
* Update the Readme
  • Loading branch information
easytarget authored May 17, 2021
1 parent fd77a62 commit 0cba55b
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 12 deletions.
16 changes: 13 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,16 @@ https://wiki.ai-thinker.com/esp32-cam
Please read this excellent guide for help with some common issues seen with the camera modules:
https://randomnerdtutorials.com/esp32-cam-troubleshooting-guide/

### Known Issues

The ESP itself is susceptable to the usual list of WiFi problems, not helped by having small antennas, older designs, congested airwaves and demanding users. The majority of disconnects, stutters and other comms problems are simply due to 'WiFi issues'. The AI-THINKER camera module & esp32 combination is quite susceptable to power supply problems affecting both WiFi conctivity and Video quality; short cabling and decent power supplies are your friend here; also well cooled cases and, if you have the time, decoupling capacitors on the power lines.

A basic limitation of the sketch is that it can can only support one stream at a time. If you try to connect to a cam that is already streaming (or attempting to stream) you will get no response and, eventually, a timeout. The stream itself is a [MJPEG stream](https://en.wikipedia.org/wiki/Motion_JPEG), which relies on the client (the web browser) to hold the connection open and request each new frame in turn via javascript. This can cause errors when browsers run into Javascript or caching problem, fail to request new frames or refuse to close the connection.

Another known issue is that if you are streaming with face detection turned on any new tatic mage capture request will cause the stream to exit.

The existing [issues list](https://github.com/easytarget/esp32-cam-webserver/issues?q=is%3Aissue) on Github is a good place to start if you have a specific issue not covered above

## Setup:

* For programming you will need a suitable development environment, I use the Arduino IDE, but this code should work in the Espressif development environment too.
Expand Down Expand Up @@ -64,7 +74,7 @@ Once you have done that you can open the sketch in the IDE by going to the `esp3

By default the sketch assumes you have an AI-THINKER board, it creates an AccessPoint called `ESP32-CAM-CONNECT` and with the password `InsecurePassword`; connect to that and then browse to [`http://192.168.4.1/`](http://192.168.4.1/). This is nice and easy for testing and demo purposes.

To make a permanent config with your home wifi settings, different defaults or a different board; copy (or rename) the file `myconfig.sample.h` in the sketch folder to `myconfig.h`. Because this is your private copy of the config it will not get overwritten if you update the main sketch!
To make a permanent config with your home wifi settings, different defaults or a different board; copy (or rename) the file `myconfig.sample.h` in the sketch folder to `myconfig.h` and edit that, all the usable defaults are in that file. Because this is your private copy of the config it will not get overwritten if you update the main sketch!

### Programming

Expand Down Expand Up @@ -121,6 +131,6 @@ V4 Remove face recognition entirely;
* implement OTA and a better network stack for remembering multiple AP's, auto-config etc.
* UI Skinning/Theming
* OSD
** Temp/humi/press sensor suport (bme20,dht11)
* Temperature/humidity/pressure sensor suport (bme20,dht11)
You can check the [enhancement list](https://github.com/easytarget/esp32-cam-webserver/issues?q=is%3Aissue+label%3Aenhancement) (past and present), and add any thoghts you may have there.

You can check the [enhancement list](https://github.com/easytarget/esp32-cam-webserver/issues?q=is%3Aissue+label%3Aenhancement) (past and present), and add any thoghts you may have there. Things that have occurred to me are, in no particular order:
2 changes: 1 addition & 1 deletion app_httpd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ static esp_err_t capture_handler(httpd_req_t *req){
bool s;
bool detected = false;
int face_id = 0;
if(!detection_enabled || fb->width > 400){
if(!detection_enabled || fb->width > 400 || streamCount != 0){
size_t fb_len = 0;
if(fb->format == PIXFORMAT_JPEG){
fb_len = fb->len;
Expand Down
14 changes: 7 additions & 7 deletions myconfig.sample.h
Original file line number Diff line number Diff line change
Expand Up @@ -131,21 +131,21 @@ struct station stationList[] = {{"ssid1", "pass1", true},
// Uncomment to disable the illumination lamp features
// #define LAMP_DISABLE

// Define a initial lamp setting as a percentage, defaults to 0%
// Define the startup lamp power setting (as a percentage, defaults to 0%)
// #define LAMP_DEFAULT 0

// Assume we have SPIFFS/LittleFS partition, uncomment to disable this.
// Controls will still be shown in the UI but are inoperative.
// Assume the module used has a SPIFFS/LittleFS partition, and use that for persistent setting storage
// Uncomment to disable this this, the controls will still be shown in the UI but are inoperative.
// #define NO_FS

// Uncomment to enable Face Detection (+ Recognition if desired) by default
// Notes: You must set DEFAULT_RESOLUTION (above) to FRAMESIZE_CIF or lower before enabling this
// Face recognition enrolements are currently lost between reboots.
// Note: 1) You must set DEFAULT_RESOLUTION (above) to FRAMESIZE_CIF or lower before enabling this
// 2) Face recognition enrolements are lost between reboots.
// #define FACE_DETECTION
// #define FACE_RECOGNITION

// Uncomment and edit the following to change the text displayed next to faces when face recognition is on
// The 'good' text will have the subject ID appended. Maximum 20 characters!
// Uncomment and edit the following to change the on screen labels for known and unknown faces
// The 'good' text will have the subject ID number appended. Maximum 20 characters!
// #define GOOD_FACE_TEXT "Hello Subject "
// #define BAD_FACE_TEXT "Intruder Alert!"

Expand Down
2 changes: 1 addition & 1 deletion src/version.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/* Version of upstream code */

char baseVersion[] = "3.1";
char baseVersion[] = "3.2";

0 comments on commit 0cba55b

Please sign in to comment.