AnnexCam in 4MB!?

If doesn't fit into any other category ....
AndyGadget
Posts: 111
Joined: Mon Feb 15, 2021 1:44 pm
Has thanked: 41 times
Been thanked: 81 times

AnnexCam in 4MB!?

Post by AndyGadget »

I've mistakenly bought a couple of pairs of 4MB flash RAM ESP32-CAM modules before I read Cicciocb's excellent explanation of the memory usage and partitioning scheme in use by Annex and was experiencing the error "Failed to create fatfs filesystem 14" when I tried to flash 'firmware + data + OTA".

BUT
Flashing 'Firmware only' proceeds with no error!
It's easy enough then to connect to the 192.146.4.1 address to set the network parameters and camera type.
I've tested the basic camera operations and all works OK. Working fine with SD card too. I haven't used the facial recognition features but as the firmware appears to be fully operational I'd expect no problems, unless it tries to take some previously unallocated FLASH.

Cicciocb, have I discovered something here or have you 'been there, done that' and I can experience problems down the line?

This is the bootup output :

Code: [Local Link Removed for Guests]

rst:0x1(OWRNRESET),boot:013(PIFST_FLASH_BOOT
lshrad err, 1000
t_mi.c371 
st:x0(TWD_TCRSET),boot:0x13(SIFATFAHBO)
cnfgip 0, SPIWP:0xee
lkdv0x00,q_drv:0x0,ddv:x0,s_r:x00h_dv0x00,wp_drv:0x0
md:DO, clock div:
od:xfff0018,len:4
lad03ff0cln121
ho0tail 12 room 
od:x0078000,len:920
o  ail 12 room 4
lad04080400,len:635
nry0400b
P˕ initializing...
PSRAM enabled
module Type 201 SD_Card 1
Camera Enabled
OK
No SD cards found. Reverts to FFAT

AnnexCAM DET 1.43.5
(C) ciccioCB 2021
Personal use only, commercial use strictly prohibited

Chip revision 1 Freq 240
STARTING...
Connecting.......
User avatar
PeterN
Posts: 142
Joined: Mon Feb 08, 2021 7:56 pm
Location: Krefeld, Germany
Has thanked: 56 times
Been thanked: 75 times
Contact:

Re: AnnexCam in 4MB!?

Post by PeterN »

Hi Andy,

I can report the same experience with ESP32CAM and M5Stack cam type B.
In connection with two servos SG90 and the Telegram option it became really interesting. However, I struggle with occasional not quite explainable reboots. But that could also be related to the fact that I needed two pins for the PWM signal of the servos and the pins were available only unproblematically and stable with the M5 camera.
(Maybe there is a conflict with the SD-card-driver and the servo Pin, too, when using that option with the ESP32cam)

An other point was that the quality/bandwidth of the WIFI-connection was very important for a stable function.

[Local Link Removed for Guests]
[External Link Removed for Guests]
cicciocb
Site Admin
Posts: 413
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 92 times
Been thanked: 297 times
Contact:

Re: AnnexCam in 4MB!?

Post by cicciocb »

[Local Link Removed for Guests] wrote: [Local Link Removed for Guests]Wed Oct 20, 2021 11:49 am I've mistakenly bought a couple of pairs of 4MB flash RAM ESP32-CAM modules before I read Cicciocb's excellent explanation of the memory usage and partitioning scheme in use by Annex and was experiencing the error "Failed to create fatfs filesystem 14" when I tried to flash 'firmware + data + OTA".

BUT
Flashing 'Firmware only' proceeds with no error!
It's easy enough then to connect to the 192.146.4.1 address to set the network parameters and camera type.
I've tested the basic camera operations and all works OK. Working fine with SD card too. I haven't used the facial recognition features but as the firmware appears to be fully operational I'd expect no problems, unless it tries to take some previously unallocated FLASH.

Cicciocb, have I discovered something here or have you 'been there, done that' and I can experience problems down the line?

This is the bootup output :

Code: [Local Link Removed for Guests]

rst:0x1(OWRNRESET),boot:013(PIFST_FLASH_BOOT
lshrad err, 1000
t_mi.c371 
st:x0(TWD_TCRSET),boot:0x13(SIFATFAHBO)
cnfgip 0, SPIWP:0xee
lkdv0x00,q_drv:0x0,ddv:x0,s_r:x00h_dv0x00,wp_drv:0x0
md:DO, clock div:
od:xfff0018,len:4
lad03ff0cln121
ho0tail 12 room 
od:x0078000,len:920
o  ail 12 room 4
lad04080400,len:635
nry0400b
P˕ initializing...
PSRAM enabled
module Type 201 SD_Card 1
Camera Enabled
OK
No SD cards found. Reverts to FFAT

AnnexCAM DET 1.43.5
(C) ciccioCB 2021
Personal use only, commercial use strictly prohibited

Chip revision 1 Freq 240
STARTING...
Connecting.......
Hi Andy,
the ESPCAM firmware works well, the unique limitation is the inability to create a default file system with the toolkit as the available "disk" space is below the minimum size that the utility can handle.
Except for this limitation, the firmware works well, as reported by PeterN.
If the OTA function is not required, it could be possible to remove the OTA partition and this as additional disk space.
I'm actually facing to a great limitation in times of disk space as the new SDK released recently generates a bin file too big to fit in the actual flash size.
User avatar
PeterN
Posts: 142
Joined: Mon Feb 08, 2021 7:56 pm
Location: Krefeld, Germany
Has thanked: 56 times
Been thanked: 75 times
Contact:

Re: AnnexCam in 4MB!?

Post by PeterN »

Hi Francesco,

regarding the size of the ANNEX CAM firmware:
I have done some tests with face det&recognition, following the principle of "keep it simple". Very interesting from a technical point of view!!! Especially the comparison with my experiments with much more powerful solutions based on heavy hardware and software was a lot of fun. But since the well-known ESP32 face detection and recognition lib in combination with the ESP32-hardware sets a principle limitation to 320x240 resolution and only 7 faces, this is nothing more than a proof of concept, but not really of practical use.
On the other hand, I love the live stream and jpg image capabilities in ANNEX-CAM - especially when combined with SD card, ftp and Telegram bot capabilities. This has a lot of practical potential - my first steps there were a lot of fun.

So if there was a way to get ANNEX_CAM into memory by leaving out something less important - my choice would be face detection.

Thanks again for that fantastic "playground"!
PANNO2
Posts: 38
Joined: Tue Jun 08, 2021 6:26 pm
Has thanked: 27 times
Been thanked: 2 times

Re: AnnexCam in 4MB!?

Post by PANNO2 »

can anyboody give me a link to the 8MB Module?

btw : @ Peter , you make a Annex Wifi thread iin the Elektor ? cool :D
AndyGadget
Posts: 111
Joined: Mon Feb 15, 2021 1:44 pm
Has thanked: 41 times
Been thanked: 81 times

Re: AnnexCam in 4MB!?

Post by AndyGadget »

Peter, is the ESP32 recognition lib tuned only for faces, or can it be taught to recognise other objects?
User avatar
PeterN
Posts: 142
Joined: Mon Feb 08, 2021 7:56 pm
Location: Krefeld, Germany
Has thanked: 56 times
Been thanked: 75 times
Contact:

Re: AnnexCam in 4MB!?

Post by PeterN »

Hi Panno,

there might be a misunderstanding about the modules with or without PSRAM.
Andy referenced cicciocb's explanation that was very helpful for me to gain a deeper understanding of the ESP32's memory-usage
[Local Link Removed for Guests]



About ELEKTOR-LABs: I do my very best :-)) and ANNEX was again very helpful with the test of the "ESP32 range extender" - the world will recognize that soon, too;-)
User avatar
PeterN
Posts: 142
Joined: Mon Feb 08, 2021 7:56 pm
Location: Krefeld, Germany
Has thanked: 56 times
Been thanked: 75 times
Contact:

