AED 31.50
1
Description
The QMC5883l is One of the most popular magnetometers it is an I2C-compatible. with solid-state construction and very low cross-axis sensitivity. it designed to measure both the direction and the magnitude of Earth’s magnetic fields, from milli-gauss to 8 gausses.
Specifications:
Parameter | QMC5883L |
---|---|
Voltage Supply (Vs) | 2V16 ~ 3V6 |
Digital Supply (VDDIO) (max) | 1.65V ~ 3V6 |
Abs. Max VDD/VDDIO | -0.3V ~ 5.4V |
Interface | I2C |
I2C Address (R,W) [RW] | 0x0D [R/W] |
I2C rates (kHz) | 100, 400 |
Resolution (ADC) | 16 bits |
Max Gauss (survival) | 50000G |
Gauss Resolution | ±2mG ~ ±8G |
Acquisition time | 6ms |
Active current (7Hz,10Hz) | 75uA |
Active current | 75uA ~ 850uA[2] |
Peak Active current | 2.6mA |
Standby mode (leakage) | 3uA |
Operating temperature | -30°C ~ 85°C |
How does a magnetometer work?
An electronic magnetometer like the QMC5883l is based on the Anisotropic Magnetoresistance phenomenon. Mastering the physics that describes the phenomenon is not an easy task, since this is a huge field whose depths we cannot hope to begin to plumb in these few words.
Basically, the magnetic field interacts with the path of the current flowing through a ferrous material, according to the Lorentz Law hence the resistance of the material seems to change to the observer. You can imagine as if the bar of ferrous material (e.g InSb) grows longer, raising its electric resistance. Therefore measuring the change in the resistance we can estimate the magnetical field!
Pinout of the GY-273 3 QMC5883l Module:
VCC: Power supply
GND: GND power
SCL: I2C Clock Input
SDA: I2C Data IO
DRDY: Data Ready Output
Arduino code for the GY-273 Module:
in this code Connect QMC5883l to Arduino Uno Board as follows:
- VCC to +5V
- GND to GND
- SCL tO A5
- SDA to A4
1. when the device rotates around its X-axis, X-axis remains the same while the other two axis changed.
2. when the device rotates around its Y-axis, Y-axis remains the same while the other two axis changed.
3. when the device rotates around its Z-axis, Z-axis remain the same while the other two axis changed.
#include//I2C Arduino Library #define addr 0x1E //I2C Address for The GY-273 void setup(){ Serial.begin(9600); Serial.print("HMC5833L COMPASS SENSOR BEGIN"); Serial.println(); Wire.begin(); Wire.beginTransmission(addr); //start talking Wire.write(0x02); // Set the Register Wire.write(0x00); // Tell the HMC5883 to Continuously Measure Wire.endTransmission(); } void loop(){ int x,y,z; //triple axis data //Tell the HMC what regist to begin writing data into Wire.beginTransmission(addr); Wire.write(0x03); //start with register 3. Wire.endTransmission(); //Read the data.. 2 bytes for each axis.. 6 total bytes Wire.requestFrom(addr, 6); if(6<=Wire.available()){ x = Wire.read()<<8; //MSB x x |= Wire.read(); //LSB x z = Wire.read()<<8; //MSB z z |= Wire.read(); //LSB z y = Wire.read()<<8; //MSB y y |= Wire.read(); //LSB y } Serial.print("X Value: "); Serial.println(x); Serial.print("Y Value: "); Serial.println(y); Serial.print("Z Value: "); Serial.println(z); Serial.println(); delay(1000); }