Skip to main content

Posts

Showing posts from August, 2016

ADC Reference voltage

ADC Reference voltage ADC Introduction  ADC Prescaler    ADC Reference voltage ADC Channel ADC Resolution ADC Interrupt What is ADC Reference voltage?? ADC reference voltage is nothing but it is used by ADC hardware while reading analogue input.It is the maximum voltage ADC can read. The Reference Voltage (VREF) is the standard voltage against which the Analog Input Voltage must be measured. VREF can be an input voltage provided through external pin. Some ADCs are capable of generating VREF for the ADC module from the Analog VCC of the MCU device. The range of VREF varies among different devices and the respective device datasheet must be referred to know the exact value. Typically, VREF can be selected by configuring the bit field of the corresponding register. For example :If we selected reference voltage as 2.5V then our ADC can read MAX 2.5 volt. If we select 10V then it can read MAX 10V. BUT if we select more value of reference voltage then the resolution

differences between C and embedded C

C and embedded C Hi, there are very few differences between C and embedded C, some of them are: C is hardware independent and embedded C  is hardware dependent C is for desktop computers, embedded C usually is for microcontroller based applications. C use the resources of desktop computers (memory, OS, etc) Embedded C use only limited resources available in the chip (limited RAM, ROM, ports, etc). Embedded  C could be a subset of C. Other differences between C and embedded C what makes embedded c so different from the regular c is *absence of console *restriction on code size *and the compiler regular compilers create os dependent executable file where as embedded c compilers create a file which is downloaded to controllers to realise the required task regular compilers don't give abstraction for all the resources of the system where as in embedded c compiler give access to all the resources directly so code efficient code written in embedded c are though no

prescaler

Prescaler in microcontroller  ADC Introduction  ADC Prescaler    ADC Reference voltage ADC Channel ADC Resolution ADC Interrupt What is the function of  Prescaler  ? Prescaler  is electronic counter used to decreases frequency of the electrical signal to a lower frequency using integer division . The Prescaler takes the basic timer clock frequency or CPU clock frequency or some higher or lower frequency and divides it by some value before feeding it to you hardware (like timer or ADC CAN), that value depends on how the Prescaler register(s) are configured. The  Prescaler  values configured might be limited to a few fixed values (powers of 2), or they may be any integer value from 1 to 2^P, where P is the number of Prescaler bits. example :ADC Prescaler in Atmel controller  By default, the successive approximation circuitry requires an input clock frequency between 50 kHz and 200 kHz to get maximum resolution. If a lower resolution than 10 b

Analog to digital converters

Analog to digital converters ADC Introduction  ADC Prescaler   ADC Reference voltage ADC Channel ADC Resolution ADC Interrupt ADC  Introduction  What is  Analog to digital converters( ADC)?  Analog to digital converters (ADC ) used to convert analog signal (continuously variable signal) to discrete(digital) signal. Example: your using one temperature sensor(linear) it is giving analog output 0V to 10V this voltage is directly proportional to temperature(0º to 100º C). If your using the microcontroller to process the sensor data you have to use Analog to digital converters(ADC) because using micro-controller you can't process the analog data (analog voltage or current) because all microcontrollers are digital. Most of the micro-controller are having inbuilt Analog to digital converters (ADC) example you take Atmega2560 it is having 8/16-channel, 10-bit ADC. What is 10bit ADC?or n bit ADC? 10 bits resolution means it convert analog data

Characteristics Of The I2C-Bus

I2C or Inter-IC (integrated circuit) bus Introduction to I2C Protocol How I2C Communication works? Characteristics Of The I2C-Bus I2C project Advantages of I2C Characteristics Of The I2C-Bus The I2C-bus is for bidirectional, two-line communication between different ICs or modules. The two lines are a serial data line (SDA) and a serial clock line (SCL). Both lines must be connected to a positive supply via a pull-up resistor. Data transfer may be initiated only when the bus is not busy. Bit transfer One data bit is transferred during each clock pulse. The data on the SDA line must remain stable during the HIGH period of the clock pulse as changes in the data line at this time will be interpreted as a control signal. Start and stop conditions Both data and clock lines remain HIGH when the bus is not busy. A HIGH-to-LOW transition of the data line, while the clock is HIGH, is defined as the start condition (S). A LOW-to-HIGH transition of the data line while

How I2C Communication works?

I2C or Inter-IC (integrated circuit) bus Introduction to I2C Protocol How I2C Communication works? Characteristics Of The I2C-Bus I2C project Advantages of I2C How I2C Communication works? As you can see in Figure 2, the master begins the communication by issuing the start condition (S). The master continues by sending a unique 7-bit slave device address, with the most significant bit (MSB) first. The eighth bit after the start, read/not-write (), specifies whether the slave is now to receive (0) or to transmit (1). This is followed by an ACK bit issued by the receiver, acknowledging receipt of the previous byte. Then the transmitter (slave or master, as indicated by the bit) transmits a byte of data starting with the MSB. At the end of the byte, the receiver (whether master or slave) issues a new ACK bit. This 9-bit pattern is repeated if more bytes need to be transmitted. In a write transaction (slave receiving), when the master is done transmitting all of the dat

I2C

I2C or Inter-IC (integrated circuit) bus Introduction to I2C Protocol How I2C Communication works? Characteristics Of The I2C-Bus I2C project Advantages of I2C Introduction to I2C Protocol: Name I 2 C is shorthand for a standard Inter-IC (integrated circuit) bus. Philips developed I 2 C for communication between devices inside for its TV / radio set. Examples of simple I 2 C-compatible devices found in embedded systems include EEPROMs, thermal sensors, and real-time clocks. The main objective behind the invention of I2C bus is to establish a simple low pin count bus that can connect different ICs on a circuit board of Television or Radio. Later I2C grew beyond the limits of TV and Radio and now it can be found in almost every computer motherboards and other embedded devices. I2C can also be used for communication between multiple circuit boards in equipments with or without using a shielded cable depending on the distance and speed of data transfer. Standard