关于CC3200 OTA失败
关于CC3200 OTA失败
这两天在调试CC3200的OTA例程,
我在Dropbox设立了账户,访问Dropbox的时候使用了Psiphon,
“Psiphon”,官方中文译名为赛风,民间早期译作白凤或彩虹,是一款可以突破网络审查的自由软件,其遵循GPL协议,于2006年12月1日发布。它是由开放网络基金资助、多伦多大学的公民实验室(Citizen Lab)开发。Psiphon 分为数个版本,Psiphon 2 是网页版代理,Psiphon 3 是利用VPN和HTTP代理技术的软件,支持Android及Microsoft Windows系统。
流程按照SDK中的CC3200 Over-The-Air (OTA) Update Application Note.pdf这个文档进行操作。
按照4.2小节的内容在Dropbox创建了相应的文件夹:
4.2 Creating Dropbox API application
Note: Assuming service pack version 2.1.0.87.31.0.0.4.1.1.5.3.3 is installed and next it is getting updated to version 2.1.0.88.31.0.0.4.1.1.5.3.3
1. Create an account with Dropbox and login
2. Go to https://www.dropbox.com/developers/apps/create and choose “Dropbox API app”
3. Choose “Files and Datastores” and “Yes My app only needs access to files it creates”.
4. Provide a suitable name for the APP and click “Create APP” button
5. You will be redirected to Apps setting page. Scroll down to “Generated access token” and click generate. Copy and save the generated token.
6. Go to https://www.dropbox.com/home/Apps
7. Click on the application name
8. Create a new folder and name it “Vid01_Pid00_Ver0087”. This folder will contain only Service pack of version 2.1.0.88.31.0.0.4.1.1.5.3.3
9. Create another folder and name it “Vid01_Pid00_Ver0088”. This folder will contain Application and other files corresponding to App version 01.
10. Create another folder and name it “Vid01_Pid00_Ver0188”. This folder will contain next update. If no next update, leave the folder empty.
11. The rationale behind steps 8 to 10 is to ensure that Service pack gets updated first and then other files like MCU image are updated. To start with device has Application files of version 00 and service pack of version 87. In order to update the device to Application files of version 01 and service pack of version 88, copy new service pack 88 into the folder “Vid01_Pid00_Ver0087” and all other application files corresponding to version 01 into the folder “Vid01_Pid00_Ver0088”. After completion of the update Application will start to point to “Vid01_Pid00_Ver0188”
按照4.3小节编译了相关代码,并把相应的.bin文件上传至Dropbox对应文件夹下:
4.3 Configuring the application for new Dropbox account
Note: Assuming service pack version 2.1.0.87.31.0.0.4.1.1.5.3.3 is installed and next it is getting updated to version 2.1.0.88.31.0.0.4.1.1.5.3.3
1. Open otaconfig.h
2. Update the following Parameters
a. OTA_SERVER_REST_HDR_VAL - Set this to the token generated in the previous steps
b. OTA_VENDOR_STRING - Set this to Vid01_Pid00_Ver01
c. APP_VER_BUILD - 1
3. Compile and upload the .bin file into “Vid01_Pid00_Ver0088” folder on Dropbox server
4. Rename it “f80_sys_mcuimgA.bin”.
5. Update the following parameters again
a. OTA_VENDOR_STRING - Set this to Vid01_Pid00_Ver00
b. APP_VER_BUILD - 0
6. Open example\common\common.h, this file contains macros related to the network AP to which this application will try to connect. Set the following parameters to match the AP
a. SSID_NAME - AP SSID Name
b. SECURITY_TYPE - Security type
c. SECURITY_KEY - Password, if any
Note: Parameters/macros defined in common.h file are shared among all the SDK examples.
7. Compile and upload the .bin file into “Vid01_Pid00_Ver0188” folder on Dropbox server
8. Rename it “f80_sys_mcuimgA.bin”.
按照4.4.1.2小节的内容烧写了flash:
4.4.1.2 Flashing
1. Open Uniflash tool for CC3xxx
2. Make sure LP is in UARTLOAD mode i.e. SOP2 jumper mounted.
3. Format the sFlash.
4. Program the service pack.
5. Go to File->New Configuration. Choose the connection and board and click ok
6. Set “/sys/mcuimg.bin” URL to point “application_bootloader.bin”
7. Select “Erase”, “Update” and “Verify”
8. Add a new file and rename it to “/sys/mcuimg1.bin”. If no factory default is required rename it to “/sys/mcuimg2.bin”. Set the URL of this file to point to the OTA application binary, set the URL of this file to point to the OTA application binary, say “ota_update_nonos.bin” if using NON-OS example.
9. Select “Erase”, “Update” and “Verify” for this new file.
10. Set the COM port to LP’s com port number
11. Press Program
对于红色字体部分,我有些疑问:
第一、 步骤4和步骤5应该是反了吧,如果不先connection CC3200,如何Program service pack,目前service pack我已经烧写成功
第二、 8种的两句红色字体内容为什么是一致的呢。我在处理条目8的时候,add new file将其rename成/sys/mcuimg2.bin。这样做是因为看到了这句If no factory default is required rename it to “/sys/mcuimg2.bin”
完成上述步骤后执行OTA操作不成功,如下:
我的路由名是Evendata-West,可以获取GTM Time,这个应该是说明连接AP成功了吧。
但是不知道什么原因,有时会显示NTP Server Error,获取不到时间,过一段时间自动重连后又可以显示时间。我的网络环境不是太好。
总之应该是访问外网成功了吧。
点击更新后:
会先显示进行中
随后就出错了:
我的问题是:
- 出错的原因不明,大家帮我看看我的步骤有问题吗
- PC是开启Psiphon才可以访问Dropbox的,如果是CC3200连路由,没有类似Psiphon这样的翻墙软件是不是CC3200就不能访问Dropbox,从而导致更新失败。我是要刷路由的固件,使路由可以“翻墙”,应该就可以了吧?
是的,国内访问dropbox有问题,你路由器可以直接访问dropbox的话应该就没问题。
您好 感谢您的回复 请问如何使路由器可以访问DropBox呢?
最近项目较多 没有留意您在5月27日发表的关于机智云服务器访问的帖子
明天我仔细拜读下 然后尝试。
我之前在决定我们项目Wi-Fi方案的时候,尝试过用STM32F103与Marvell88W8686构建网络
当时的物联网平台叫Yeelink,控制部分用的JSON,请问这个机智云也是是国内的一个物联网平台吧
CC3200是不是和任何类似的物联网平台都可以交互呢 只要遵守一定的协议
再有一点疑问与您探讨 CC3200的Wi-Fi是SPI总线的,应该存在传输速度的瓶颈吧
我之前用的STM32F103与Marvell88w8686是SDIO 速度要快很多