Loading

Kategory:

Basic microcontroller: LED

Bookmark and Share

Basic microcontroller: LED


Bismillahirrohmaanirrohiim .. Hmm ... so remember when first learning to fit the microcontroller. Many people say it's easy to learn microcontroller, but I really do not understand well understood. Yep, are first learning to program for LED lighting, it was pake Assembler language. Well heck emang error many times, but because so curiosity ama "chip that can program", whatever sesusah tetep I pursue. As a result, Alhamdulillah LED can be lit as I wanted, and flames could be my heart's content variations. In the liver, with very very happy, I say, "Congratulations .. you can use a microcontroller .." he he he he. . .


Tutorial is intended for anyone who wants to learn the fundamentals of programming the microcontroller (which is discussed here is to use the AVR to the BASIC language). The theory (I took from Wikipedia ), light emitting diode, or better known as LED (light-emitting diode) is a semiconductor that emits incoherent monochromatic light when given a forward voltage. These symptoms include elektroluminesensi form. The resulting color depends on the semiconducting material used, and can be near ultraviolet or near infrared. Sightings:

 

To turn on the LED, the anode must be logic 1 (high) and the cathode must be logic 0 (low). Then for the LED with a lot number, typically all of the anode or the cathode into one (in-common), then other pins connected to the data. So often we know the name of common Anode (anode in all the feet connect to the VCC, to power the LED, the other pin was given logic 0) and Common Cathode (anode in all the feet connect to GND, to power the LED, the other pin was given a logic 1 .) immediately wrote .. Well let's make the circuit used in proteus like this (we use AVR AT90S8535 and ATMEGA8535 or in-circuit LED Common Anode)


note:
When you use the actual series, please give Resistor Before the LED at a minimum of 330 Ohm to limit current into the LED aagar not damaged. Type a blinking LED program below, then compile it, download it to the microcontroller in Proteus, and RUN! : $ regfile = "8535def.dat" 'used micro $ crystal = 8 million 'cristal used PORTB = Output Config Do   PORTB = 255   Wait 1 'turn on the LED   PORTB = 0   Wait 1 'turn off LED Loop Well, it's easy right? Learning microcontroller is easy and fun (sometimes, hehehe) ... want to try something else? Download the aja through the link below ... (free!) proteus design LED 1 LED 2 LED 3 Of course, there are many patterns of the other LED lighting. Please be seatraktif possible. Thus, I hope are useful and can be used as references. Good luck n Awaited comments .. :)
Basic microcontroller: LED
Thanks for reading: Basic microcontroller: LED
Related Posts Plugin for WordPress, Blogger...