虫虫首页| 资源下载| 资源专辑| 精品软件
登录| 注册

do-while

  • Wide-input dc/dc modules offer

    When a system designer specifies a nonisolated dc/dc powermodule, considering the needed input voltage range isequally as important as considering the required performanceattributes and features. Generally, nonisolated moduleshave either a narrow or a wide input voltage range. Narrowinputmodules typically have a nominal input voltage of3.3, 5, or 12 V. For systems that operate from a tightlyregulated input bus—such as those that do not use batterybackup—a narrow-input module is often adequate sincethe input remains fairly stable.Offering greater flexibility, wide-input modules operatewithin a range of 7 to 36 V, which includes the popular12- or 24-V industrial bus. This enables a single module tobe used for generating multiple voltages. These modulesare ideal for industrial controls, HVAC systems, vehicles,medical instrumentation, and other applications that usea loosely regulated distribution bus. In addition, systemspowered by a rectifier/battery charger with lead-acidbattery backup almost always require wide-input modules.System designers who choose power supplies may wantto take a close look at the latest generation of wide-inputdc/dc modules.

    标签: Wide-input modules offer dc

    上传时间: 2014-12-24

    上传用户:dragonhaixm

  • 74ls164_动态驱动多位数码管

    void display()    //数码显示 { SCON=0;    //初始化串行口方式   SBUF=dispcode[ge];   while(!TI);   TI=0;     led4=0;   delay(2);   led4=1;     SBUF=dispcode[shi];   while(!TI);   TI=0;    led3=0;   delay(2);   led3=1;

    标签: 164 74 ls 动态

    上传时间: 2013-11-20

    上传用户:wtrl

  • 基于51单片机的八音盒设计

    本设计是以STC89C52RC芯片为核心,利用Keil UV4编写软件和STC_ISP烧写软件,设计出一个八音盒。八音盒主要由五大模块构成,包括单片机最小系统、4*4矩阵键盘、蜂鸣器发生电路和4位数码管显示电路。有8个按键对应8首曲目播放按钮,另外8个按键对应do、re、mi、fa、so、la、si、do’八中音调。本设计主要使用单片机的内部定时器0和中断产生不同频率的方波和延时驱动蜂鸣器,并采取行列反转扫描法识别键盘键值。由于使用的是实验箱已经固化的电路,本设计主要从软件设计上加以优化,以使蜂鸣器产生的音乐更纯净。最终实现的基础功能是任意播放8首单片机内已存曲目,发挥部分是另外实现8个可演奏的琴键,使八音盒具有放音和简单演奏的两重功能,并辅以数码管显示当前播放曲目号,经过优化和调试,音色较好,琴键发音比较纯正,初步达到设计要求。

    标签: 51单片机 八音盒

    上传时间: 2013-11-18

    上传用户:450976175

  • TLC2543 中文资料

    TLC2543是TI公司的12位串行模数转换器,使用开关电容逐次逼近技术完成A/D转换过程。由于是串行输入结构,能够节省51系列单片机I/O资源;且价格适中,分辨率较高,因此在仪器仪表中有较为广泛的应用。 TLC2543的特点 (1)12位分辩率A/D转换器; (2)在工作温度范围内10μs转换时间; (3)11个模拟输入通道; (4)3路内置自测试方式; (5)采样率为66kbps; (6)线性误差±1LSBmax; (7)有转换结束输出EOC; (8)具有单、双极性输出; (9)可编程的MSB或LSB前导; (10)可编程输出数据长度。 TLC2543的引脚排列及说明    TLC2543有两种封装形式:DB、DW或N封装以及FN封装,这两种封装的引脚排列如图1,引脚说明见表1 TLC2543电路图和程序欣赏 #include<reg52.h> #include<intrins.h> #define uchar unsigned char #define uint unsigned int sbit clock=P1^0; sbit d_in=P1^1; sbit d_out=P1^2; sbit _cs=P1^3; uchar a1,b1,c1,d1; float sum,sum1; double  sum_final1; double  sum_final; uchar duan[]={0x3f,0x06,0x5b,0x4f,0x66,0x6d,0x7d,0x07,0x7f,0x6f}; uchar wei[]={0xf7,0xfb,0xfd,0xfe};  void delay(unsigned char b)   //50us {           unsigned char a;           for(;b>0;b--)                     for(a=22;a>0;a--); }  void display(uchar a,uchar b,uchar c,uchar d) {    P0=duan[a]|0x80;    P2=wei[0];    delay(5);    P2=0xff;    P0=duan[b];    P2=wei[1];    delay(5);   P2=0xff;   P0=duan[c];   P2=wei[2];   delay(5);   P2=0xff;   P0=duan[d];   P2=wei[3];   delay(5);   P2=0xff;   } uint read(uchar port) {   uchar  i,al=0,ah=0;   unsigned long ad;   clock=0;   _cs=0;   port<<=4;   for(i=0;i<4;i++)  {    d_in=port&0x80;    clock=1;    clock=0;    port<<=1;  }   d_in=0;   for(i=0;i<8;i++)  {    clock=1;    clock=0;  }   _cs=1;   delay(5);   _cs=0;   for(i=0;i<4;i++)  {    clock=1;    ah<<=1;    if(d_out)ah|=0x01;    clock=0; }   for(i=0;i<8;i++)  {    clock=1;    al<<=1;    if(d_out) al|=0x01;    clock=0;  }   _cs=1;   ad=(uint)ah;   ad<<=8;   ad|=al;   return(ad); }  void main()  {   uchar j;   sum=0;sum1=0;   sum_final=0;   sum_final1=0;    while(1)  {              for(j=0;j<128;j++)          {             sum1+=read(1);             display(a1,b1,c1,d1);           }            sum=sum1/128;            sum1=0;            sum_final1=(sum/4095)*5;            sum_final=sum_final1*1000;            a1=(int)sum_final/1000;            b1=(int)sum_final%1000/100;            c1=(int)sum_final%1000%100/10;            d1=(int)sum_final%10;            display(a1,b1,c1,d1);           }         } 

    标签: 2543 TLC

    上传时间: 2013-11-19

    上传用户:shen1230

  • 100个单片机实例

    #include<reg51.h> //包含单片机寄存器的头文件 /******************************************************* 函数功能:主函数 (C 语言规定必须有也只能有1 个主函数) ********************************************************/ void main(void) { while(1) //无限循环 { P1=0xff; // P1=1111 1111B,熄灭LED P0=P1; // 将 P1 口状态送入P0 口 P2=P1; // 将 P1 口状态送入P2 口 P3=P1; // 将 P1 口状态送入P3 口

    标签: 100 单片机

    上传时间: 2013-10-26

    上传用户:离殇

  • keil编译错误分析

    一、 main.c(35): warning: #128-D: loop is not reachable from preceding code 原因,前面有一个while(1){ …….} 二、 main.c(54): warning: #1-D: last line of file ends without a newline 少了一个回车在}之后  

    标签: keil 编译 错误

    上传时间: 2014-12-26

    上传用户:sjb555

  • 基于单总线式无线温度采集系统设计

    为提高温度测量效率,降低系统的成本,扩展传输距离,设计出一种新型温度采集系统。单片机通过控制具有单总线方式的温度传感器DS18B20实现对温度的测量,同时单片机通过控制具有单总线方式300~450MHz频率范围内的MAX7044与MAX7033无线发射与接收芯片实现温度数据的无线传输。与传统温度采集系统相比,该系统利用单总线方式连接,采用无线传输方式实现远距离通信,易于系统的集成与扩展。实验结果表明,该系统结构简单、方便移植,能够同时实现多达上百点温度的测量与500m范围的传输。 Abstract:  To improve the temperature measurement efficiency and reduce system cost,expansion of transmission distance,a new type of temperature acquisition system is designed.Microcontroller controlled temperature sensor DS18B20which has a single-bus achieves temperature measurement,while microcontroller by controlled the MAX7044and MAX7033chip with a single-bus and having300~450MHz radiofrequency to achieve the wireless transmission of temperature data.Compared with conventional temperature acquisition system,the system uses single-bus connected,and uses wireless transmission means to achieve long-distance communications,easy-to-system integration and expansion.The experimental results show that the system is simple,convenient transplantation,and can be implemented in as many as a hundred-point temperature measure-ment and the transmission range of500meters.

    标签: 单总线 无线温度 采集 系统设计

    上传时间: 2013-10-29

    上传用户:515414293

  • 基于C8051F310的山路转弯预防警示系统

    针对盘山路存在的转弯盲区,即在转弯时司机无法得知弯路对面是否有车辆通过,设计一种基于C8051F310的山路转弯预防警示系统。该系统利用一阶滤波算法检测山路转弯时是否有车辆通过。运用该算法可增强系统检测的实时性,提高检测机动车辆的灵敏度,同时大大减少环境温度对检测的干扰。试验表明该系统能够正确指示出在山路转弯时是否有车辆通过,目前该系统已安装在盘山路上,可大大减少事故的发生率。 Abstract:  Aiming at passing hilly road,there is a turn blind spot.Motormen usually do not know if the passing of vehicles pass the road.So a system of defending accident on hilly road is designed,which is based on MCU C8051F310.The sys-tem uses the first-order filter algorithm to detect whether there are passing vehicles.This algorithm enhances the real-time detection and improves the sensitivity of detection vehicles.Meanwhile,it reduces the detection interference of environmen-tal temperature.The experimental results show that this system can exactly indicate if there are passing vehicles.At present,the system has been successfully applied to hilly road.The system can greatly decrease accident.

    标签: C8051F310 转弯

    上传时间: 2013-10-10

    上传用户:归海惜雪

  • 基于双ATmega128的安检力学试验机设计

    针对当前安检力学试验机所能完成的试验种类单一、自动化程度低等问题,提出一种以ATmega128单片机为核心控制器的安检力学试验机的设计。详细阐述了该安检力学试验机各个组成部分的设计原理和方案,并且给出了各部分的软件设计思想和操作流程。经过大量测试试验表明:设计的安检力学试验机可以完成多达十余种的力学安检试验,完全符合相关国家标准,并且具有数据采集精度高、传输速度快、操作安全简便等特点,实现了安检设备的多功能化、数字化和自动化。 Abstract:  Currently, many mechanical security testing machines have only one function. The degree of automation of them is low. To solve those problems, a new kind of mechanical security testing machine, using ATmega128 micro-controller as its core controller, has been advanced. It describes the components of the machine. The principles and the scheme in the designing processes are presented in detail, and the software architecture and the operation processes of each part are given. After having done many testing, we have reached the following conclusions: the mechanical security testing machine presented can do over ten mechanical security tests complying with related national standards. It has high data acquisition accuracy and high transmission speed. The operation of the machine is simple and safe. In general, this machine is a multi-functional, highly automatic, digitalized security testing device.

    标签: ATmega 128 安检 试验机

    上传时间: 2013-11-05

    上传用户:a67818601

  • CAT93C46 器件数据手册

    The CAT93C46 is a 1 kb Serial EEPROM memory device which isconfigured as either 64 registers of 16 bits (ORG pin at VCC) or 128registers of 8 bits (ORG pin at GND). Each register can be written (orread) serially by using the DI (or DO) pin. The CAT93C46 features aself−timed internal write with auto−clear. On−chip Power−On Resetcircuit protects the internal logic against powering up in the wrongstate.

    标签: CAT 93C C46 93

    上传时间: 2013-11-20

    上传用户:ynzfm