• Home
  • Tutorials
  • Interviews
  • Info Seed
  • Forums
  • Projects
  • Links
  • Contact Us
Digital Electronics
NUMBER SYSTEM
BINARY CODES
TYPES OF BINARY CODES
BCD CODE
EFFICIENCY OF BCD
EXCESS-3 CODE
GRAY CODE
M out of N CODING SCHEME with EFFICIENCY
PARITY BIT
ERROR DETECTION by PARITY
QUESTION
HAMMING CODE (General form)
Relation of PARITY BIT with MESSAGE BITS
ILLUSTRATION-I
ILLUSTRATION-II
BOOLEAN ALGEBRA
K MAPS
COMBINATIONAL CKT
SEQUENTIAL CIRCUITS
TIMING CIRCUITS

 

Gray Code:

This is also called unit distance code or reflected code. This coding system has a property that there is only one bit change between consecutive gray codes. The following table would show gray codes of decimal values.

Binary to gray conversion:

Starting from right to left

  1. If it is MSB then place it as it is
  2. Otherwise, Add the bit to the previous bit and place the sum in GRAY, ignoring any carry
  3. Repeat step 2 till end

Eg.  Convert 1011 to gray

Gray to Binary conversion:

Starting from right to left  

  1. If it is MSB then place it as it is
  2. Otherwise, Add the bit to the previous than corresponding bit of GRAY code and place the sum in GRAY, ignoring any carry
  3. Repeat step 2 till end

Eg.  Convert 1110 to gray

 

 

previous next
| Copyright © 2009 exploreroots- All Rights Reserved | Disclaimer |