{"id":1484,"date":"2026-03-10T18:17:05","date_gmt":"2026-03-10T17:17:05","guid":{"rendered":"https:\/\/eltra.bfenterprise.it\/encoder-pedia\/cosa-sono-il-codice-binario-e-gray\/"},"modified":"2026-04-02T11:08:30","modified_gmt":"2026-04-02T09:08:30","slug":"what-are-gray-and-binary-codes","status":"publish","type":"page","link":"https:\/\/eltra.bfenterprise.it\/en\/encoder-pedia\/what-are-gray-and-binary-codes\/","title":{"rendered":"What are Gray and binary codes?"},"content":{"rendered":"<p><strong>Absolute encoders<\/strong>\u00a0are so defined since they maintain the absolute position value also after an interruption or a power-loss, so it\u2019s essential that all data referring to the position should be always available. For this purpose binary codes are employed, set by the pattern of transparent and opaque segments placed crosswise or lengthwise on the disc, in relation to the direction of the movement.<\/p>\n<h4>Binary code<\/h4>\n<p>The\u00a0<strong>natural binary code<\/strong>\u00a0presents the disadvantage to have more binary digits changing between two consecutive positions. Because of mechanical tolerances, bounces or noise, it could happen that the commutation signals do not operate all at the same time when the state changes, causing intermediate situations that could produce errors in the calculation of the position. To avoid this inconvenient and, therefore, to avoid errors in the output code, an output sync signal (<strong>STROBE<\/strong>) is used.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-489 alignnone\" src=\"https:\/\/eltra.bfenterprise.it\/wp-content\/uploads\/2026\/03\/commutazione-segnali.png\" alt=\"commutazione segnali\" width=\"446\" height=\"324\" srcset=\"https:\/\/eltra.bfenterprise.it\/wp-content\/uploads\/2026\/03\/commutazione-segnali.png 446w, https:\/\/eltra.bfenterprise.it\/wp-content\/uploads\/2026\/03\/commutazione-segnali-300x218.png 300w\" sizes=\"auto, (max-width: 446px) 100vw, 446px\" \/><\/p>\n<h4>Gray code<\/h4>\n<p>In\u00a0<strong>Gray code<\/strong>\u00a0a single binary digit changes between consecutive steps; the code tracks are read crosswise, with respect to the direction of movement, avoiding encoding errors caused by bits changing in contiguous positions.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignleft size-full wp-image-490\" src=\"https:\/\/eltra.bfenterprise.it\/wp-content\/uploads\/2026\/03\/tabella-binario-Gray.png\" alt=\"tabella binario Gray\" width=\"242\" height=\"335\" srcset=\"https:\/\/eltra.bfenterprise.it\/wp-content\/uploads\/2026\/03\/tabella-binario-Gray.png 242w, https:\/\/eltra.bfenterprise.it\/wp-content\/uploads\/2026\/03\/tabella-binario-Gray-217x300.png 217w\" sizes=\"auto, (max-width: 242px) 100vw, 242px\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Absolute encoders\u00a0are so defined since they maintain the absolute position value also after an interruption [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":721,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_acf_changed":false,"footnotes":""},"class_list":["post-1484","page","type-page","status-publish","hentry"],"acf":[],"_links":{"self":[{"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/pages\/1484","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/comments?post=1484"}],"version-history":[{"count":2,"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/pages\/1484\/revisions"}],"predecessor-version":[{"id":1486,"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/pages\/1484\/revisions\/1486"}],"up":[{"embeddable":true,"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/pages\/721"}],"wp:attachment":[{"href":"https:\/\/eltra.bfenterprise.it\/en\/wp-json\/wp\/v2\/media?parent=1484"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}