nrf7002ek and nrf52840Dk

Hi All!

I am trying to connect with static SSID & password to connect with the wififund_less2_exer2_solution

Ncs 2.5.2 and vscode studio , Dk's are nrf52840Dk with nrf7002EK

I also tried wifi_provisioning example as well as used the andriod app to provision using BLE .

Both have the same response!

I entered the correct SSID and password.

Uart terminal output with error code is -134

and

cmakelist.txt

cmake_minimum_required(VERSION 3.20.0)


set(SHIELD nrf7002ek)   #added


find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(wifi_fundamentals)

target_sources(app PRIVATE src/main.c)

prj.conf

#
# Copyright (c) 2022 Nordic Semiconductor ASA
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

# Wi-Fi
# STEP 1.1 - Enable the Wi-Fi relevant configurations
CONFIG_WIFI=y
CONFIG_WIFI_NRF700X=y
CONFIG_WPA_SUPP=y
# STEP 2 - Configure the Wi-Fi credentials
CONFIG_WIFI_CREDENTIALS=y
# STEP 12.1 - Diasble static Wi-Fi network configuration
CONFIG_WIFI_CREDENTIALS_STATIC=y
CONFIG_WIFI_CREDENTIALS_STATIC_SSID="NETGEAR06"
CONFIG_WIFI_CREDENTIALS_STATIC_PASSWORD="bxxxxxxxxx41"


# Networking Management API
# STEP 1.2 Enable the Network Management relevant configurations
CONFIG_NET_MGMT=y
CONFIG_NET_MGMT_EVENT=y
CONFIG_NET_MGMT_EVENT_INFO=y
CONFIG_NET_MGMT_EVENT_STACK_SIZE=4096
CONFIG_NET_CONNECTION_MANAGER=y
CONFIG_WIFI_MGMT_EXT=y

# STEP 12.3 Enable support for shell commands
CONFIG_SHELL=y
CONFIG_WIFI_CREDENTIALS_SHELL=y
CONFIG_SHELL_STACK_SIZE=4096

# Logging
CONFIG_LOG=y

# DK library
CONFIG_DK_LIBRARY=y

# System settings
CONFIG_NEWLIB_LIBC=y
CONFIG_NEWLIB_LIBC_NANO=n

# Networking
CONFIG_NETWORKING=y
CONFIG_NET_NATIVE=y
CONFIG_NET_SOCKETS=y
CONFIG_NET_L2_ETHERNET=y
CONFIG_NET_IPV6=n
CONFIG_NET_IPV4=y
CONFIG_NET_DHCPV4=y

# Memory
CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=4096
CONFIG_MAIN_STACK_SIZE=4096
CONFIG_HEAP_MEM_POOL_SIZE=153600

Thanks & Regards,

Muhammad Usman

