Here You can learn Microcontrollers from scrap...

Saturday, June 20, 2009

Number Systems

Number Systems



In human system, to express a count ‘ten’, we use two digits. Do you know why and the logic behind all number systems. It’s simple.
-->0,1,2,3,4,5,6,7,8,9
From 0 to 9, we use single digits. After that there is no number or characters to express the count so we increase the no of digits --> 1_
After that we start counting from 0 to 9, --> 10,11,12,13,14,15,16,17,18,19
Again we increase the second digit by one and start counting from 0 to 9,
-->20,21,22,23,24,25,26,27,28,29……………..98,99
After you reach 99, you again increase one digit and start counting from 0-9,
-->100,101,102,…109,
-->110,111,112………..

This is how the number system works.
Let’s try with octal number system
-->0,1,2,3,4,5,6,7
After 7 there is no number exist in octal system. So increase the no of digits and start counting-->1_
-->10,11,12,13,14,15,16,17
Again increase the second digit and count
-->20,21,22,23,24,25,26,27…….

Here the number 10 expresses the count ‘eight’
11 expresses the count ‘nine’
12 expresses the count ‘ten’
13 expresses the count ‘eleven’ and so on.

Similarly we try for hexadecimal system,
-->0,1,2,3,4,5,6,7,8,9
After 9 still we have numbers or characters to express the count ‘ten’
-->0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
After ‘F’ (expresses the count 15), we increase the no of digits and start counting from 0 to ‘F’
-->10,11,12,13,14,15,16,17,18,19,1A,1B,1C,1D,1E,1F
-->20,21,22,23,24,25,26,27,28,29,2A,2B,2C,2D,2E,2F….

‘A’ represents the count ‘10’
‘B’ represents the count ‘11’
‘C’ represents the count ‘12’
‘D’ represents the count ‘13’
‘E’ represents the count ‘14’
‘F’ represents the count ‘15’
Totally from zero to 15, we express 16 numbers. That’s why it is called as ‘Hexadecimal System’



Binary System
0 -->0
1-->1
2-->10
3-->11
4-->100
5-->101
6-->110
7-->111
8-->1000
9-->1001
10-->1010
11-->1011
12-->1100
13-->1101
14-->1110
15-->1111

In the memory of the computer, all these numbers are stored in Binary Format.
You can also express the Binary format in other number systems. But expressing in Binary and Hexadecimal system will be easy to work.
Four Digits in Binary is Equivalent to one digit in Hexadecimal system.
Binary Operations
More over there are many binary operations you have to learn
AND, OR, NOT, EX-OR

AND- this is just multiplying the corresponding digits of two binary numbers.
Example:
1100 0111
1001 1111
Ans: 1000 0111

OR – this is logical addition of corresponding digits of two binary numbers.
Logical addition means 1+1=1, 1+0=1, 0+0=0
Example:
1000 0111
1001 0110
Ans: 1001 0111

NOT – this is interchanging one’s with zero and zero’s with ones.
1100 1010
Ans: 0011 0101
EX-OR –Compare corresponding digits and
put one if both digits are different
put zero if both digits are same.
Example:
1100 1010
1001 0110
Ans: 0101 1100

ADD –this is ordinary addition of binary numbers.
Here 1 + 1 = 10, 1+1+1=11
Example:
1100 1010
1000 1001
Ans: 10101 1011

Wednesday, May 20, 2009

Microprocessor An Easy explanation


Microprocessor

Microprocessor is nothing but a data manipulator. It manipulates or modifies data according to the instructions given. The “Instructions given” is the program what we are writing and giving it to the computer. (The computer what we are using has a microprocessor to which we will give programs to execute like C programs which they execute to produce certain result. The result is what we see in the computer’s screen)

Simply, microprocessor (μP) is an executer unit of instructions. μP has a very small memory to store the results and operands. The data is in the form of numbers.


The instructions (i.e.) program is stored in a separate memory called ‘Program Memory’. The data that has to be manipulated or processed is stored in a separate memory called ‘Data Memory’.


Data Means

Now we will describe what Data means…


In the field of microprocessor, data is a number. In human language, we represent numbers as 1,2,3,4,5,6,7,8,9,0 and its combinations. In computer’s language,(i.e.) microprocessor’s language, it knows only 2 numbers {0,1}. So symbolically we have to represent the number 1,2,3,4,… using {0,1}

To understand this You need to study number systems.




























SYSTEM

NUMBERS

NO OF NUMBERS

Human Arabic system:

0,1,2,3,4,5,6,7,8,9

10

Binary system:

0,1

2

Octal system:

0,1,2,3,4,5,6,7

8

Hexadecimal system:

0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F

16

Saturday, March 21, 2009

What is microcontroller ?

A Microcontroller is a combination of microprocessor, memory and other accessories in a single package. so first of all if you want to study microcontrollers you need to know about Microprocessor.

Microprocessor is very easy to learn once you understand the basic concepts. To learn this, you need to study Digital electronics and Numbers systems a little.

Followers

Contributors