6 Replies Latest reply on Mar 21, 2017 5:26 AM by user_2263061

    Debug writing app WWD

      I writing a small app to test function WWD:

      
      #include "lwip/opt.h"
      #include "lwip/icmp.h"
      #include "lwip/inet_chksum.h"
      #include "lwip/sockets.h"
      #include "lwip/mem.h"
      #include "lwip/inet.h"
      #include "netif/etharp.h"
      #include "ipv4/lwip/ip.h"
      #include "lwip/tcpip.h"
      #include "lwip/dhcp.h"
      #include "wwd_network.h"
      #include "wwd_management.h"
      #include "wwd_wifi.h"
      #include "wwd_debug.h"
      #include "wwd_assert.h"
      #include "platform/wwd_platform_interface.h"
      #include "RTOS/wwd_rtos_interface.h"
      #include "wwd_buffer_interface.h"
      
      
      
      
      #define COUNTRY             WICED_COUNTRY_UNITED_STATES
      
      
      int main( void )
      {
          
          wwd_result_t result;
      
      
          /* Initialise Wiced */
          WPRINT_APP_INFO(("Starting Wiced v" WICED_VERSION "\n"));
      
      
          wwd_buffer_init( NULL);
          result = wwd_management_wifi_on( COUNTRY );
          if ( result != WWD_SUCCESS )
          {
              WPRINT_APP_INFO(("Error %d while starting WICED!\n", result));
          }
      }
      
      
      

      but with kit BCM94343W_AVN it always build with error dct wiced_dct_internal_common.o): In function `wiced_dct_erase_non_current_dct':
      Could you please help me to solve this problem
      Thanks

        • 1. Re: Debug writing app WWD
          SeyhanA_31

          What are you trying to achieve?

          • 2. Re: Debug writing app WWD

            I want to get ethernet packet using WWD directly

            • 3. Re: Debug writing app WWD
              JeGu_2199941

              Hi, ntvinh

               

              Have you find a way to fix your build errors? ("but with kit BCM94343W_AVN it always build with error dct wiced_dct_internal_common.o): In function `wiced_dct_erase_non_current_dct'")

              Can you share your experience?

               

              Hi, SeyhanA_31

               

              Could you provide some help with the error messages below?

               

              What I'm trying to do is let apps/wwd/scan supports BCM94343W_AVN platform.

              And I see error msgs like this : ()

               

              Making wwd.scan-BCM94343W_AVN-ThreadX-NetX.elf

              build/wwd.scan-BCM94343W_AVN-ThreadX-NetX/libraries/STM32F4xx.a(wiced_dct_internal_common.o): In function `wiced_dct_finish_new_dct':

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:635: undefined reference to `dct2_start_addr_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:635: undefined reference to `dct1_size_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:635: undefined reference to `dct1_start_addr_loc'

              build/wwd.scan-BCM94343W_AVN-ThreadX-NetX/libraries/STM32F4xx.a(wiced_dct_internal_common.o): In function `wiced_dct_erase_non_current_dct':

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:1113: undefined reference to `dct1_size_loc'

              build/wwd.scan-BCM94343W_AVN-ThreadX-NetX/libraries/STM32F4xx.a(wiced_dct_internal_common.o): In function `wiced_dct_internal_dct_update':

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:860: undefined reference to `dct1_start_addr_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:860: undefined reference to `dct2_start_addr_loc'

              build/wwd.scan-BCM94343W_AVN-ThreadX-NetX/libraries/STM32F4xx.a(wiced_dct_internal_common.o): In function `wiced_dct_get_current_address':

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:1061: undefined reference to `dct1_start_addr_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:1061: undefined reference to `dct1_start_addr_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:1061: undefined reference to `dct2_start_addr_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_internal_common.c:1061: undefined reference to `dct1_size_loc'

              build/wwd.scan-BCM94343W_AVN-ThreadX-NetX/libraries/STM32F4xx.a(wiced_dct_update.o): In function `wiced_dct_update_header_to_current':

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_update.c:227: undefined reference to `dct1_start_addr_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_update.c:227: undefined reference to `dct2_start_addr_loc'

              /Users/xavieryin/Documents/WICED/WICED-Studio-4.0.1/43xxx_Wi-Fi/WICED/platform/MCU/STM32F4xx/../wiced_dct_update.c:227: undefined reference to `dct2_start_addr_loc'

              make[1]: *** [build/wwd.scan-BCM94343W_AVN-ThreadX-NetX/binary/wwd.scan-BCM94343W_AVN-ThreadX-NetX.elf] Error 1

              make: *** [main_app] Error 2

               

              I didn't modify MCU .ld files, they're all stock SDK 4.0.1

              I thought they' should be defined in places such as WICED/platform/MCU/STM32F4xx/GCC/STM32F411/*.ld like this

                   MEMORY

                   {

                       BTLDR_VECTORS    (rx)  : ORIGIN = 0x08000000, LENGTH = 512

                       SHARED_API       (rx)  : ORIGIN = 0x08000200, LENGTH = 512

                       BTLDR_CODE       (rx)  : ORIGIN = 0x08000400, LENGTH = 15K

                       DCT1_FLASH       (rx)  : ORIGIN = 0x08004000, LENGTH = 16K

                       DCT2_FLASH       (rx)  : ORIGIN = 0x08008000, LENGTH = 16K

                       APP_CODE         (rx)  : ORIGIN = 0x0800C000, LENGTH = 464K

                       SRAM             (rwx) : ORIGIN = 0x20000000, LENGTH = 128K

                       BTLDR_SRAM       (rwx) : ORIGIN = 0x2001BC00, LENGTH = 17k       /* Boot loader stack at the end. */

                   }

              And through the below expression in other .ld

                   PROVIDE( dct2_size_loc           = LENGTH( DCT2_FLASH ));

              But I still don't understand why I get "undefined reference" errors on above.

              • 4. Re: Debug writing app WWD

                Hi, JeGu_2199941,

                 

                Have you solve this problem?

                How did you solve this?

                • 5. Re: Debug writing app WWD
                  JeGu_2199941

                  I simply avoid to reference sample code "apps/wwd/xxx".

                  1 of 1 people found this helpful
                  • 6. Re: Debug writing app WWD

                    That's too bad that is not able to use wwd directly!