DA16200/DA16600 WiFi provisioning app 'connection to socket' problem

I'm testing the functionality of a DA16600 PMOD board and have encountered a problem with the WiFi provisioning demo using the Android app (v2.4.11) which gets stuck at stage 6 (UM-WI-042 manual) with the message 'connection to socket...' (see screen shot below). I don't know whether the app is failing to receive the list of APs from the DA16600 or if the DA16600 isn't able to see them, although when I configure it as a STA the APs are visible. Any suggestions what's wrong?

I'm using the firmware supplied with the PMOD board, SDK version = V3.2.7.1 GEN-ATCMD, F/W Version = FRTOS-GEN01-01-98e58a5d3-006374

Parents
  • Hi There,

    Thank you for posting your question online.

    Any suggestions what's wrong?

    I'm using the firmware supplied with the PMOD board, SDK version = V3.2.7.1 GEN-ATCMD

    I am not really sure if your FreeRTOS Image has the Wi-Fi Provisioning feature enabled.
    Please refer on the US159-DA16600EVZ Evaluation Board Manual (renesas.com) on page:5

    Please use a FTDI Cable (or USB to Serial converter) on J3 header in order to get access on the UART0 (Debug Console Interface).
    From the logs shown there you will understand if the Wi-Fi Provisioning is supported or not.
    Otherwise you can use the UART0 to load another firmware image that can support Wi-Fi Provisioning from the pre-compiled binaries.

    Best Regards,
    OV_Renesas

  • Thanks for getting back to me. I configured the device in SoftAP mode via the debug console (see console output below) and it connects to my phone but then hangs up at 'stage 6' of the app ('connecting to socket') with no further messages on the console.

    setup
    
    Stop all services for the setting.
     Are you sure ? [Yes/No] : y
    
    
    
    [ DA16600 EASY SETUP ]
    
    Country Code List:
    AD  AE  AF  AI  AL  AM  AR  AS  AT  AU  AW  AZ  BA  BB  BD  BE  BF  BG  BH  BL
    BM  BN  BO  BR  BS  BT  BY  BZ  CA  CF  CH  CI  CL  CN  CO  CR  CU  CX  CY  CZ
    DE  DK  DM  DO  DZ  EC  EE  EG  ES  ET  EU  FI  FM  FR  GA  GB  GD  GE  GF  GH
    GL  GP  GR  GT  GU  GY  HK  HN  HR  HT  HU  ID  IE  IL  IN  IR  IS  IT  JM  JO
    JP  KE  KH  KN  KP  KR  KW  KY  KZ  LB  LC  LI  LK  LS  LT  LU  LV  MA  MC  MD
    ME  MF  MH  MK  MN  MO  MP  MQ  MR  MT  MU  MV  MW  MX  MY  NG  NI  NL  NO  NP
    NZ  OM  PA  PE  PF  PG  PH  PK  PL  PM  PR  PT  PW  PY  QA  RE  RO  RS  RU  RW
    SA  SE  SG  SI  SK  SN  SR  SV  SY  TC  TD  TG  TH  TN  TR  TT  TW  TZ  UA  UG
    UK  US  UY  UZ  VA  VC  VE  VI  VN  VU  WF  WS  YE  YT  ZA  ZW  ALL
    
     COUNTRY CODE ? [Quit] (Default KR) : uk
    
    
    SYSMODE(WLAN MODE) ?
            1. Station
            2. Soft-AP
            3. Station & SOFT-AP
     MODE ?  [1/2/3/Quit] (Default Station) : 2
    
    [ SOFT-AP CONFIGURATION ]
    
     SSID ? (Default DA16600_3FCD4B) : Renesas_DA16200
    
     CHANNEL ? [1~13, Auto:0/Quit] (Default Auto) :
    
    
    AUTHENTICATION ?
             1. OPEN
             2. WEP(Unsupported)
             3. WPA-PSK
             4. WPA2-PSK
             5. WPA/WPA2-PSK
             6. WPA3-SAE
             7. WPA2-PSK+WPA3-SAE (Recommend)
             8. WPA3-OWE
     AUTHENTICATION ? [1/3/4/5/6/7/8/Quit] : 7
    
    
     PSK-KEY(ASCII characters 8~63) ? [Quit]
    [123456789|123456789|123456789|123456789|123456789|123456789|1234]
    :12345678
    
     Do you want to set advanced WiFi configuration ? [No/Yes/Quit] (Default No) : n
    
    ============================================
    SSID        : Renesas_DA16200
    CHANNEL     : AUTO(ACS)
    AUTH        : WPA2-PSK+SAE
    ENCRYPTION  : AES(CCMP)
    PSK/SAE KEY : 12345678
    PMF MODE    : Optional
    WIFI MODE   : 11b/g/n
    ============================================
     WIFI CONFIGURATION CONFIRM ? [Yes/No/Quit] : y
    
    
     IP ADDRESS ? [Quit] (Default 10.0.0.1) :
    
     SUBNET ? [Quit] (Default 255.255.255.0) :
    
     GATEWAY ? [Quit] (Default 10.0.0.1) :
    ============================================
    [WLAN1]
    IP ADDRESS: 10.0.0.1
    SUBNET    : 255.255.255.0
    GATEWAY   : 10.0.0.1
    ============================================
     IP CONFIGURATION CONFIRM ? [Yes/No/Quit] : y
    
    
     DHCP SERVER CONFIGURATION ? [Yes/No/Quit] : y
    
    
     DHCP SERVER LEASE IP Count(MAX 10) ? [Quit] (Default 10) :
    
     DHCP SERVER LEASE TIME(60 ~ 86400 SEC) ? [Quit] (Default 1800) :
    ============================================
    [DHCP SERVER]
    Start IP  : 10.0.0.2
    END IP    : 10.0.0.11
    LEASE TIME: 1800
    ============================================
    
     DHCP SERVER CONFIGURATION CONFIRM ? [Yes/No/Quit] : y
    
    Configuration OK
    
    Reboot...
    
    Reset BLE ...
    
    Wakeup source is 0x0
    [dpm_init_retmemory] DPM INIT CONFIGURATION(1)
    
    
            ******************************************************
            *             DA16600 SDK Information
            * ---------------------------------------------------
            *
            * - CPU Type        : Cortex-M4 (120MHz)
            * - OS Type         : FreeRTOS 10.4.3
            * - Serial Flash    : 4 MB
            * - SDK Version     : V3.2.7.1 GEN-ATCMD
            * - F/W Version     : FRTOS-GEN01-01-98e58a5d3-006374
            * - F/W Build Time  : Apr 13 2023 13:54:57
            * - Boot Index      : 0
            *
            ******************************************************
    
    gpio wakeup enable 00000402
    [combo][iot_sensor]
       is_provisioned = 0
       is_sensor_started = 0
    [combo] dpm_boot_type = 0
    
    >>> UART1 : Clock=80000000, BaudRate=115200
    >>> UART1 : DMA Enabled ...
    [combo] BLE_BOOT_MODE_0
    invalid Product Header, program multi-part image again !
    Error Initialization of DA14531, freeRTOS, err_code = -5
    
    
    System Mode : Soft-AP (1)
    
    >>> DHCP Server Started
    >>> Start DA16X Supplicant ...
    >>> DA16x Supp Ver2.7 - 2022_03
    >>> Add SoftAP Inteface (softap1) ...
    >>> MAC address (softap1) : d4:3d:39:3f:cd:4b
    >>> softap1 interface add OK
    >>> AP Operating Channel: AUTO
    by default, rf_meas_btcoex(1, 0, 0)
    
    >>> UART2 : Clock=80000000, BaudRate=115200
    >>> UART2 : DMA Enabled ...
    >>> Soft-AP ACS : ideal ch is 13
    
    >>> Network Interface (wlan1) : UP
    >>> BSS Isolate Disabled
    
    Soft-AP is Ready (d4:3d:39:3f:cd:4b)
    AP-STA-CONNECTED 68:c4:4d:31:27:f8
    
    ### User Call-back : Success to connect Wi-Fi ...

  • Hi There,

    Thank you for the reply.

    so you're saying it can't do that with the app?

    For the DA16600MOD, the Wi-Fi Provisioning app is designed to do the Provisioning via the BLE.
    Yes, the DA16200 is able to do the Provisioning mode in SoftAP.

    I'd be interested to know what the difference is since the DA16600 contains a DA16200.

    We have designed it this way, because it is considered more "secure" to do the initial provisioning via BLE instead of Wi-Fi.
    Please check the __SUPPORT_WIFI_PROVISIONING__ macro. When it is defined we can use the Wi-Fi Provisioning.
    Please open the DA16200 getting started project and the DA16600 getting started project. 
    If you follow this macro you can find the implementation for both. 
    You could just replace the implementation from the DA16200 on your DA16600 project that it would not utilize BLE.

    Best Regards,
    OV_Renesas

  • Thanks for the guidance - I'm still on a steep learning curve with the SDK! I tried enabling __SUPPORT_WIFI_PROVISIONING__ in config_generic_sdk.h and got the following error on rebuilding, presumably due to some conflict with the existing BLE provisioning code?

    E:/Programming/DA16200_DA16600_SDK_FreeRTOS_v3.2.8.1/apps/app_common/src/provisioning/app_provisioning_sample.c:800: multiple definition of `app_check_internet_with_ping'; ./customer_app/src/ble_svc/provision/src/app_provisioning_sample.o:E:/Programming/DA16200_DA16600_SDK_FreeRTOS_v3.2.8.1/apps/da16600/get_started/src/ble_svc/provision/src/app_provisioning_sample.c:151: first defined here
    collect2.exe: error: ld returned 1 exit status
    make[1]: *** [makefile:247: da16600.elf] Error 1
    make: *** [makefile:238: all] Error 2
    "make -r all" terminated with exit code 2. Build might be incomplete.

  • further to my previous question, is there an simple SDK configuration macro that would disable the BLE functionality and make the DA16600 behave as a DA16200?

  • Hi There,

    Thank you for the reply.
    Please check for any multiple definitions of the same macro inside your project.

    is there an simple SDK configuration macro that would disable the BLE functionality and make the DA16600 behave as a DA16200?

    You can just download the DA16200 image that you want on your DA16600, and make sure you have erased the DA14531 (BLE) image. The DA16600 will then behave like the DA16200.

    Best Regards,
    OV_Renesas

  • Thanks - I erased the entire flash with the 'sflash erase 0 400000’ command from the MROM prompt (which presumably ensures the DA14531 is erased, as you advised) and then succesfully programmed it with the DA16200_IMG_ATCMDSET_v3.2.3.0 image.

    It seems to now operate as a DA16200, although when setup in SoftAP mode the WiFi provisioning app connects OK but then won't display the available APs for some reason. 

  • I also generated a DA16200 image from the SDK with __SUPPORT_WIFI_PROVISIONING__defined, but the WiFi provisioning app still hangs at the stage where it should display the AP list.

  • Hi There,

    Thank you for the reply.
    Could you please share the full UART0 logs?
    Please use the SDK v3.2.8.1 and work with the DA16200 getting started example which has the Wi-Fi Provisioning enabled by default.

    Best Regards,
    OV_Renesas

  • The problem seems to be with the Wi-Fi provisioning app running on my phone (Android 8) as I've just discovered it does work on a phone running Android 13, although the documentation for the app suggests it should work with Android 5.0 and later.

  • Hi KSW,

    Thank you for the reply.
    On the Google PlayStore I checked the Renesas WiFiProvisioning mobile application:

    As you can see, it is available for Android 8.1 and up.

    Best Regards,
    OV_Renesas

  • My old phone is actually 8.1.0 so that doesn't explain why it doesn't work... Anyway, it's good to know that it's the phone app that's the problem rather than a problem with the DA16600/DA16200 firmware!

Reply Children
No Data