-->
Page 1 of 2

Need 20-30k - plus flash memory(dont spiff)

PostPosted: Sun Oct 11, 2015 12:05 pm
by zsocy
Hi,

I develop small webserver applicaton with Sming framework.
I want to use Spiff filesistem - with 2-4K size.
I need 3-4 pieces file(html,css,js), with 5-8kbyte.

My idea in this situation:

I put the file to code(in binary form).

If one file (for example - index.html content), the framwork working fine.
If I use two file (about 12k size), the application resetting.

Thanks,

Zsocy

Re: Need 20-30k - plus flash memory(dont spiff)

PostPosted: Sun Oct 11, 2015 1:47 pm
by hreintke
zsocy

You should be more specific on your environment, what you want to achieve and the errors/issue to see at the moment.

- What sming version do you use
- Which esp do you use
- What are the requirements of your application
- How did you configure applicaton/spiffs
- What errormessages did you see

Re: Need 20-30k - plus flash memory(dont spiff)

PostPosted: Sun Oct 11, 2015 10:29 pm
by zsocy
Hi Hreintke,

Sorry, for short description!

Details:

Sming version: ae1cc856b8b27d5be043cb4f284872d4e0a0bd23
Esp: esp8266-07
Requirements(short): serve 3 file. 1pcs html(~5-7kbyte), 1pcs css(~5-7kbyte), 1pcs js(~5-7kbyte)
My make file configuration:
MODULES = app
SPIFF_FILES = web/build

Test1:

#include "../generatedCFiles/indexHtml.c"
void onIndex(HttpRequest &request, HttpResponse &response)
{
response.sendString(indexFile_data);
}

when indexHtml.c contain ~5kbyte string

The application serve the file, error not occured.

Test2:

#include "../generatedCFiles/indexHtml.c"
void onIndex(HttpRequest &request, HttpResponse &response)
{
response.sendString(indexFile_data);
}

#include "../generatedCFiles/allCss.c"
void onAllCss(HttpRequest &request, HttpResponse &response)
{
response.sendString(cssFile_data);
}

when indexHtml.c and allCss.c contain ~5-6kbyte string

This my flashing:
make flash
/home/zsolt/.opt/esp-open-sdk/esptool/esptool.py -p /dev/ttyUSB0 -b 115200 write_flash -ff 40m -fm qio -fs 4m 0x00000 out/firmware/0x00000.bin 0x09000 out/firmware/0x09000.bin
Connecting...
Erasing flash...
Wrote 50176 bytes at 0x00000000 in 4.8 seconds (82.8 kbit/s)...
Erasing flash...
Wrote 235520 bytes at 0x00009000 in 23.0 seconds (81.9 kbit/s)...

Leaving...
python -m serial.tools.miniterm /dev/ttyUSB0 115200
--- Miniterm on /dev/ttyUSB0: 115200,8,N,1 ---
--- Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H ---
tail 4
chksum 0xdd
csum 0xdd
csum err
ets_main.c


Thanks,

Zsocy

Re: Need 20-30k - plus flash memory(dont spiff)

PostPosted: Sun Oct 11, 2015 10:35 pm
by zsocy
Remark:

A want 4-8kbyte Spiff filesystem.