One thought on “NuttX Channel #016: Using the HC-SR04 to measure distance

  1. Olá Alan,

    Bom dia. Estava tentando configurar o Nuttx para alguns testes em uma SPI NOR AT45DB161. Habilitei o driver SPI1 e nas opções de MTD habilitei o driver da AT45DB. Estava seguindo este tutorial, mas o GCC está retornando erro na biblioteda de ftl

    ||=== Build: all in nuttx (compiler: GNU GCC Compiler for ARM) ===|
    mtd/ftl.c|99|warning: ‘struct geometry’ declared inside parameter list|
    mtd/ftl.c|99|warning: its scope is only this definition or declaration, which is probably not what you want|
    mtd/ftl.c|106|error: variable ‘g_bops’ has initializer but incomplete type|
    mtd/ftl.c|108|warning: excess elements in struct initializer|
    mtd/ftl.c|108|warning: (near initialization for ‘g_bops’)|
    mtd/ftl.c|109|warning: excess elements in struct initializer|
    mtd/ftl.c|109|warning: (near initialization for ‘g_bops’)|
    mtd/ftl.c|110|warning: excess elements in struct initializer|
    mtd/ftl.c|110|warning: (near initialization for ‘g_bops’)|
    mtd/ftl.c|114|warning: excess elements in struct initializer|
    mtd/ftl.c|114|warning: (near initialization for ‘g_bops’)|
    mtd/ftl.c|116|warning: excess elements in struct initializer|
    mtd/ftl.c|116|warning: (near initialization for ‘g_bops’)|
    mtd/ftl.c|121|warning: excess elements in struct initializer|
    mtd/ftl.c|121|warning: (near initialization for ‘g_bops’)|
    mtd/ftl.c|411|warning: ‘struct geometry’ declared inside parameter list|
    mtd/ftl.c|411|error: conflicting types for ‘ftl_geometry’|
    mtd/ftl.c|99|note: previous declaration of ‘ftl_geometry’ was here|
    mtd/ftl.c||In function ‘ftl_geometry’:|
    mtd/ftl.c|421|error: dereferencing pointer to incomplete type|
    mtd/ftl.c|422|error: dereferencing pointer to incomplete type|
    mtd/ftl.c|426|error: dereferencing pointer to incomplete type|
    mtd/ftl.c|428|error: dereferencing pointer to incomplete type|
    mtd/ftl.c|429|error: dereferencing pointer to incomplete type|
    mtd/ftl.c||In function ‘ftl_initialize’:|
    mtd/ftl.c|603|warning: implicit declaration of function ‘register_blockdriver’ [-Wimplicit-function-declaration]|
    mtd/ftl.c|99|warning: ‘ftl_geometry’ used but never defined|
    mtd/ftl.c|411|warning: ‘ftl_geometry’ defined but not used [-Wunused-function]|
    Makefile|122|recipe for target ‘ftl.o’ failed|
    LibTargets.mk|98|recipe for target ‘drivers/libdrivers.a’ failed|
    ||=== Build failed: 9 error(s), 18 warning(s) (0 minute(s), 1 second(s)) ===|

    Você já fez algum teste utilizando o SMARTFS?
    Onde ficam estas configurações:
    CONFIG_MTD_SMART_MINIMIZE_RAM,
    CONFIG_MTD_SMART_WEAR_LEVEL?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s