Recently Updated Pages
8. ADC Assembly Code Example
8.1 Full Code Here is an example of AVR Assembly code to read the ADC from the ADC0 pin using the...
7. ADC Conversion Flowchart
Here is the complete workflow for using the ADC on the ATmega328p: The flowchart above illustrat...
6. Specific Registers for ADC In ATmega328p
6.1 ADMUX — ADC Multiplexer Selection Register ADMUX is an 8-bit register that handles the basic ...
5. Important ADC Parameters In ATmega328p
5.1 Reference Voltage (Vref) Reference Voltage (Vref) is the maximum voltage that serves as the f...
4. ADC In ATmega328p
4.1 ATmega328p ADC Specifications The ATmega328p (used in the Arduino Uno) has a built-in ADC wit...
3. Why is ADC Needed in Embedded Systems?
The real world is analog — all physical phenomena (temperature, light, sound, pressure, humidity...
2. Analog to Digital Converter (ADC)
2.1 Understanding ADC ADC (Analog to Digital Converter) is a component or circuit that converts a...
1. Analog vs Digital Signal
1.1 Analog Signals Analog signals are signals that are continuous — meaning their values can chan...
1. PWM (Pulse Width Modulation)
PWM is a technique used to simulate analog output using a digital signal. Instead of producing a ...
4. References
PWM Basics PWM Overview PWM Docs Servo Basics Wok Servo Wok EEPROM EEPROM Docs
2. Servos
Servos are motors that adjusts to certain angles following certain PWM pulses. Servo Signal Oper...
3. EEPROM
EEPROM is a small non-volatile memory inside the microcontroller. Unlike SRAM: SRAM loses data w...
4. Internal/Timer Interrupts
Internal Interrupts Now Internal interrupts or Timer interrupts is somewhat more complex then ext...
3. External Interrupt Registers
For detailed information about the registers, please refer to the Atmega32p datasheet. here Fro...
2. Interrupt Handler
On the ATMega328P microcontroller, there are three essential requirements that must met to enable...
1. Introduction to Interrupt
An interrupt is a mechanism used in microcontroller programming to pause the execution of the cur...
2. Operating Modes
2.1. Normal Mode In Normal Mode, the timer acts as a simple up-counter. It starts from 0 and inc...
6. Der Code
6.1. Code Example 1 (Timer0) This code toggles PD5 every 0.5s. The delay_timer0 subroutine uses ...
5. Delay Using Timers
5.1. Delay Calculation in Normal Mode In Normal Mode, the timer always counts up to its maximum v...
4. Timer1
4.1. TCNT1 (Timer/Counter Register) TCNT1 is functionally the same as TCNT0, serving as the core...