为您找到约 50 条结果,搜索耗时:0.0027秒

红外遥控模拟

...d delay(); char getkey() {   P1=0xfe;P3_6=P3_7=1;P3_3=1;   if(!P1_4)return 1;   //ON   if(!P1_5)return 2;   //7   if(!P1_6)return 3;   //8   if(!P1_7)return 4;   //9   if(!P3_6)return 5;   //X   if(!...

基于51单片机的多功能时钟

...imer2(); while(1){ /*防止sec、minute、hour超出合理范围*/ if(sec>=60||sec<0) sec=0;  if(minute>=60||minute<0) minute=0; if(hour>=25||hour<0) hour=0; /*UpdateTimeFlag标注位来刷新Buffer区*/ if(UpdateTimeFlag=1){ UpdateTimeFlag=0; ...

编码开关试验

...while(1)  {   b=0x80; for(i=0;i<8;i++) { P2=b; if((i%2)==0)c=dat[i/2]%10;else c=dat[i/2]/10; P0=~num[c]; for(a=0;a<10;a++) ; b>>=1;P0=0; //if(i==7) for(a=0;a<10000;a++) ; }  } } void CodingsWitchPolling1()//  {    &nbsp...

可预设电压的数控电源

可预设电压的数控电源#ifndef _PWLOCK_H // 防止PWLock.h被重复引用 #define _PWLOCK_H #include <reg52.h> #include <absacc.h> #include <stdio.h> #include <math.h> #define uchar unsigned char #define uint unsigned int uchar px; uint a; uint b; ...

密码锁

...赋值50MS定时  TL0=(65536-50000)%256; //重装计数初值  if(yhsh==1)   {   TCNTY++;//用户定时计数   if(shw==1)  {   TR0=0;   TCNTY=0;   }   if(TCNTY==400)   {     TR0=0;//关闭T0定时器   &nbs...

直流电机测速+中文液晶显示

... P3_0=1; P3_1=1; P3_2=1;     P3_3=1; _nop_();_nop_(); if(!P3_0)return '7';   if(!P3_1)return '8';   if(!P3_2)return '9';     if(!P3_3)return '/';   P1_4=1;   P1_5=0;   P1_6=1;   P1_7=1; _nop_();_nop_(); if(!P3_0)return '4'; &nb...

ibsystat源码分析

...istribution and use in source and binary forms, with or * without modification, are permitted provided that the following * conditions are met: * * - Redistributions of source code must retain the above * copyright notice, this list of conditions and the following * ...

FPGA上数字时钟的VHDL代码

...econd*/  input [1:0] H_in1, /*A 2-bit input used to set the most significant hour digit of the clock (if LD_time=1),or the most significant hour digit of the alarm (if LD_alarm=1). Valid values are 0 to 2. */  input [3:0] H_in0, /* A 4-bit input used to set the least significant hour di...

贪吃蛇+俄罗斯方块+万年历

...gt; #include "18b20.h" #include "1302.h" #include "12864.h" #include "zifu.h" uchar k,direction; bit flag; bit flag5=0;    //flag5是外部中断1的标志位 flag1是步进标志 uchar p,dengji;               //定时次数  bit flag...

简易示波器设计

...nbsp;E=0;  }  void pianxuan(unsigned int i)  {   if(i==1)    CS1=0,CS2=1;   if(i==2)   CS1=1,CS2=0;   if(i==3)   CS1=0,CS2=0;   }   void shuju()  {   pianxuan(i);   writecommand(ye);   writecommand(lei);...

微信捐赠

微信扫一扫体验

立即
上传
返回
顶部