Parents Reply Children
  • Hi Elfving 

    When I tried the Wifi-Station example, it worked for me! 

    [00:00:06.752,166] <ESC><inf> sta: State: SCANNING<ESC><CR><LF>
    [00:00:07.052,551] <ESC><inf> sta: ==================<ESC><CR><LF>
    [00:00:07.052,581] <ESC><inf> sta: State: SCANNING<ESC><CR><LF>
    [00:00:07.352,722] <ESC><inf> sta: ==================<ESC><CR><LF>
    [00:00:07.352,752] <ESC><inf> sta: State: SCANNING<ESC><CR><LF>
    [00:00:07.652,862] <ESC><inf> sta: ==================<ESC><CR><LF>
    [00:00:07.652,893] <ESC><inf> sta: State: SCANNING<ESC><CR><LF>
    [00:00:07.953,002] <ESC><inf> sta: ==================<ESC><CR><LF>
    [00:00:07.953,033] <ESC><inf> sta: State: AUTHENTICATING<ESC><CR><LF>
    [00:00:08.093,505] <ESC><inf> sta: Connected<ESC><CR><LF>
    [00:00:08.149,963] <ESC><inf> net_config: IPv6 address: fe80::f6ce:36ff:fe00:4e73<ESC><CR><LF>
    [00:00:08.152,038] <ESC><inf> net_dhcpv4: Received: 192.168.1.9<ESC><CR><LF>
    [00:00:08.152,191] <ESC><inf> net_config: IPv4 address: 192.168.1.9<ESC><CR><LF>
    [00:00:08.152,191] <ESC><inf> net_config: Lease time: 86400 seconds<ESC><CR><LF>
    [00:00:08.152,252] <ESC><inf> net_config: Subnet: 255.255.255.0<ESC><CR><LF>
    [00:00:08.152,313] <ESC><inf> net_config: Router: 192.168.1.1<ESC><CR><LF>
    [00:00:08.152,404] <ESC><inf> sta: DHCP IP address: 192.168.1.9<ESC><CR><LF>
    [00:00:08.257,141] <ESC><inf> sta: ==================<ESC><CR><LF>
    [00:00:08.257,171] <ESC><inf> sta: State: COMPLETED<ESC><CR><LF>
    [00:00:08.257,202] <ESC><inf> sta: Interface Mode: STATION<ESC><CR><LF>
    [00:00:08.257,232] <ESC><inf> sta: Link Mode: WIFI 6 (802.11ax/HE)<ESC><CR><LF>
    [00:00:08.257,263] <ESC><inf> sta: SSID: NETGEAR06<ESC><CR><LF>
    [00:00:08.257,293] <ESC><inf> sta: BSSID: C8:9E:43:73:08:8B<ESC><CR><LF>
    [00:00:08.257,324] <ESC><inf> sta: Band: 2.4GHz<ESC><CR><LF>
    [00:00:08.257,324] <ESC><inf> sta: Channel: 2<ESC><CR><LF>
    [00:00:08.257,354] <ESC><inf> sta: Security: WPA2-PSK<ESC><CR><LF>
    [00:00:08.257,385] <ESC><inf> sta: MFP: Optional<ESC><CR><LF>
    [00:00:08.257,385] <ESC><inf> sta: RSSI: -33<ESC><CR><LF>
    [00:00:09.069,885] <ESC><inf> net_config: IPv6 address: 2601:1c0:5002:ccb0:f6ce:36ff:fe00:4e73<ESC><CR><LF>

    Can you please help me to find out the issue in the Nordic Academy example code I want to use other examples in my project. They are easy to understand and use.

    Thanks & Regards,

    Muhammad Usman

  • Muhammad Usman said:

    yes , right credentials added in default with the folliowing line added in the cmakelist.txt as well "set(SHIELD nrf7002ek)

    That should work.

    Muhammad Usman said:

    One more observation is that , when i used ncs2.6.0 then i got following error related to ram overflow 

    phyr-eabi/bin/ld.bfd.exe: region `RAM' overflowed by 35564 bytes.

    To compile with ncs 2.6.0 I disabled the following 

    I would assume it should work with multiple versions of NCS, 2.6.0 as well, though the course was tested with 2.5.0, and there might be some additions to the Wi-Fi stack that has made it require a bit more RAM in 2.6.0. 

    I guess this is why it says that this course is only supported on the nRF7002DK, or the nRF5340DK with an nRF7EK. It needs the additional RAM that the 53 provides.

    Though as you've found out, multiple samples work on the nRF52840.

    Do you have a nRF5340DK you could use?

    Regards,

    Elfving

  • Hi Elfving!

    Thank you for the response!

    Do you have a nRF5340DK you could use?

    sorry, I don't have it as we are required to use nrf52840 because of its 8dbm output power.

     One more observation I tried a wifi-provisioning example with ncs2.5.2/2.5.0/2.4.0 and nrf52840dk+nrf7002ek.

    However, this sample supports the DK I have. But I got the following serial output.

    *** Booting nRF Connect SDK v2.5.0 ***<CR><LF>
    [00:00:00.248,260] <ESC><inf> net_config: Initializing network<ESC><CR><LF>
    [00:00:00.248,291] <ESC><inf> net_config: Waiting interface 1 (0x200018c0) to be up...<ESC><CR><LF>
    [00:00:00.248,443] <ESC><inf> net_config: IPv4 address: 192.165.100.150<ESC><CR><LF>
    [00:00:00.248,474] <ESC><inf> net_config: Running dhcpv4 client...<ESC><CR><LF>
    [00:00:01.248,962] <ESC><inf> bt_sdc_hci_driver: SoftDevice Controller build revision: <CR><LF>
                                                c5 93 ba a9 14 4d 8d 05  30 4e 9b 92 d7 71 1e e8 |.....M.. 0N...q..<CR><LF>
                                                aa 02 50 3c                                      |..P<             <ESC><CR><LF>
    [00:00:01.251,342] <ESC><inf> bt_hci_core: HW Platform: Nordic Semiconductor (0x0002)<ESC><CR><LF>
    [00:00:01.251,373] <ESC><inf> bt_hci_core: HW Variant: nRF52x (0x0002)<ESC><CR><LF>
    [00:00:01.251,403] <ESC><inf> bt_hci_core: Firmware: Standard Bluetooth controller (0x00) Version 197.47763 Build 2370639017<ESC><CR><LF>
    [00:00:01.252,410] <ESC><inf> bt_hci_core: Identity: F9:E4:7B:5A:9B:1A (random)<ESC><CR><LF>
    [00:00:01.252,441] <ESC><inf> bt_hci_core: HCI: version 5.4 (0x0d) revision 0x1102, manufacturer 0x0059<ESC><CR><LF>
    [00:00:01.252,471] <ESC><inf> bt_hci_core: LMP: version 5.4 (0x0d) subver 0x1102<ESC><CR><LF>
    Bluetooth initialized.<CR><LF>
    Wi-Fi provisioning service starts successfully.<CR><LF>
    BT Advertising successfully started.<CR><LF>
    [00:00:01.253,570] <ESC><err> net_sock: invalid access on sock 536956416 by thread 0x20004a68<ESC><CR><LF>
    BT Connected: 58:2D:17:07:A0:18 (random)BT Disconnected: 58:2D:17:07:A0:18 (random) (reason 0x13).<CR><LF>
    BT Connected: 50:A7:2C:69:07:F6 (random)BT pairing completed: 50:A7:2C:69:07:F6 (random), bonded: 0<CR><LF>
    BT Security changed: 50:A7:2C:69:07:F6 (random) level 2.<CR><LF>
    [00:00:47.834,259] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - control point: indications enabled<ESC><CR><LF>
    [00:00:48.104,248] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - data out: notifications enabled<ESC><CR><LF>
    [00:00:48.599,273] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:00:48.599,304] <ESC><inf> wifi_prov: GET_STATUS received...<ESC><CR><LF>
    [00:00:50.084,167] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:00:50.084,197] <ESC><inf> wifi_prov: Start_Scan received...<ESC><CR><LF>
    [00:00:56.024,047] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:00:56.024,078] <ESC><inf> wifi_prov: Stop_Scan received...<ESC><CR><LF>
    [00:01:12.224,090] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:01:12.224,121] <ESC><inf> wifi_prov: Set_config received...<ESC><CR><LF>
    [00:01:46.738,433] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:01:46.738,464] <ESC><inf> wifi_prov: Set_config received...<ESC><CR><LF>
    [00:01:47.728,424] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:01:47.728,454] <ESC><inf> wifi_prov: Set_config received...<ESC><CR><LF>
    [00:01:52.993,164] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - control point: indications disabled<ESC><CR><LF>
    [00:01:52.993,225] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - data out: notifications disabled<ESC><CR><LF>
    BT Disconnected: 50:A7:2C:69:07:F6 (random) (reason 0x13).<CR><LF>
    BT Connected: 47:EE:3E:95:41:C8 (random)BT Disconnected: 47:EE:3E:95:41:C8 (random) (reason 0x13).<CR><LF>
    BT Connected: 4D:4D:DF:A5:79:D9 (random)BT pairing completed: 4D:4D:DF:A5:79:D9 (random), bonded: 0<CR><LF>
    BT Security changed: 4D:4D:DF:A5:79:D9 (random) level 2.<CR><LF>
    [00:02:11.307,769] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - control point: indications enabled<ESC><CR><LF>
    [00:02:11.487,762] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - data out: notifications enabled<ESC><CR><LF>
    [00:02:11.847,808] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:02:11.847,839] <ESC><inf> wifi_prov: GET_STATUS received...<ESC><CR><LF>
    [00:02:14.187,683] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:02:14.187,713] <ESC><inf> wifi_prov: Start_Scan received...<ESC><CR><LF>
    [00:02:20.667,572] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:02:20.667,602] <ESC><inf> wifi_prov: Stop_Scan received...<ESC><CR><LF>
    [00:02:36.597,656] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:02:36.597,686] <ESC><inf> wifi_prov: Set_config received...<ESC><CR><LF>
    [00:02:44.697,509] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:02:44.697,540] <ESC><inf> wifi_prov: Set_config received...<ESC><CR><LF>
    [00:02:54.192,321] <ESC><inf> wifi_prov: Start parsing...<ESC><CR><LF>
    [00:02:54.192,352] <ESC><inf> wifi_prov: Set_config received...<ESC><CR><LF>
    [00:14:16.739,624] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - control point: indications disabled<ESC><CR><LF>
    [00:14:16.739,685] <ESC><inf> wifi_prov: Wi-Fi Provisioning service - data out: notifications disabled<ESC><CR><LF>
    BT Disconnected: 4D:4D:DF:A5:79:D9 (random) (reason 0x08).<CR><LF>

    and android app 

    The only change I made is to add 

    set(SHIELD nrf7002ek)        // in cmakelists.txt of the original sample 

    Can you please help me where is the issue?

    when I compared this sample with the nanopb sample, I was unable to find out the 

    #include <pb_encode.h>
    #include <pb_decode.h>
                     &
    decode_message()
                    and
    encode_message
    functions in the wifi-provisioning example.is it related to nanopb configuration and cmakelists.txt files?
    Can you please help me with how to configure that if this is the issue?
    Thanks & Regards,
    Muhammad Usman

  • Hello again

    Sorry about the wait, Easter is a public Holiday in Norway.

    Muhammad Usman said:

    sorry, I don't have it as we are required to use nrf52840 because of its 8dbm output power.

    Understood. 

    So you get this output immediately with, when flashing the unmodified wifi-provisioning example (besides the modification of adding the nRF7 shield to cmakelists)?

    I just tried this myself in NCS 2.5.2, and I am not getting exactly that. Though I am bit uncertain if this might be due to some OTP programming of the nRF7. Could you try flashing this hex I've built, and see if you see the same issue you saw on your side?

    test.hex

    Regards,

    Elfving

Related