Understanding bitwise operations
GyX=Wire.read()&lt;&lt;8|Wire.read();


This is a bug. It reads two bytes from the I2C bus and builds a 16-bit
number from them. One of the bytes (we don't know which one) will be the
most significant byte of the result. The other byte will be the least
significant byte.

This instruction is likely to work just fine on some particular version
of some particular compiler with some particular compiler options.
Presumably it did work for the author. But you should not expect it to
work consistently across compilers, or even across different versions of
the same compiler.

The proper way to do this is to perform the two reads in different
instructions:

GyX = (uint16_t) Wire.read() &lt;&lt; 8;
GyX |= Wire.read();


assuming the bytes come most-significant first.

Edit: added (uint16_t) cast. C.f. this answer.