Digital and Analog are two different types of signals in nature. They are used to send data from the transmitter to the receiver. The Digital signal has 2 states HIGH and LOW. Whereas Analog is variable in nature and can change as per the factors involved.
Understanding the digital signal is like the switch being turned ON and OFF. A digital signal carries the data in the form of binary because it signifies in the bits i.e. 1’s and 0’s.
Digital is represented in many ways:
- ON / OFF
- 1 / 0
- HIGH / LOW
- TRUE / FALSE
- 3.3V / 0V
- 5V / 0V
When you group many digital bits/signal together you can form a binary integer. A group of 8 bits is called a byte. Computer data is organised in the form of bytes. This decimal representation is also used to represent voltage levels in microcontroller like Arduino, RPi etc
Now the digital signal is like the line drawn by a butterfly while flying. An analog signal is variable in nature and is one type of continuous time-varying signals, and these are classified into composite and simple signals. A simple type of analog signal is nothing but a sine wave, and that can’t be decomposed, whereas a composite type analog signal can be decomposed into numerous sine waves.
Arduino can take and give digital and analog signals as INPUT’s and OUTPUT’s.