ST意法半导体
直播中

李雷

8年用户 196经验值
私信 关注
[问答]

软件检查hw引脚是否可以正常运行

你好!
我想问一下,在使用我的SPWF04SA激活miniAP时我做错了什么。我已经阅读了SPWF04SA的数据表,UM2114,AN4964以及大多数“SPWF04SA模块上的WiFi培训手册”,pdf。我有2-3个模块IDW04A1和几个NUCLEO-L053R8板。开始时我刚刚抓住USB转串口转换器(FTDI)并用它与IDW04A1模块通信。通信正常后,我下载了''Flash Loader Demonstrator''版本2.8并通过UART SPWF04SA的固件更新。安装的固件是“SPWF04S-171117-0328fe3-Release.hex”。在STSW_WIFI004文件夹中,我看到了''SPWF04S-171117-0328fe3-Full.hex''文件。这个文件是否与''SPWF04S-171117-0328fe3-Release.hex'相同? (无论如何,我还没有尝试过这个)。
接下来我尝试了一些基本命令和一些python脚本与AT命令和u***2serial转换器设置,一切正常。但是当我尝试设置miniAP时,它根本没有用。经过多次尝试,复位和出厂默认复位后,我在NUCLEO-L053R8板上连接IDW04A1,miniAP模式首次尝试使用。庆祝我的成功10分钟后,我决定再次切换到我的简单的u***2serial转换器。该模块回应它已启动miniAP但我的智能手机和笔记本电脑无法找到我的miniAP。我还要提一下,我已经使用了9600和115200波特率的模块。我附上了我用过的设置照片。并且设置miniAP的代码对于我使用的每个设置都是相同的。
码:
AT + S.SCFG = console_enabled,第2版; CR> //我使用过这个,因为我想在设置miniAP后尝试使用uP。 (我认为console_enabled,2不会影响miniAP功能)
AT + S.WIFI = 0℃; CR>
AT + S.SSIDTXT = SP_DemoAP< CR>
AT + S.SCFG = wifi_mode,第3版; CR>
AT + S.SCFG = wifi_priv_mode,0℃; CR>
AT + S.WCFG< CR>
AT + S.WIFI = 1·; CR>
AT< CR>
AT + S.WCFG< CR> //保存Configs以便在每次重置模块进入miniAP模式后按顺序保存WIFI = 1配置。
这些是通过我的PC串行终端在两种设置中使用的AT命令。
我正在添加以下文本文件。在使用AT + S.FCFG< CR>重置为出厂默认配置之后,它们是具有模块的串行通信。命令。此外,我还添加了“SPWF04SA序列响应”之后生成的配置和状态列表。
总结一下:

