tag 标签: rtos

相关博文
  • 热度 3
    2019-11-30 17:54
    1730 次阅读|
    1 个评论
    【RT-Thread软件包+w601评测】开发板上手点灯
    正点原子W601 WIFI 物联网开发板 是原子科技基于国产 物联网无线通信芯片供应商北京联盛德微电子有限责任公司 开发的 WIFI MCU 芯片W 601, 主打家电市场。 联盛德官网 http://www.winnermicro.com/ 这款开发板原子科技官方淘宝店只卖98元,读者可以自行搜索购买 原子科技联合 RT -thread为这款开发板提供了软件开发套件支持 资料下载链接:https://pan.baidu.com/s/1UwbrQBbNt3Vnf9DGoETymg 提取码:q6dc 芯片资源: 该 SoC 芯片集成 Cortex-M3 内核,内置 Flash,支持 SDIO、SPI、UART、GPIO、I²C、PWM、I²S、7816、LCD、 ADC 等接口, 支持多种硬件加解密协议,如 PRNG/SHA1/MD5/RC4/DES/3DES/AES/CRC/RSA 等;集成射频 收发前端 RF Transceiver,PA 功率放大器,基带处理器/媒体访问控制。 开发板硬件资源: 软件开发包: 从原子论坛下载的开发板资料,包含各种文档和代码和部分视频 源码部分分两部分,一部分是原子开发的裸机例程,demo了各种外设的使用,提供Keil工程文件。 第二部分是基于RT -Thread RTOS开发的 SDK ,同样提供大量外设和物联网demo , 包含KEIL和 IAR 工程文件。 裸机工程: 打开并编译工程 "E:\boards\ 【正点原子】 W601 开发板光盘资料 \4 ,程序源码 \1 ,裸机例程 \ 实验 1 跑马灯 (RGB) 实验 \USER\ATK_RGB.uvprojx" binary 生成在目录 E:\boards\ 【正点原子】 W601 开发板光盘资料 \4 ,程序源码 \1 ,裸机例程 \ 实验 1 跑马灯 (RGB) 实验 \BIN RT -Thead 工程: 打开i并编译工程 "E:\boards\ 【正点原子】 W601 开发板光盘资料 \4 ,程序源码 \RT-Thread_W60X_SDK\examples\01_basic_led_blink\project.uvprojx" binary 生成在目录 E:\boards\ 【正点原子】 W601 开发板光盘资料 \4 ,程序源码 \RT-Thread_W60X_SDK\examples\01_basic_led_blink\Bin 程序下载: 开发板支持SWD下载,可以用JLINK或者原子商城提供的LINK下载 也可以用串口工具下载: 打开 "E:\boards\ 【正点原子】 W601 开发板光盘资料 \6 ,软件资料 \1 ,软件 \ 星通智联串口调试下载助手 \ThingsTurn_Serial_Tool.exe" 选择串口,选择固件文件,点击下载
  • 热度 5
    2016-6-3 11:52
    535 次阅读|
    0 个评论
    1). 简介 MQX是由NXP提供的实时操作系统,结构框图如下图所示, 包含内核,文件系统以及协议栈, 同时对于NXP的ARM处理器也可以很好的支持,可以很方便的开发和部署. 本文就基于Toradex Colibri VF61 (基于NXP VF61 SoC) ARM计算机模块搭配Colibri Eva Board开发板来演示编译和部署MQX应用. VF61为异构双核架构ARM处理器,包含一个Cortex-A5和一个Cortex-M4,通常应用场景为A5核心运行Linux或者WinCE系统作为控制和界面显示,M4核心运行一个实时操作系统来处理实时任务. 本文所演示的即是在M4核心上面部署运行MQX应用. 2). 准备 a). 硬件准备 ./ Colibri VF61计算机模块和Colibri Eva Board开发板 ./ Ubuntu Linux开发主机 b). 软件准备 ./ VF61模块A5核心运行Toradex Embedded Linux release V2.5 Beta3 ./ Ubuntu Linux开发主机 ./ MQX RTOS 4.1.2 Vybrid - 从这里下载 ./ Linaro bare-metal toolchain for Cortex-R/M, 4.8 2014-Q1 update - 从这里下载 3). 配置 a). 解压缩到”/home/username”目录下 ------------------------ $ tar xzf “~/MQX RTOS 4.1.2 for Vybrid Linux Base.gz.gz” $ tar xjf ~/gcc-arm-none-eabi-4_8-2014q1-20140314-linux.tar.bz2 ------------------------ b). 配置MQX ./ 文件 ”FSLMQXOS_4_1_2_Vybrid/build/common/make/global.mak” 设置交叉编译toolchain ------------------------ + TOOLCHAIN_ROOTDIR = /home/yourname/gcc-arm-none-eabi-4_8-2014q3/ ------------------------   ./ 文件  “FSLMQXOS_4_1_2_Vybrid/config/twrvf65gs10_m4/user_config.h” 由于VF61 A5和M4共享外设资源,因此在使用M4外设时候要通过修改A5 Device Tree来确保此外设没有被A5已经占用.本文后续只测试M4调用GPIO,因此将其他和A5冲突的外设资源都去掉,实际应用中可以根据具体情况做配置. ------------------------ ... #define BSPCFG_ENABLE_I2C0                  0 #define BSPCFG_ENABLE_II2C0                  0 ... #define BSPCFG_ENABLE_SPI0                   0 ... #define BSPCFG_ENABLE_RTCDEV               0 ... #define BSPCFG_ENABLE_ESDHC                0 #define BSPCFG_ENABLE_SAI                    0 ... #define BSPCFG_ENABLE_TTYB                   0 #define BSPCFG_ENABLE_ITTYB                  0   #define BSPCFG_ENABLE_TTYC                   1 #define BSPCFG_ENABLE_ITTYC                   0 ... ------------------------   ./ 文件 ”FSLMQXOS_4_1_2_Vybrid/mqx/source/bsp/twrvf65gs10_m4/twrvf65gs10_m4.h” 修改时钟 ------------------------ ... #define BSP_CORE_CLOCK                  (166700000) #define BSP_BUS_CLOCK                   (166700000) #define BSP_SYSTEM_CLOCK                (83300000) #define BSP_IPG_CLOCK                   (83300000) ... ------------------------ 4). 编译MQX a). 替换  “mqx/examples/hello/build/make/hello_twrvf65gs10_m4/build_gcc_arm.sh” 文件 从这里下载文件 b). 编译Helloworld Firmware ------------------------ $ cd mqx/examples/hello/build/make/hello_twrvf65gs10_m4/ $ ./build_gcc_arm.sh ... Build done Press any key to continue... ------------------------ c). 创建binary Firmware文件 ------------------------ $ cd ~/FSLMQXOS_4_1_2_Vybrid/mqx/examples/hello/build/make/hello_twrvf65gs10_m4/gcc_arm/ram_release $ export PATH=~/gcc-arm-none-eabi-4_9-2014q1/bin/:$PATH $ arm-none-eabi-objcopy -O binary hello_twrvf65gs10_m4.elf hello_twrvf65gs10_m4.bin ------------------------ d). 查看应用入口地址 由于二进制程序没有可以指明加载地址或入口地址的头部信息,因此需要在加载的时候手动添加 ------------------------ $ arm-none-eabi-objdump -f hello_twrvf65gs10_m4.elf   hello_twrvf65gs10_m4.elf:     file format elf32-littlearm architecture: arm, flags 0x00000112: EXEC_P, HAS_SYMS, D_PAGED start address 0x3f0007b1 ------------------------ e). 运行MQX 将bin文件复制到Colibri VF61 A5核心的Linux系统上面,运行下面命令启动mcc然后下载并运行MQX在M4核心 ------------------------ # modprobe mcc # mqxboot hello_twrvf65gs10_m4.bin 0x3f000000 0x3f0007b1 ------------------------ f). 查看M4串口输出 将Colibri开发板UARTB接口连接到开发主机 ------------------------ $ sudo minicom -D /dev/ttyUSB1 -d 115200 Welcome to minicom 2.7   OPTIONS: I18n Compiled on Jan  1 2014, 17:13:19. Port /dev/ttyUSB1, 14:58:22 Press CTRL-A Z for help on special keys   Hello World ------------------------ 5). GPIO demo 在M4运行MQX GPIO demo, 通过BSP_BUTTON1来控制打开和关闭BSP_LED1 a). 查看M4对应管脚定义 确定BSP_BUTTON1对应GPIO管脚为PTB16,BSP_LED1对应GPIO管脚为PTB0 ------------------------ $ vi FSLMQXOS_4_1_2_Vybrid/mqx/source/bsp/twrvf65gs10_m4/twrvf65gs10_m4.h   ... #define BSP_LED1                            (LWGPIO_PIN_PTB0) ... #define BSP_SW1                             (LWGPIO_PIN_PTB16) ... #define BSP_BUTTON1                         BSP_SW1 ... ------------------------ b). 确认M4 GPIO管脚资源 通过查询Colibri VF61手册和A5 Linux Device Tree文件, 发现PTB0被A5 Linux pwm0占用,而PTB16虽然被flexcan1占用但默认并为启用,因此首先需要根据这里的说明先重新编译A5 Linux Device Tree文件将pwm0 disable以免管脚资源冲突;然后在Colibri载板上面将PTB0 (SODIMM 59)连接到X21 LED1 (Pin 2), PTB16 (SODIMM 63)连接到X21 SW6 (Pin 11) c). 同样方法编译MQX GPIO Firmware ------------------------ $ cd ~/FSLMQXOS_4_1_2_Vybrid/mqx/examples/gpio/build/make/gpio_twrvf65gs10_m4 $ ./build_gcc_arm.sh $ cd gcc_arm/ram_release/ $ export PATH=~/gcc-arm-none-eabi-4_9-2014q1/bin/:$PATH $ arm-none-eabi-objcopy -O binary gpio_twrvf65gs10_m4.elf gpio_twrvf65gs10_m4.bin $ arm-none-eabi-objdump -f gpio_twrvf65gs10_m4.elf   gpio_twrvf65gs10_m4.elf:     file format elf32-littlearm architecture: arm, flags 0x00000112: EXEC_P, HAS_SYMS, D_PAGED start address 0x3f000e51 ------------------------ d). 部署并测试demo ./ 在VF61 A5 Linux上面部署并运行MQX GPIO到M4 ------------------------ # mqxboot gpio_twrvf65gs10_m4.bin 0x3f000000 0x3f000e51 ------------------------ ./ 在M4 串口输出打印按键3次 ------------------------ ====================== GPIO Example ====================== The (SW1) button is configured to trigger GPIO interrupt. Press the (SW1) button 3x to continue. ------------------------ ./ 按Colibri 开发板SW6 3次后,即可通过SW6控制LED1 ------------------------ Button pressed 3x   The (SW1) button state is now polled. Press the (SW1) button to switch LED on or off   Button pressed ------------------------ 6). MCC Pingpong demo 下面通过MCC Pinpong demo来测试A5和M4之间的信息传递 a). 配置MCC版本 MQX 4.1.2版本默认采用MCC V2版本,但也同时提供了V1版本源代码;由于目前VF61 Linux只支持MCC V1版本,因此首先要用V1版本源代码替换V2版本 ------------------------ $ cd ~/FSLMQXOS_4_1_2_Vybrid/mcc/source $ unzip mcc_version_1_2.zip -d ../.  //按提示选择全部替换 $ vi mcc_vf600.c //如下面红色部分修改 static const unsigned int mcc_cpu_to_cpu_vectors[] = { GIC_CPU_to_CPU_int0, NVIC_CPU_to_CPU_int0 }; ------------------------ b). 编译MCC ------------------------ $ cd ~/FSLMQXOS_4_1_2_Vybrid/mcc//build/make/mcc_twrvf65gs10_m4 $ ./build_gcc_arm.sh ------------------------ c). 编译Pingpong demo ------------------------ $ cd ~/FSLMQXOS_4_1_2_Vybrid/mcc/examples/pingpong/build/make/pingpong_example_twrvf65gs10_m4 $ ./build_gcc_arm.sh ------------------------ d). 部署运行测试Pingpong demo 和之前同样方法获得bin和入口地址,并通过A5 Linux运行到M4上面 ./ A5 Linux部署执行Pingpong demo ------------------------ $ mqxboot pingpong_example_twrvf65gs10_m4.bin 0x3f000000 0x3f001095 ------------------------ ./ 运行后, M4串口输出 ------------------------ Responder task started, MCC version is 001.002   ------------------------ ./ 然后在A5 Linux运行自带的Pingpong应用 ------------------------ mcc-pingpong ------------------------ ./ 然后M4串口输出 ------------------------ Responder task received a msg                                                   Message: Size=4, DATA = 1                                                       Responder task received a msg                                                    Message: Size=4, DATA = 3 ... ------------------------ ./ 同样A5串口输出 ------------------------ version: 001.002                                                                Message: Size=4, DATA = 2 after 0.004325 seconds.                                Message: Size=4, DATA = 4 after 0.004340 seconds.                               Message: Size=4, DATA = 6 after 0.004669 seconds. ... ------------------------ 7). 总结 本文简单展示了在VF61 M4核心上面运行MQX以及A5和M4核心通信例程,可见MQX可以非常方便的部署在NXP处理器上面,详细的MQX应用开发可以参考下面文档. FSLMQXOS_4_1_2_Vybrid/doc http://developer.toradex.com/knowledge-base/mqx-on-the-cortex-m4-of-a-colibri-vf61
  • 热度 11
    2015-8-8 16:34
    685 次阅读|
    7 个评论
    应网友要求,经过半年多时间的重新修订,基本完成嵌入式微系统书籍的编写工作。   这本书,并不是针对嵌入式初学者,而是针对有2、3年以上工作经验的嵌入式工程师,他们做了一些项目或产品后,需要深入技术,提高效率,团队作战,而这方面的书籍很少,希望嵌入式微系统这本书可以有效解决他们的困惑。   本书是基于作者在开发工业控制项目过程中,碰到了什么问题,为什么要这么做的思路写的,把嵌入式微系统这套软件怎么来的,每一个需求作者是怎么思考,如何取舍的,这个思考过程讲解出来,而不是直接把结果讲出来,这是最值得项目或产品人员借鉴的。   所有的一切都问为什么,重视推理。   最后一章,侧重讲解了msOS自带的双任务内核的工作原理,因为双任务内核非常简单,并且用推理的方式分析的非常透彻,   这对想学习RTOS,尤其是uC/OS-II的网友非常有好处。 附件为源码及文档, 交流QQ群:291235815 2000人大群,现在超过1500人,空位不多,大多是有多年工作经验的高手。
  • 热度 3
    2013-8-29 17:53
    906 次阅读|
    0 个评论
    In this second instalment , we have another expert panel talking about the intellectual property (IP) industry. In part 1 , we tackled the concept of IP as a partnership between the supplier and the user. Taking part in this discussion are Warren Savage, president and CEO of IPextreme; John Koeter, vice president of marketing for the solutions group at Synopsys; and Chris Rowen, Cadence Fellow and CTO of Tensilica. EE Times : When the IP industry was first being formed, a lot of people would create a piece of RTL IP, hang out a shingle, and attempt to start selling it. They quickly realised that there was more to it than this. Have we moved beyond the point where this is within the realm of a start-up? Warren Savage : I don't think so. For example, we have our constellations program. It is a lot of smaller companies, very smart people with innovative ideas. There has been enough written about IP in the last 15 years, and the industry itself has matured enough such that there's been success stories written. People know how to put IP together—better than they did in 1998. It's a much different environment. It's not the Wild West anymore. EE Times : How does a company build up enough trust to get established? Savage : Usually, it's the technology innovation that is the driver to make the customers make a leap—they need that specific technology that's not commoditized. Early adopters are willing to work with them in a real partnership model. Sometimes technology is not fully baked such that it needs that close cooperation to get to that maturity level. John Koeter : I think, if you're really doing complex IP, like physical IP and highly configurable IP, you have to have a certain scale to be able to build the quality into the product. Being able to afford to do that, to run all the tests and simulations and running the characterisations and split lots and get certification and so on and so forth, takes a lot. Having said that, though, there are many small IP companies that fill a vital niche. There's certainly room for many smaller companies to have a speciality that could do very well. In Warren's case, you resell other people's ideas, and they've already proven them, right? They've already put the investment in, and you've put more investment on top of it, so you can make that happen because of your unique business. Chris Rowen : I don't think that the barrier to the IP business has gotten relatively higher. It's gotten absolutely higher. But I think that's true for every area of electronic innovation. The barrier to entry for new start-ups has gone up—a lot. I think IP, particularly if it's a small team that has some unique insight into a particular vertical application domain—a particular kind of technology that may allow them to encapsulate those insights into something they can license—that's still a viable opportunity. I think we also see the emergence of new kinds of intellectual property. We're starting to see, for example, in the case of Tensilica, the ability to extend something that is already there. They can create a set of processor extensions in a standard form that plugs into our processor. Now this customer can build an entire application-specific processor without needing a compiler team, an RTOS team, a debugger team, a simulator team, a hardware team, a verification team, or models working at the next level of abstraction. A lot of that becomes automated, and it distills out just their know-how. * * * In the next installment, we will look at the areas that are most ripe for increased IP adoption. Brian Bailey EE Times  
  • 热度 3
    2013-8-29 17:50
    1021 次阅读|
    0 个评论
    This is the second instalment of an expert panel discussing the intellectual property (IP) industry. In part 1 , we tackled the concept of IP as a partnership between the supplier and the user. Taking part in this discussion are Warren Savage, president and CEO of IPextreme; John Koeter, vice president of marketing for the solutions group at Synopsys; and Chris Rowen, Cadence Fellow and CTO of Tensilica. EE Times : When the IP industry was first being formed, a lot of people would create a piece of RTL IP, hang out a shingle, and attempt to start selling it. They quickly realised that there was more to it than this. Have we moved beyond the point where this is within the realm of a start-up? Warren Savage : I don't think so. For example, we have our constellations program. It is a lot of smaller companies, very smart people with innovative ideas. There has been enough written about IP in the last 15 years, and the industry itself has matured enough such that there's been success stories written. People know how to put IP together—better than they did in 1998. It's a much different environment. It's not the Wild West anymore. EE Times : How does a company build up enough trust to get established? Savage : Usually, it's the technology innovation that is the driver to make the customers make a leap—they need that specific technology that's not commoditized. Early adopters are willing to work with them in a real partnership model. Sometimes technology is not fully baked such that it needs that close cooperation to get to that maturity level. John Koeter : I think, if you're really doing complex IP, like physical IP and highly configurable IP, you have to have a certain scale to be able to build the quality into the product. Being able to afford to do that, to run all the tests and simulations and running the characterisations and split lots and get certification and so on and so forth, takes a lot. Having said that, though, there are many small IP companies that fill a vital niche. There's certainly room for many smaller companies to have a speciality that could do very well. In Warren's case, you resell other people's ideas, and they've already proven them, right? They've already put the investment in, and you've put more investment on top of it, so you can make that happen because of your unique business. Chris Rowen : I don't think that the barrier to the IP business has gotten relatively higher. It's gotten absolutely higher. But I think that's true for every area of electronic innovation. The barrier to entry for new start-ups has gone up—a lot. I think IP, particularly if it's a small team that has some unique insight into a particular vertical application domain—a particular kind of technology that may allow them to encapsulate those insights into something they can license—that's still a viable opportunity. I think we also see the emergence of new kinds of intellectual property. We're starting to see, for example, in the case of Tensilica, the ability to extend something that is already there. They can create a set of processor extensions in a standard form that plugs into our processor. Now this customer can build an entire application-specific processor without needing a compiler team, an RTOS team, a debugger team, a simulator team, a hardware team, a verification team, or models working at the next level of abstraction. A lot of that becomes automated, and it distills out just their know-how. * * * In the next installment, we will look at the areas that are most ripe for increased IP adoption. Brian Bailey EE Times  
相关资源
广告