2021-11-29 03:06 PM
Hi,
I have been writing drivers for the ISM43341-M4G-L44-SPI WiFi module mounted on the STM32H7BI3-DK.
I can send the device AT commands and get back the OK response, but after setting the network parameters SSID, password, security mode, DHCP after issuing the Join Network command "C0" the module ready line goes low and never sets back to ready.
Overall Response of C0 Cmd
SPI Bus Detail of C0 Cmd
I sent an "I?" command to find the software revision of the WiFi Module and this works fine:
When I use the "I?" command to retrieve the Revision Information using the "RM" command I get:
{ISM43341-M4G-L44-SPI,C3.5.2.6.STM,v3.5.2,v1.4.0.rc1,v8.2.1,144000000, Inventek eS-WiFi
OK
>}
The curly brackets I have added for clarity.
So I am confident the SPI bus is working OK
I have written to the manufacturer of the WiFi module (Inventek), but haven't heard back yet?
I've used a couple of AT WiFi modules, LPB100 and one I can't remember the part number fo in the past both of which used a serial port for processor side comms without any difficulties so I am at a loss why I can't get the Inventek one to work.
Any how I have attached my project to this post. It uses the Cube IDE and should NOT work out of the box.
I had to use a modified HAL Spi driver for the Transmit-Receive. As I am using DMA and the SPI peripheral NSS signal is not wired to the WiFi module you have to use PA11 the HAL_SPI_TransmitReceive function doesn't enable the end of frame interrupt which is required to control the surrogate NSS pin. (I wish the writers of HAL would provide control over the interrupts through the SPI handle so the applications programmer has options.)
In any event I really have only one question: Why doesn't it work.
Hoping someone has more luck than I did. Two days work and nothing to show for it.
Best regards
Rob
Solved! Go to Solution.
2021-12-13 05:14 AM
Hello
There is an example of use of WiFi on STM32H7B3I-DK in STM32H7 Cube SW package in Projects\STM32H7B3I-DK\Demonstrations\ClockAndWeather.
See files Core\Src\net_conf_es_wifi_spi.c, Core\Inc\net_conf_es_wifi_spi.h. Also from top level : Drivers\BSP\Components\es_wifi\*.c *.h, Middlewares\ST\STM32_Network_Library\*
Regarding the Join problem, there *may* be a problem if your WiFi access point uses 2.4 GHz Wifi channel number higher than channel 11.
By default the Inventek Firmware is configured to be in "US" country which forbids WiFi channels higher than 11.
if it is the case, then you have to set the Country to something other than US. it's Inventek AT command "CN". Use "CN=?" to know which values are acceptable. Try something like CN=CA/0 or CN=FR/0. Or change the channel on your WiFi access point to something lower than 12.
2021-12-13 05:14 AM
Hello
There is an example of use of WiFi on STM32H7B3I-DK in STM32H7 Cube SW package in Projects\STM32H7B3I-DK\Demonstrations\ClockAndWeather.
See files Core\Src\net_conf_es_wifi_spi.c, Core\Inc\net_conf_es_wifi_spi.h. Also from top level : Drivers\BSP\Components\es_wifi\*.c *.h, Middlewares\ST\STM32_Network_Library\*
Regarding the Join problem, there *may* be a problem if your WiFi access point uses 2.4 GHz Wifi channel number higher than channel 11.
By default the Inventek Firmware is configured to be in "US" country which forbids WiFi channels higher than 11.
if it is the case, then you have to set the Country to something other than US. it's Inventek AT command "CN". Use "CN=?" to know which values are acceptable. Try something like CN=CA/0 or CN=FR/0. Or change the channel on your WiFi access point to something lower than 12.
2021-12-17 12:32 AM
Hi,
Thanks very much for that. I hadn't thought about the channel numbers - silly me.
I checked my router on my android phone and found it is running on channel 13. So there's a very good chance that the channel is the problem.
I will have a crack at it next week and let you know how I get on.
I will also have a look at the example.
I will let you know how I get on.
I hope I can get it working as I don't want to have to retrofit a different wi fi module.
Best regards
Rob
2021-12-17 10:09 PM
Hi Guillaume K,
I used the CN command to set the Country Code to "AU", but this was rejected as "Unknown."
It turns out the latest firmware only supports: C3.5.2.5 or greater now limited to CR,FR(EU),US,JP(43362 only).
Fortunately Australia uses 1-13 like the EU so setting the country code to FR(ance) got everything going.
Again thanks for your help.
Best regards
Rob