摘要
基于开源的CANopen架构CanFestival和嵌入式实时系统μC/OS-Ⅱ,提出了一种构建CANopen从站平台的方法。详细阐述CANopen协议栈的软件结构设计,实现了μC/OS-Ⅱ系统在MC9S12XF512上的移植,并将CANopen从站协议的状态机封装成任务后嵌入到μC/OS-II中运行。该硬件平台采用单片机MC9S12XF512和高速CAN总线收发器TJA1040来实现。通信测试表明CANopen从站通信稳定,实现了DS301通信规范的功能。
This paper presents a method for using MC9S12XF512 chip to construct a CANopen slave station based μC/OS-Ⅱ system and CanFestival open source stack, and illustrates the software design of CANopen protocol stack, the transplantation of μC/OS-Ⅱ and the process of embedding CANopen slave stack to μC/OS-Ⅱ. The communication test shows that the slave station realized the function of DS301 standard.
出处
《单片机与嵌入式系统应用》
2014年第1期12-15,共4页
Microcontrollers & Embedded Systems