我想知道我要安装哪个FW。 ('''SPWF04S-171117-0328fe3-Release.hex''或''SPWF04S-171117-0328fe3-Full.hex'')NUCLEO-L053R8 FW为SPWF04SA设置的其他配置是否还没有? !
我想实现这个目标:
1)软件检查(hw引脚)是否可以正常运行或在配置模式下启动

2)如果照常营业没什么特别的;使用uP示例代码
3)如果配置模式:
启动SPWF04SA访问点并启动显示现有SSID,密码和授权代码的Web页面。修改这些值并将值存储在FLASH或EEPROM4中。重置并重新进行。
此致,K.Ifantidis。

#miniap#access-point #spwf04 #password#uart-set-up #uart #ssid #problem #usart

以上来自于谷歌翻译


以下为原文




Hello there!
I would like to ask what i'm doing wrong in activating the miniAP with my SPWF04SA. I've read SPWF04SA's datasheet, UM2114, AN4964 and most of ''WiFi Training Hands on SPWF04SA module'' pdf. I have 2-3 modules IDW04A1 and a couple NUCLEO-L053R8 boards. In the beginning i just grabbed a USB to Serial converter (FTDI) and used it to communicate with the IDW04A1 module. After communication was OK, i downloaded ''Flash Loader Demonstrator'' version 2.8 and updated via UART SPWF04SA's firmware. The firmware installed is ''SPWF04S-171117-0328fe3-Release.hex''. In the STSW_WIFI004 folder i saw ''SPWF04S-171117-0328fe3-Full.hex'' file. Is this file the same as ''SPWF04S-171117-0328fe3-Release.hex'' ?? (Anyway i haven't tried this one yet).
Next i tried some basic commands and some python scripting with AT commands and u***2serial converter setup and everything worked. But when i tried to setup a miniAP, it didn't work out at all. After many tries, resets, and factory default resets I hooked up IDW04A1 on NUCLEO-L053R8 board and miniAP mode worked with first try. After 10 minutes of celebrating of my success i decided to switch again to my humble u***2serial converter. The module responded that it had started the miniAP but my smartphone and laptop weren't able to find my miniAP. I would like to mention also that i have used the module in 9600 and in 115200 baud rates. I have attached photos with the setups that i have used. And the code for setting the miniAP which was the same for every setup that I've used.
Code:
AT+S.SCFG=console_enabled,2 // I used thisone because i wanted to experiment with uP after setting the miniAP. (I think console_enabled,2 doesn't affect the miniAP feature)
AT+S.WIFI=0
AT+S.SSIDTXT=SP_DemoAP
AT+S.SCFG=wifi_mode,3
AT+S.SCFG=wifi_priv_mode,0
AT+S.WCFG
AT+S.WIFI=1
AT
AT+S.WCFG // I saved Configs in order to save WIFI=1 configuration in order after every reset the module to enter in miniAP mode.
Those are the AT commands that i have used in both setups via my PC serial terminal.
I'm adding the following text files. They are the Serial comm with the module after resetting to factory default configurations with AT+S.FCFG command. Also I've added the configuration and status lists which I've generated right after the ''SPWF04SA SERIAL RESPONSE''.
To summarize:

I would like to know which FW I've to install. (''SPWF04S-171117-0328fe3-Release.hex'' or ''SPWF04S-171117-0328fe3-Full.hex'') Is there any other configuration that NUCLEO-L053R8 FW sets up for the SPWF04SA that I haven't  ?!
I want to achieve this:
1) software checks (hw pin) whether is can run business as usual or start-up in the configuration mode

2) If Business as usual nothing special; use uP example code
3) If configuration mode:
  Start SPWF04SA access-point and launch web-page showing the existing SSID, password and authorisation code. Modify these values and store the values in FLASH or in EEPROM4) Reset and go all over again.
Best regards, K.Ifantidis.

#miniap #access-point #spwf04 #password #uart-set-up #uart #ssid #problem #usart

回帖(5)

刘倩

2019-2-27 14:53:20
嗨康斯坦丁诺斯,
你的系统内存不足:
AT-S.Var:free_heap = 6848
AT-S.Var:min_heap = 80
我建议根据你的需要减少ramdisk_memsize和python_memsize的数量

以上来自于谷歌翻译


以下为原文




Hi Konstantinos,
your system is running low on memory:
AT-S.Var:free_heap=6848
AT-S.Var:min_heap=80
I suggest to reduce the amount of ramdisk_memsize and python_memsize, according to your needs
举报

李雷

2019-2-27 15:09:31
另外,我想在连接NUCLEO-L053R8时添加模块的响应

以上来自于谷歌翻译


以下为原文




Also i would like to add the response of the module when connecting with NUCLEO-L053R8
举报

李雷

2019-2-27 15:17:27
你好Elio。
我还在学习如何处理这块板子。而我还没有弄清楚如何管理内存。
 
我应该从FS中删除一些文件,这是什么意思?我在那里安装了默认设置:AT + S.FSL
AT-S.Free RAM磁盘:15360
AT-S.File:我4281 config.fhtml
AT-S.File:I 676 favicon.gz.ico
AT-S.File:I 697 firstset.gz.html
AT-S.File:我401 index.gz.html
AT-S.File:I 252 input_demo.fhtml
AT-S.File:我432 MULTI_CLIENT_SERVER.py
AT-S.File:I 290 output_demo.gz.html
AT-S.File:我1719 peers.fhtml
AT-S.File:I 894 remote.gz.html
AT-S.File:我2390 RL_TCP_CL.py
AT-S.File:我2689 RL_TCP_SE.py
AT-S.File:I 2696 RL_TCP_SE_GC_COLLECT.py
AT-S.File:I 2360 RL_UDP_CL.py
AT-S.File:我2688 RL_UDP_SE.py
AT-S.File:我1768 status.fhtml
AT-S.File:I 4134 stlogo.gz.jpg
AT-S.File:I 897 WLAN.py
AT-S.File:I 1024 WLAN.STA.py
AT-S.OK
我还有一个问题是:FS中我的SPWF04SA的关键文件是什么?我需要所有这些文件还是仅需2-3个文件?
此致,K.Ifantidis。

以上来自于谷歌翻译


以下为原文




Hello Elio.
I'm still learning how to handle this board. And i haven't figured out yet how to manage with the memory.

Shall i delete some files from the FS, is that what you mean? I have the defaults installed there: AT+S.FSL
AT-S.Free RAM Disk:15360
AT-S.File:I 4281 config.fhtml
AT-S.File:I 676 favicon.gz.ico
AT-S.File:I 697 firstset.gz.html
AT-S.File:I 401 index.gz.html
AT-S.File:I 252 input_demo.fhtml
AT-S.File:I 432 MULTI_CLIENT_SERVER.py
AT-S.File:I 290 output_demo.gz.html
AT-S.File:I 1719 peers.fhtml
AT-S.File:I 894 remote.gz.html
AT-S.File:I 2390 RL_TCP_CL.py
AT-S.File:I 2689 RL_TCP_SE.py
AT-S.File:I 2696 RL_TCP_SE_GC_COLLECT.py
AT-S.File:I 2360 RL_UDP_CL.py
AT-S.File:I 2688 RL_UDP_SE.py
AT-S.File:I 1768 status.fhtml
AT-S.File:I 4134 stlogo.gz.jpg
AT-S.File:I 897 WLAN.py
AT-S.File:I 1024 WLAN.STA.py
AT-S.OK
And an other question I have is: What are the Critical Files for my SPWF04SA in the FS ? Do i need all of those files or just 2-3 of them?
Regards, K.Ifantidis.
举报

刘倩

2019-2-27 15:36:11
“你的系统内存不足”这句话必须是'你的系统在系统RAM内存上运行不足'(free_heap status var显示的那个; min_heap显示系统RAM内存达到的绝对最小值)
我建议减少ramdisk_memsize和python_memsize的数量,因为它们都在系统RAM中分配。
ram磁盘(磁盘'3'或'D')大小由ramdisk_memsize cfg var定义,并从系统RAM中消耗大约两倍的值:如果您的应用程序可以使用较小的ramdisk,那么您可以将ramdisk_memsize设置为较小的值(0完全禁用ramdisk,2是从python执行网络扫描时建议的最小值。
同样,当启用uPython时,在启动时从系统RAM分配等于python_memsize的数量。此内存空间用于uPython堆栈,应用程序和结构,而TCP / IP堆栈使用的内存仍然在系统RAM中分配,即使使用python套接字/ wsocket / mqtt / http模块也是如此。 free / used python内存可以通过特定的python函数显示(即gc.mem_free,gc.mem_alloc):你可以相应地减少python_memsize并释放系统RAM资源。
在您的情况下,AT + S.FSL仅显示带有“I”前缀的文件。这些文件存储在Application Flash磁盘中,不占用系统RAM。
设置ramdisk_memsize = 12和python_memsize = 32应允许运行Open MiniAP:尝试在重置IDW04A1时按住SW2以在Open MiniAP中启动SPWF04并验证配置是否正常(+ WIND:26:启动AP:iwm-BD-D1-7A应该显示为您的IDW04A1)。
关于你的问题'我想知道我要安装哪个FW。 ('SPWF04S-171117-0328fe3-Release.hex'或'SPWF04S-171117-0328fe3-Full.hex')':
- SPWF04S-171117-0328fe3-Release.hex仅包含SPWF04的FW
- SPWF04S-171117-0328fe3-Full.hex包含bootloader + FW +默认应用程序闪存盘
您还可以使用以下帖子作为进一步的信息来源。

以上来自于谷歌翻译


以下为原文




The statement 'your system is running low on memory' must be read 'your system is running low on system RAM memory' (the one shown by free_heap status var; min_heap show the absolute min reached by system RAM memory)
I suggested to decrease the amount of ramdisk_memsize and python_memsize because both of them are allocated in system RAM.
ram disk (disk '3' or 'D') size is defined by ramdisk_memsize cfg var, and consume about twice that value from system RAM: if your application can work with a smaller ramdisk then you can set ramdisk_memsize to a smaller value (0 disable the ramdisk at all, 2 is the suggested minimum when the network scan is performed from python).
The same way, when uPython is enabled an amount equal to python_memsize is allocated from system RAM at boot time. This memory space is used for uPython stack, application and structure, while the memory used by TCP/IP stack is still allocated in system RAM even when python sockets/wsocket/mqtt/http modules are used. The free/used python memory can be displayed by specific python functions (i.e. gc.mem_free, gc.mem_alloc): you can reduce python_memsize accordingly and free system RAM resources.
In your case AT+S.FSL show only file with 'I' prefix. Those files are stored in the Application Flash disk and do not consume system RAM.
Setting ramdisk_memsize=12 and python_memsize=32 should allow running Open MiniAP: try keeping SW2 pressed while resetting IDW04A1 to boot SPWF04 in Open MiniAP and verify the configuration is ok (+WIND:26:Started AP:iwm-BD-D1-7A should be displayed for your IDW04A1).
About your question 'I would like to know which FW I've to install. ('SPWF04S-171117-0328fe3-Release.hex' or 'SPWF04S-171117-0328fe3-Full.hex')':
- SPWF04S-171117-0328fe3-Release.hex only contain the SPWF04's FW
- SPWF04S-171117-0328fe3-Full.hex contain bootloader+FW+default application flash disk
You can also use the following post as further source of information.
举报

更多回帖

发帖
×
20
完善资料,
赚取积分