Gray code converters

These online calculators convert to and from the binary reflected in the Gray code and can produce a table for an n-bit Gray code

Esta página existe graças aos esforços das seguintes pessoas:





Criado: 2020-03-17 13:47:06, Ultima atualização: 2020-12-11 12:28:59

This page combines several calculators related to Gray code. You can read a short recap of what is the Gray code right below the calculators.

First, there is a converter from decimal (to be precise, non-negative integer number) to Gray code (to be precise, binary reflected Gray code):

PLANETCALC, Decimal to Gray code

Decimal to Gray code

Gray Code

Second, this is a converter from binary reflected Gray code to decimal, and the result is displayed in decimal and binary formats:

PLANETCALC, Gray code to Decimal

Gray code to Decimal


And finally, there is a table generator, which can generate a table for an n-bit Gray code:

PLANETCALC, n-bit Gray code table generator

n-bit Gray code table generator

The file is very large. Browser slowdown may occur during loading and creation.

Gray code

The Gray code, named after Frank Gray, is an ordering of the binary numeral system, such that two successive values differ in only one bit. The Gray code rolls over the range it represents with only one bit/switch change. I wrote 'switch' because initially, it was designed to prevent spurious output from electromechanical switches in sequential systems. For example, a change from 3 to 4 in normal binary ordering requires three switch changes (from 011 to 100), while in Gray code, we always need only one (from 010 to 110).

The Gray code is also known as the reflected binary code.

URL copiado para a área de transferência
PLANETCALC, Gray code converters