I have a FRDM-RW612 board, and I'm trying to run the "wifi_mqtt" example from the SDK (version 2.16.100, build 858, 2024-10-02) using MCUXpresso IDE v24.9 (currently the latest release). I'm able to build it and download it using the built-in MCU-Link. But when I run it, I get the following:
************************************************
MQTT client example
************************************************
[i] Initializing Wi-Fi connection...
[wifi_io] Error: Download firmware failed
[wifi] Error: imu_wifi_init failed. status code -1
[wlcm] Error: wifi_init failed. status code -1
[!] WPL Init failed: 1
If I enable CONFIG_WIFI_IO_DEBUG, I just get a few more lines of output. Here's the relevant code snippet:
imu_wifi_init() from wifi-imu.cimu_wifi_init() from wifi-imu.c
Commenting line 1612 has no effect. Resetting the board manually or unplugging and replugging it produces the same result. I read doc/readme.md, and it mentions "select Wi-Fi module macro in the app_config.h. (see #define WIFI_
app_config.happ_config.h
Am I doing something wrong? This should be an out-of-the-box example, I'm not sure why it's failing. Thanks.
Dana M.
Ha, nope, that was it. It would be super useful for folks if there was a mention of that specific user manual and section in the readme.md for the Wi-Fi sample projects. I've developed on NXP MCUs for a long time, but having to put a separate binary blob into flash first using a separate manual J-Link command is a new trick.
For those out there running Windows, here's a useful batch file for programming the firmware. Put it in component\conn_fwloader\fw_bin and edit the path to JLink.exe if needed.
@set JLINK="C:\Program Files\SEGGER\JLink\JLink.exe"
@set FIRMWARE="rw61x_sb_wifi_a2.bin"
@set FLASH_ADDRESS=0x08400000
@set COMMAND_FILE="jlink_command.txt"
@echo loadbin %FIRMWARE%,%FLASH_ADDRESS% > %COMMAND_FILE%
@echo quit >> %COMMAND_FILE%
%JLINK% -device RW612 -if SWD -speed 4000 -CommandFile %COMMAND_FILE%
@pauseThanks for the pointer.
Dana M.
Hi,
Could you please confirm you downloaded the Wi-Fi firmware using J-Link?
Please check section 4.1.1 in UM11799 (available in your SDK bundle).
Regards,
Daniel.