A Free Template From Joomlashack

A Free Template From Joomlashack

Sign in with a social network::

Powered by OneAll Social Login

Who is online

We have 9 guests online

Chat with us

Inputs & Outputs

 

In microcontroller applications push buttons are used in most cases. How to use them without unwanted contact «bounce« (what is debouncing anyway?), how we can intelligently increase the number of I/O pins of a microcontroller, driving DC motors and becoming familiar with PWM, are topics of this chapter.

 

Get your hands on an AVR microcontroller with help from Bascom-AVR and start controlling the world around you!



Short introduction to Bascom-AVR Programming PDF Print E-mail
Written by Jurij Mikeln   

We are witnessing great progress in all areas of technical science. Much of that progress we can attribute to the development of processing power in our PCs, which have enabled development of new powerful programming tools running on our PCs. In the field of electronics there are many tools that we use daily and which are indispensable to our work. The same goes for electronics components, especially microcontrollers, which have progressed tremendously in the last 15 years.

Last Updated on Tuesday, 04 June 2013 13:38
 
Improved Debounce Routines PDF Print E-mail
Written by Vladimir Mitrović   

Bascom’s Debounce statement solves this problem, by checking the switch’s state over again a bit later, when a level change is detected at an input pin. For example, if Debounce is configured to recognise a falling edge at an input pin (a logical level change from High to Low), it will delay the program execution for 25 ms and then check the input pin again to see if it is still at a logic “0” or not. If it is, an associated subroutine will be executed.

Last Updated on Wednesday, 01 August 2012 14:33
 
I/O Expansion PDF Print E-mail
Written by Vlado Berend   

I had a requirement where a 20-pin microcontroller had to drive one LED display plus other peripherals. To drive the LED display, required 8 pins that were not available, because they were already used by other peripherals. After a literature search, I found a cheap shift register which performs like the PCF8574 (which is not cheap at all!).

Last Updated on Wednesday, 01 August 2012 14:34
 
Something about PWM in Bascom-AVR PDF Print E-mail
Written by Vladimir Mitrović   

Most AVRs contain PWM hardware, especially the newer ones, which typically have two or more PWM units built-in. A PWM signal is one in which the ratio between a pause and a signal is changing as seen in Figure 1.

Last Updated on Tuesday, 04 June 2013 13:36
 
Programming AVR microcontrollers without a programmer PDF Print E-mail
Written by Jurij Mikeln   

Our task here is to program our target microcontroller with a Bootloader program. What is a Bootloader? It’s a short program that is placed at the upper end of a microcontroller’s Flash memory which is normally inactive. We can activate it by pulling the Reset line low or pressing the Reset button.

Last Updated on Wednesday, 01 August 2012 14:33
 
Wait a minute! PDF Print E-mail
Written by Vladimir Mitrović   

ll of Bascom’s wait statements and the delays embedded in other statements are essentially loops that execute the required number of times to achieve a desired time-delay. There is an internal Bascom-AVR routine that lasts 1 ms, _WAITMS. During program compilation, the Bascom-AVR compiler checks the $crystal directive and uses a specified parameter to calculate the values needed for the counting registers in order to achieve a 1 ms execution time of the _WAITMS routine (or as close as possible to 1 ms).

Last Updated on Wednesday, 01 August 2012 14:34
 
Driving motors with AVR PDF Print E-mail
Written by Vladimir Mitrović   

The Power module shown in Figure 1 is built around four L272M integrated circuits: IC1-IC4. Each of them contains two powerful operational amplifiers with maximum output currents up to 1 A. These amplifiers are used to switch loads connected to their outputs, to the ground (pin 4) or to the positive power supply voltage (pin 2).

Last Updated on Wednesday, 01 August 2012 14:35
 


Joomla Templates: by JoomlaShack