MCU SOURCE FILE_marquee

Publisher:快乐飞跃Latest update time:2015-12-22 Source: eefocusKeywords:MCU Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
#include"reg51.h"

#define uchar unsigned char
#define uint unsigned int

sbit LED=P3^6;
//delay for 1ms
void delay1ms(uint t)
{
  uint i;
  uchar j;
  for(i=0;i     for(j=0;j<120;j++);
}

//main
void main()
{
 uint m,n;
 LED=0;
 for(m=0;m<256;m++)
    {
     P0=m;
     delay1ms(300);
    }
  P0=0xff;
 for(n=0;n<256;n++)
    {
     P0=n;
     delay1ms(300);
    }
  while(1)
   {
    P0=0xf0;
    P1=0x0f;
    delay1ms(500);
    P0=0x0f;
    P1=0xf0;
    }
}

Keywords:MCU Reference address:MCU SOURCE FILE_marquee

Previous article:MCU C_FILE_MARQUE
Next article:8-bit microcontroller multiplication function

Latest Microcontroller Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号