[En-Nut-Discussion] STM32F756 strange effect

Uwe Bonnes bon at elektron.ikp.physik.tu-darmstadt.de
Fri Apr 8 11:09:22 CEST 2016


>>>>> "Holger" == Holger Mai <mai at gemac.info> writes:

    Holger> Hello all since a few days i had a working NutOS 5.2.4 (from a
    Holger> repository snapshot ~3 weeks old) with a webserver app, based on
    Holger> an Olimex STM32E407 board, MCU replaced by a STM32F576. All own
    Holger> application parts works fine, but the OS has a strange effect:
    Holger> only every second network request will be answered. I.e., you
    Holger> ping the device, only every second ping is replyed, the others
    Holger> runs in a timeout.  Has anybody an idea how to fix or debug
    Holger> this?

I have a Nucleo-f746 and have run app/httpd some weeks ago. Can this ping
test be done with app/httpd?

Otherwise the M7 has more complex caching. I activated caching some weeks
ago and maybe this exposes some problems, with e.g. DMA shuffling data to
RAM and CPU still working with old data in cache. Please try with caching
disabled ( Architecture-> CM3 -> STM32 Family -> STM32 Clock and system
settings -> Instruction prefetch/Unified flash acceleration buffer).

Probably DMA needs to set some barriers at the right moment. Help is
welcome.

    Holger> The same OS-version works fine with the orininal STM32F407 on an
    Holger> other (same type) board.  IDE is STM32 System workbench,
    Holger> toolchain ARM-GCC embedded 5.0.2 (support for Cortex-M7)

I use the lastest GCC found at https://launchpad.net/gcc-arm-embedded
This seems to be the reference for gcc on arm.

    Holger> Linkerscript is modified to use RAM from 0x20010000, same value
    Holger> used in configurator, "Memory Start" entry in Kernel section,
    Holger> because the first 64kb RAM is not accesible from DMA (Data RAM,
    Holger> core access only)

SRAM setup for F7 is complex. The present setup worked for me with Nucleo-F7
and Discovery F7 on app/uart and app/httpd for a coarse test :-)

Can you proposed and explain a better setup?

    Holger> Another thing is that the default config for Kernel/Main Thread
    Holger> Stack size is too low, it fails with F756 (produces some
    Holger> different usage and hard faults at init phase). However, if i
    Holger> set this to 2048 or 3072 bytes, the OS runs.

Again, contribution is welcome. Hopefully this stack setup is a
configuration setting...

Cheers
-- 
Uwe Bonnes                bon at elektron.ikp.physik.tu-darmstadt.de

Institut fuer Kernphysik  Schlossgartenstrasse 9  64289 Darmstadt
--------- Tel. 06151 1623569 ------- Fax. 06151 1623305 ---------


More information about the En-Nut-Discussion mailing list