Generally and briefly, are there any direct application of gray code in electronics? If so, what are they?
It is also used in digital modulation schemes like, for instance, in this 8-PSK modulation here:
Because of the noise, sometimes the receiver might incorrectly detect an adjacent symbol instead of the correct one. If gray encoding is used, the adjacent symbol will only be 1 bit apart. The received binary stream will therefore be closer to the correct one, and might be eventually corrected if an error correction mecanism is in place.
More about constellations here: http://en.wikipedia.org/wiki/Constellation_diagram
We used grey code for a non-ferrous optical encoder to track joint position in MRI kinematic studies. Due to the high level of RF noise from the MRI transceiver, and the high magnetic field, errors might occur sending an incorrect position of (knee, elbow, etc) joing in the positioning system.
Something that wasn't mentioned yet is the use of gray code in Karnaugh maps.
This site gives a good explanation: https://www.allaboutcircuits.com/textbook/digital/chpt-8/logic-simplification-karnaugh-maps/
In the 1980's one of the defense industries proposed developing a guided hypervelocity missile (Mach 5) for air-to-ground attacks. The missile was to be guided by a rear-facing optical sensor which would be illuminated by a pulsed laser in the launcher. The output of the laser would produce a modulated pattern in the far field which was specified to be gray-scale encoded. That is, it would provide a "checkerboard" pattern with each successive pulse producing a different pattern, and the result of a series of pulses would be a gray code representation of the location of the particular spot with respect to the aiming axis of the launcher. This would allow the missile to know where it was with respect to the desired line of flight without the need for the launcher to track it and issue guidance commands, as the missile itself would figure out its error and correct its flight path.
I suppose that's only barely real-world, since the system was never funded, but I know they did preliminary work on it and were fairly certain it would work.
A gray code can be used to minimize transition power, when a counter value goes on a bus with a large enough capacitance to warrant the overhead of encoding (if any).
A gray code is also often used in read&write pointers in asynchronous dual-port FIFOs to prevent wrong transitions being detected by the two asynchronous clock domains.
Switching between vectors in Space vector PWM is another one. Switching only one half bridge at a time reduces harmonics. Its much less direct than the other examples though. You have to go out of your way not to use it though in this case since there is a physical correlation with the phases that naturally arises as a gray code