{"product_id":"qmc5883l-compass-module-3-axis-magnetic-sensor-i2c-for-arduino","title":"QMC5883L Compass Module – 3-Axis Magnetic Sensor I2C for Arduino","description":"\u003ch1\u003eQMC5883L Compass Module – 3-Axis Magnetic Sensor I2C\u003c\/h1\u003e\n\n\u003cp class=\"product-lede\"\u003eThe QMC5883L is a 3-axis magnetometer sensor module that provides compass heading and magnetic field strength via I2C communication, compatible with Arduino, ESP32, and Raspberry Pi boards.\u003c\/p\u003e\n\n\u003ch2\u003eKey Specifications\u003c\/h2\u003e\n\u003ctable class=\"specs-table\"\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n\u003ctd\u003eOperating Voltage\u003c\/td\u003e\n\u003ctd\u003e3.3V – 5V DC (onboard LDO regulator)\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eCurrent Consumption\u003c\/td\u003e\n\u003ctd\u003eless than 1 mA in active mode\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eSensing Range\u003c\/td\u003e\n\u003ctd\u003e±2 gauss \/ ±8 gauss (configurable)\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eResolution\u003c\/td\u003e\n\u003ctd\u003e16‑bit per axis (0.15 µT\/LSB at ±2 gauss)\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eInterface\u003c\/td\u003e\n\u003ctd\u003eI2C, default address 0x0D\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eOutput Data Rate\u003c\/td\u003e\n\u003ctd\u003eup to 200 Hz\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eModule Dimensions\u003c\/td\u003e\n\u003ctd\u003e~13 mm × 13 mm\u003c\/td\u003e\n\u003c\/tr\u003e\n  \u003c\/tbody\u003e\n\u003c\/table\u003e\n\n\u003ch2\u003eWhat You Can Build With This\u003c\/h2\u003e\n\u003cul\u003e\n  \u003cli\u003e\u003ca href=\"\/products\/kit-magnetic-compass-heading-display\"\u003e\n\u003cstrong\u003eDigital Compass Display:\u003c\/strong\u003e Connect an Arduino, QMC5883L, and an OLED screen to show live heading in degrees – perfect for first-time sensor projects.\u003c\/a\u003e\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eWireless Heading Logger:\u003c\/strong\u003e Use an ESP32 to read magnetic field data and transmit it over WiFi to a cloud dashboard for remote monitoring.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRobot Orientation Tracker:\u003c\/strong\u003e Attach the module to a Raspberry Pi‑powered robot, combine with Python scripts, and log tilt‑compensated yaw angles.\u003c\/li\u003e\n  \u003cli\u003e\u003ca href=\"\/products\/kit-magnetic-field-mapper\"\u003e\n\u003cstrong\u003eMagnetic Field Mapper:\u003c\/strong\u003e CBSE \/ ATL students can map the magnetic environment of a classroom, detect metallic objects, and learn about soft and hard iron distortions.\u003c\/a\u003e\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eIndoor Positioning System:\u003c\/strong\u003e For B.Tech or Smart India Hackathon, implement magnetic fingerprinting to estimate indoor location without GPS.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch2\u003eCompatibility\u003c\/h2\u003e\n\u003ctable class=\"compat-table\"\u003e\n  \u003cthead\u003e\u003ctr\u003e\n\u003cth\u003ePlatform\u003c\/th\u003e\n\u003cth\u003eCompatible\u003c\/th\u003e\n\u003cth\u003eConnection\u003c\/th\u003e\n\u003cth\u003eLibrary \/ Method\u003c\/th\u003e\n\u003c\/tr\u003e\u003c\/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n\u003ctd\u003eArduino Uno R3\u003c\/td\u003e\n\u003ctd\u003eYes\u003c\/td\u003e\n\u003ctd\u003eSDA → A4, SCL → A5\u003c\/td\u003e\n\u003ctd\u003eWire.h, QMC5883LCompass\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eArduino Nano\u003c\/td\u003e\n\u003ctd\u003eYes\u003c\/td\u003e\n\u003ctd\u003eSDA → A4, SCL → A5\u003c\/td\u003e\n\u003ctd\u003eWire.h, QMC5883LCompass\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eArduino Mega 2560\u003c\/td\u003e\n\u003ctd\u003eYes\u003c\/td\u003e\n\u003ctd\u003eSDA → 20, SCL → 21\u003c\/td\u003e\n\u003ctd\u003eWire.h, QMC5883LCompass\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eESP8266 NodeMCU\u003c\/td\u003e\n\u003ctd\u003eYes\u003c\/td\u003e\n\u003ctd\u003eSDA → D2 (GPIO4), SCL → D1 (GPIO5)\u003c\/td\u003e\n\u003ctd\u003eWire.h, QMC5883LCompass\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eESP32 Dev Board\u003c\/td\u003e\n\u003ctd\u003eYes\u003c\/td\u003e\n\u003ctd\u003eSDA → 21, SCL → 22 (default)\u003c\/td\u003e\n\u003ctd\u003eWire.h, QMC5883LCompass\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eRaspberry Pi Pico\u003c\/td\u003e\n\u003ctd\u003eYes\u003c\/td\u003e\n\u003ctd\u003eSDA → GP0, SCL → GP1\u003c\/td\u003e\n\u003ctd\u003eMicroPython machine.I2C, custom driver\u003c\/td\u003e\n\u003c\/tr\u003e\n    \u003ctr\u003e\n\u003ctd\u003eRaspberry Pi 4 \/ 5\u003c\/td\u003e\n\u003ctd\u003eYes\u003c\/td\u003e\n\u003ctd\u003eSDA → GPIO2 (pin 3), SCL → GPIO3 (pin 5)\u003c\/td\u003e\n\u003ctd\u003esmbus2 \/ python‑smbus, QMC5883L library\u003c\/td\u003e\n\u003c\/tr\u003e\n  \u003c\/tbody\u003e\n\u003c\/table\u003e\n\n\u003ch2\u003eWiring and Interface Notes\u003c\/h2\u003e\n\u003cp\u003eConnect VCC to 3.3V (the onboard regulator allows 5V input, but I2C lines are already 3.3V‑tolerant), GND to ground, and SDA\/SCL to the corresponding microcontroller pins. Add 4.7 kΩ pull‑up resistors on the I2C lines if your board doesn’t include them. On Raspberry Pi, enable I2C via \u003cem\u003eraspi‑config\u003c\/em\u003e and install \u003cem\u003epython3‑smbus\u003c\/em\u003e for quick testing.\u003c\/p\u003e\n\n\u003ch2\u003eFrequently Asked Questions\u003c\/h2\u003e\n\u003cdiv class=\"faq\"\u003e\n  \u003cdiv class=\"faq-item\"\u003e\n    \u003ch3\u003eIs the QMC5883L directly interchangeable with the popular HMC5883L?\u003c\/h3\u003e\n    \u003cp\u003eNo, although the pinout is identical, the internal registers and data format are different. You must use a dedicated library such as “QMC5883LCompass” by keepworking for correct readings.\u003c\/p\u003e\n  \u003c\/div\u003e\n  \u003cdiv class=\"faq-item\"\u003e\n    \u003ch3\u003eCan this module work reliably near large metal objects or strong magnets?\u003c\/h3\u003e\n    \u003cp\u003eYes, but nearby ferrous materials will distort the magnetic field and reduce accuracy. Always perform a hard‑ and soft‑iron calibration routine before use.\u003c\/p\u003e\n  \u003c\/div\u003e\n\u003c\/div\u003e\n\n\u003cscript type=\"application\/ld+json\"\u003e\n{\n  \"@context\": \"https:\/\/schema.org\",\n  \"@graph\": [\n    {\n      \"@type\": \"Product\",\n      \"@id\": \"https:\/\/compoden.in\/products\/qmc5883l-compass-module-3-axis-magnetic-sensor-i2c-for-arduino#product\",\n      \"name\": \"QMC5883L Compass Module – 3-Axis Magnetic Sensor I2C\",\n      \"description\": \"QMC5883L 3-axis compass magnetometer module. I2C, 16-bit, ±2 gauss. Works with Arduino, ESP32, Raspberry Pi. In stock, fast shipping from Compoden India.\",\n      \"sku\": \"CDN-0992\",\n      \"mpn\": \"CDN-0992\",\n      \"brand\": {\"@type\": \"Brand\", \"name\": \"Compoden\"},\n      \"offers\": {\n        \"@type\": \"Offer\",\n        \"priceCurrency\": \"INR\",\n        \"price\": \"PRICE_PLACEHOLDER\",\n        \"availability\": \"https:\/\/schema.org\/InStock\",\n        \"seller\": {\"@type\": \"Organization\", \"name\": \"Compoden\", \"url\": \"https:\/\/compoden.in\"}\n      }\n    },\n    {\n      \"@type\": \"FAQPage\",\n      \"@id\": \"https:\/\/compoden.in\/products\/qmc5883l-compass-module-3-axis-magnetic-sensor-i2c-for-arduino#faq\",\n      \"mainEntity\": [\n        {\"@type\": \"Question\", \"name\": \"Is the QMC5883L directly interchangeable with the popular HMC5883L?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"No, although the pinout is identical, the internal registers and data format are different. You must use a dedicated library such as “QMC5883LCompass” by keepworking for correct readings.\"}},\n        {\"@type\": \"Question\", \"name\": \"Can this module work reliably near large metal objects or strong magnets?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"Yes, but nearby ferrous materials will distort the magnetic field and reduce accuracy. Always perform a hard‑ and soft‑iron calibration routine before use.\"}}\n      ]\n    }\n  ]\n}\n\u003c\/script\u003e","brand":"Compoden","offers":[{"title":"Default Title","offer_id":53454859043181,"sku":"CDN-0992","price":410.0,"currency_code":"INR","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0999\/3997\/5533\/files\/p_d6eef936-e6e7-4d0b-94f7-15db6b622c03.jpg?v=1782232079","url":"https:\/\/compoden.com\/products\/qmc5883l-compass-module-3-axis-magnetic-sensor-i2c-for-arduino","provider":"Compoden","version":"1.0","type":"link"}