登录
首页 » c » 串口通信课程设计

串口通信课程设计

于 2022-08-22 发布 文件大小:16.86 MB
0 75
下载积分: 2 下载次数: 1

代码说明:

#include     //52系列单片机头文件#define uchar unsigned char#define uint unsigned int sbit cs1=P2^3; //数码管段选信号sbit cs2=P2^2; //数码管段选信号sbit cs3=P2^1; //数码管段选信号sbit cs4=P2^0; //数码管段选信号sbit RE=P1^6; //低电平收数据,高电平发数据sbit DE=P1^7;   //低电平收数据,高电平发数据sbit key0=P1^0;   //主机用两个拨码开关sbit key1=P1^1; //主机用两个拨码开关uchar show_code[]={0xc0,0xf9,0xa4,0xb0,0x99,0x92,0x83,0xf8,0x80,0x98}; //数字0-9的显示码,更改数码管显示程序。uchar temp1=0,temp2=0;uchar count=0,sum=0;//void delayms(uint); //延时函数声明//void decide (void);void send_byte(uchar t)   //发送一个字节  发送一个数据后立马变成收数据的状态{ RE=1;  //高电平发    DE=1;  //高电平发         ES=0;    SBUF=t; while(!TI);   TI=0;ES=1; RE=0;  //低电平收    DE=0;  //低电平收}void delayms(uint xms) //延时

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

发表评论

0 个回复

  • 3
    说明:  利用VTK实现的一个可以不停旋转的球体,不需要交互(VTK can be used to achieve a continuously rotating sphere, does not require interactivity)
    2009-12-26 15:35:47下载
    积分:1
  • WinCImage
    说明:  源码 for "C語言數位影像處理" 吳上力 編譯(Source code for "C language digital image processing")
    2009-07-24 11:10:54下载
    积分:1
  • TIM1
    STM8单片机TIM1计数器精确定时后进入中断函数(STM8 microcontroller TIM1 counter precise timing after entering the interrupt function )
    2015-04-16 16:11:13下载
    积分:1
  • 12345
    车牌识别标准字体,,很有用处哦111111111111111111111(plate rec)
    2014-05-05 10:05:31下载
    积分:1
  • 一个数字密码锁的小程序
    该程序是一个数字密码锁的小程序,在基于单片机的LCD12864显示屏上实现的一个密码输入解锁的功能程序。
    2022-12-21 11:35:04下载
    积分:1
  • les-4-3-tools
    CyberBot botnet tool for hacking
    2013-10-04 02:41:58下载
    积分:1
  • binary
    实现对二叉树的操作:建树、遍历、求层高、叶子数和结点数等(binary tree)
    2011-12-09 15:58:29下载
    积分:1
  • DistributeColor.cpp
    The program uses opencv and distrbute color according to distance of Object pixels.
    2009-05-06 18:08:20下载
    积分:1
  • Popular-PID-algorithm
    PID算法的通俗讲解,有助于同学们学习了解PID算法(Popular PID algorithm to explain, to help students learn to understand the PID algorithm)
    2012-09-30 16:51:51下载
    积分:1
  • 自助点菜系统上位机QT
    基于QT串口通讯方式的自助点菜系统小程序,下位机使用C51单片机完成,可以接收到下位机发送的菜单,并自动将菜单排序,另外具有简单的串口设置窗口
    2023-05-03 13:35:03下载
    积分:1
  • 696516资源总数
  • 106442会员总数
  • 11今日下载