刘红蕾,张键洋,郝 宁,周立超,许雪梅
摘 要:为使传统智能车在环境改变时做出更为及时的响应,设计并实现了一种基于μC/OS-Ⅱ系统的智能寻迹模型车。采用高性能、低功耗的AVR系列8位ATmega 16单片机为核心控制单元。在程序设计时应用μC/OS-Ⅱ系统。采用红外探测法,根据单片机是否收到反射回来的红外光为依据来确定黑线的位置,由单片机控制进行PWM变频调速,实现小车沿黑线行驶。该智能车定位准确,系统响应快且稳定,证明了μC/OS-Ⅱ系统的有效性。
关键词:智能车;μC/OS-Ⅱ系统;路径识别;脉冲宽度调制;AVR单片机
中图分类号:TP368.1文献标识码:A
文章编号:1004-373X(2009)20-023-03
Design and Implementation of Intelligent-searching Track Car Model Based on μC/OS-Ⅱ System
LIU Honglei,ZHANG Jianyang,HAO Ning,ZHOU Lichao,XU Xuemei
(School of Physics Science and Technology,Central South University,Changsha,410083,China)
Abstract:To enable the traditional intelligent car to make more timely response while the environment changes,an intelligent-searching track car model based on μC/OS-Ⅱ system is designed and implemented.The intelligent car system uses the AVR series 8 b single chip which has low power and high performance as its control micro-processor.The μC/OS-Ⅱ system is used for designing program.With infrared detection method,according to whether the single chip microcomputer has received reflected infrared light,the intelligent car determines location of the black line,then it can track the black-guide line automatically by single chip PWM control.This intelligent car can locate accurately and the system can response fast and stably,therefore,it proves superiority of the μC/OS-Ⅱ system.
Keywords:intelligent car;μC/OS operating system;lane detection;PWM control;AVR single chip microcomputer
0 引 言
智能车辆是当今车辆工程领域研究的前沿,它体现了车辆工程、人工智能、自动控制、计算机等多个学科领域理论技术的交叉和综合,是未来汽车发展的趋势。以往智能小车在软件设计上多采用单程序控制,不利于智能车在外部环境改变时做出快速反应,为使智能车系统反应更为快速,该智能车应用μC/OS-Ⅱ系统,该系统适合小型控制系统,具有执行效率高、占用空间小、实时性能优良等特点。且选用功耗较低、资源更为丰富的AVR系列ATmega16单片机作为核心控制单元。
采用红外探测法实现寻迹功能,即将红外光电传感器固定在底盘前沿,利用其在不同颜色的物体表面具有不同的反射性质的特点,在小车行驶过程中不断地向地面发射红外光,单片机就是否收到反射回来的红外光为依据来确定黑线的位置和小车的行走路线。……