SparkFun
HMC6343 Qwiic Digital Compass
· MPN: SEN-30183
This compact digital compass module is built around the HMC6343, a fully integrated electronic compass designed to deliver reliable heading data without maki...
Get notified when back in stock
This compact digital compass module is built around the HMC6343, a fully integrated electronic compass designed to deliver reliable heading data without making your main microcontroller do all the processing.
Unlike basic magnetometers that need to be kept flat, the HMC6343 combines 3-axis magneto-resistive sensors with 3-axis MEMS accelerometers. Its onboard microprocessor fuses the data to provide tilt-compensated heading information, so readings stay useful when the board is angled, moving, or handheld.
Integration is straightforward with the Qwiic Connect System: use the two Qwiic connectors to add it to an I2C chain without soldering. Standard 0.1" pins are also broken out for breadboard-style connections.
Documentation includes a schematic, KiCad files, hookup guide, HMC6343 datasheet, Arduino library with example code, and a GitHub repository.
Features:
- Heading Computation: It outputs a final heading direction accurate to within a couple of degrees.
- Hard-Iron Calibration: It automatically compensates for magnetic distortion, maintaining accuracy in environments with magnetic interference.
- Rapid Updates: The board computes and outputs fresh data every 200ms (5Hz), ideal for real-time control loops.
- Compass with Heading/Tilt Outputs
- 3-axis MR Sensors, Accelerometers, and a Microprocessor in a Single Package
- EEPROM Memory
- 2x Qwiic Connectors
- Red Power LED
Specifications:
- Operating Voltage: 3.3V
- Run Mode Current: 4.5mA
A strong choice for robotics, navigation, handheld instruments, and other projects that need heading data over I2C with minimal wiring.
Jargon buster
Plain-language definitions for the technical terms used above.
- EEPROM
- A type of non-volatile memory that keeps stored data even when power is turned off. In a sensor module, it can be used to store settings or calibration data so they do not need to be re-entered every time.
- hard-iron calibration
- A calibration process that compensates for fixed magnetic distortion from nearby metal or magnets in the project. It matters because mounting a compass near motors, screws, or batteries can shift readings unless the sensor is calibrated.
- HMC6343
- A compass sensor chip that combines magnetic sensing, tilt sensing, and onboard processing to output a heading direction. The part number matters because code libraries, wiring details, accuracy, and calibration steps are specific to this chip.
- I2C
- I2C is a two-wire communication bus used by many sensors and small modules. It matters because several I2C devices can share the same two wires, but each device needs a compatible address and your controller must support I2C.
- LED
- A light-emitting diode (LED) is a small electronic component that emits light when current flows through it in the correct direction. Because it only conducts one way, its polarity matters, and a through-hole LED must be soldered the correct way around to light up.
- microcontroller
- A microcontroller is a small computer on a single chip that runs a stored program and controls connected inputs and outputs such as buttons, sensors, displays and communication interfaces. In a device built around one, it is the part that executes the code and coordinates the device's behaviour.
- Qwiic
- Qwiic is a plug-in connector system for I2C devices that uses small 4-pin cables, so you can connect compatible sensors without soldering. It matters because your controller or adapter also needs Qwiic, or you will need a cable or breakout to wire it up.
- tilt-compensated heading
- A compass heading that has been corrected using tilt information so it still works when the board is angled. This matters for handheld or moving projects where the sensor cannot be kept level all the time.
Find this product in
Brands
Sensors & Input
HMC6343 Datasheet
Datasheet · 782.0 KB · Click any page to view full size
HMC6343 Qwiic Compass Schematic
Schematic · 124.2 KB · Click any page to view full size
HMC6343 Datasheet
Datasheet · 309.6 KB · Click any page to view full size
Supplier page — sparkfun.com
Supplier Description · 759.5 KB · Click any page to view full size
Resources & Downloads
Guides, code examples, and more
Source Code
Open-source libraries, firmware & example projects for this product
032f111
about 6 years ago
· 12 commits
- examples Move Wire.begin() Outside of .cpp about 6 years ago
- src Move Wire.begin() Outside of .cpp about 6 years ago
- .gitattributes Initial files additions over 10 years ago
- .gitignore Initial files additions over 10 years ago
- keywords.txt Use a single tab field separator in keywords.txt almost 8 years ago
- library.properties Lib ver roll about 6 years ago
- LICENSE.md Initial files additions over 10 years ago
- README.md Update README.md about 6 years ago