Light the LEDs with the Stc12c5a60s2 P4 interface.

Source: Internet
Author: User


STC12C5A60S2 Pin

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/74/07/wKiom1YOPDuSS-56AALUa67nfTg822.jpg "title=" 12c.jpg "alt=" Wkiom1yopduss-56aalua67nftg822.jpg "/>



Development Board for use


650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/74/07/wKiom1YOOarD1-3MAAZn-6JbRmE601.jpg "title=" Development Board. PNG "alt=" wkiom1yooard1-3maazn-6jbrme601.jpg "/>



Program code

/* Project to create MCU selection, Atmel 89c55 microcontroller: stc12c5a60s2 Crystal: 12M function: With stc12c5a60s2 P4 interface lit LED connection description: Led positive junction VCC, negative to MCU 9,29,30,31 foot */# Include <STC12C5A60S2.    h> sbit led7=p4^7;sbit led6=p4^6;sbit led5=p4^5;sbit led4=p4^4;void delay_ms (unsigned int a) {unsigned int i;    while (--a! = 0) {for (i=0;i<=600;i++); }} void Main (void) {p4sw=0xff;//If the LED is only lit on 9 feet, this line led6=0 is not required;  led4=0; while (1) {LED7 = ~led7; LED6 = ~led6; LED5 = ~led5;   LED4 = ~led4;delay_ms (200); }}



Program Burning Special Instructions

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/74/04/wKioL1YOOp6yfShEAASZKPM_V9M758.jpg "title=" 4led.png "alt=" Wkiol1yoop6yfsheaaszkpm_v9m758.jpg "/>


650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/74/07/wKiom1YOQV7RwAPeABQIh4s8X64716.gif "title=" 123. GIF "alt=" Wkiom1yoqv7rwapeabqih4s8x64716.gif "/>




October 2, 2015, no one about, a person at home, rotten, alas.


















This article comes from "Life is endless, tossing and turning." "blog, declined reprint!"

Light the LEDs with the Stc12c5a60s2 P4 interface.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.