Magnetic Compass to Pacman Mod

Attached is the schematics for the Honeywell HMC1052L Dual Axis Magnetic Sensor to Pacman mod and the modified Python Source code. You may purchase the breakout board from sparkfun. The python program is pacman.py

SEN-00761 Dual Axis Magnetic Sensor Eval Board - Honeywell HMC1052L
SEN-00719 Dual Axis Magnetic Sensor Breakout - Honeywell HMC1052L

Pacman.zip (282.64 KB)

Note the following
1) For the Compass, my recommended circuit excludes the amplifier as the EMANT380 can measure down to 1uV. However the problem is that if you want to implement my circuit, you need to be able to solder the QFN and SOIC packages. Alternatively, you can use the SEN-00761 Dual Axis Magnetic Sensor Eval Board and connect the amplified output to the EMANT380 analog inputs. In this case, do modify the Python code
2) Don't forget to set the COM port of the EMANT380
3) There is an additional python code ReadCompass.py This code writes the calibration info to the compass.ini file which is used by the pacman.py to determine direction. See the Honeywell HMC1052L app note as why this is required. 100 readings will be taken and the module should be rotated 360 degrees at least once. This will also allow to check if your board is connected up correctly.
4) North move up
West move left
South move down
East move right
5) For more info, look at the Honeywell HMC1052L specs and app note.

Created by kychan. Last Modification: Monday 24 of November, 2008 11:42:32 SGT by kychan.

Menu