登录
首页 » c » 四路寻迹

四路寻迹

于 2023-04-27 发布 文件大小:27.11 kB
0 126
下载积分: 2 下载次数: 1

代码说明:

#include #define CAR_SPEED_MAX 10 //最大速度 sfr P4=0xe8; sbit PWM_R=P1^7; //PWM输出 sbit PWM_L=P1^2; sbit Moto_RA=P1^6; sbit Moto_RB=P1^5; sbit Moto_LA=P1^4; sbit Moto_LB=P1^3; //左右电机驱动 unsigned char Moto_Speed_R; //右轮速度 unsigned char Moto_Speed_L; //左轮速度  unsigned char Moto_Speed_Num; //PWM调速 sbit INF_R0=P4^3; //循迹 右侧内传感器 sbit INF_R1=P4^2; //循迹 右侧外传感器 sbit INF_L0=P4^1;   //循迹 左侧内传感器 sbit INF_L1=P4^0;   //循迹 左侧外传感器 unsigned char Car_Sta; //电机启动速度 /*********************************** *函数名称:void Delay(unsigned char num) *函数功能:延时 *参数说明:num 延时时间 数值最大255 *返回说明:无 *其它说明:不精准延时 ***********************************/ //void Delay(unsigned char num) //{ // unsi

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • dds
    说明:  使用STM32单片机驱动dds模块,这里的dds模块为正点原子的模块(Using STM32 MCU to drive the DDS module, where the DDS module is the module of positive atom)
    2019-07-02 09:53:20下载
    积分:1
  • SURFmex
    matalab调用C程序实现的基于SURF算法的全景图像拼接(matalab call C SURF algorithm based Program for panoramic image stitching)
    2011-05-03 08:30:54下载
    积分:1
  • PER2BIN
    1. csharp source code 2. .per file to binary file convertor(This program opens the .per file for ATSHA204 and generates 3 binary files for programming)
    2012-10-25 09:00:58下载
    积分:1
  • 5_zhanlue
    战略管理 中科院的经典教材 这个非常还是 现在中科院用的教材(Academy of Strategic Management is now this very classic textbook used textbooks Academy)
    2013-11-24 21:28:15下载
    积分:1
  • duibidulasheng
    对比度拉伸,对原始图像进行对比度拉伸,从而得到拉伸后的图像(tensile contrast, the original image contrast stretching, and thus drawing the images)
    2007-06-28 16:19:44下载
    积分:1
  • uCOSII.for.LPC2148API
    LPC2148微处理器ARM7开发板带驱动编程模板(LPC2148 microprocessor ARM7 development board tape driver programming template)
    2010-07-12 20:08:17下载
    积分:1
  • voicebox
    mfcc的matlab显示方法,可以直接运行(mfcc s showing by matlab)
    2012-04-23 01:26:15下载
    积分:1
  • File2
    说明:  矩阵求逆(lu分解法),已在matlab下进行测试,计算精度大概为小数点后4位(Matrix inversion (lu decomposition method), has been tested under matlab, after the decimal point accuracy is approximately 4)
    2011-04-15 10:41:42下载
    积分:1
  • RTC5 Files
    用于激光扫描的RTC5振镜控制的DLL、LIB和头文件(DLL, LIB and header files for the control of RTC5 galvanometer for laser scanning)
    2019-03-24 20:30:34下载
    积分:1
  • 珍藏的C++Builder 电子书,从中受益很多
    珍藏的C++Builder 电子书,从中受益很多-Book of C++Builder
    2023-01-16 03:50:05下载
    积分:1
  • 696516资源总数
  • 106658会员总数
  • 16今日下载