PX4/Firmware — pull request #1295 by muharred (2014-08-20 10:25:18+00:00)
Title: HMC5883 set_excitement minor fix.

Since set_excitement method in the hmc5883 driver is exposed through ioctl MAGIOCEXSTRAP command, it's better to reset the two LSBs of configuration register A before or-ing with 0x01 or 0x02. Else calling the method with -1 as the argument followed by a call with 1 as the argument will produce 0x03 in the two LSBs which corresponds to the "Reserved" mode on the chip.