Re: AnnexCam in 4MB!?

Post by PeterN »

[Local Link Removed for Guests] wrote: [Local Link Removed for Guests]Thu Oct 21, 2021 9:09 pm Peter, is the ESP32 recognition lib tuned only for faces, or can it be taught to recognise other objects?
Hi Andy,

with this lib it seems tuned to recognize faces only and can not simply be trained to recognize other objects. M5Stack has a "M5 Stick V" with micropython that seems to be very flexible in this area for a resonable price


Without having tested this ... maybe this is one of many other ways with the esp32cam: [External Link Removed for Guests]
PANNO2
Posts: 38
Joined: Tue Jun 08, 2021 6:26 pm
Has thanked: 27 times
Been thanked: 2 times

Re: AnnexCam in 4MB!?

Post by PANNO2 »

anyone test the cam with some lens kits for a phone ?
User avatar
PeterN
Posts: 142
Joined: Mon Feb 08, 2021 7:56 pm
Location: Krefeld, Germany
Has thanked: 56 times
Been thanked: 75 times
Contact:

Re: AnnexCam in 4MB!?

Post by PeterN »

Hi Panno,
Yes, I have two of those lense sets with magnetic ring holders.
I took one with a wide optic in front of a standard ESP32-Cam and a tele-lense with the M5Cam and a pan/tilt head.
But before this I carefully removed the glue at the original lens to be able to simply change the focus point
3FB772BE-72E1-4771-81C8-F938766D78AD.jpeg
234303CE-4D94-4597-AB4B-7D043DF93704.jpeg
1E8E5E71-BB41-433A-A97C-D48F90018663.jpeg
Be careful when using acrylic acetate adhesive near the lenses - the adhesive vapors quickly cloud the lenses
You do not have the required permissions to view the files attached to this post.
Post Reply