{"product_id":"mikroe-3099","title":"Gaussmeter click","description":"\u003cp\u003e\u003ca class=\"btn-download\" href=\"https:\/\/download.mikroe.com\/documents\/2d-3d-files\/gaussmeter-click-2d-and-3d-files-v100.zip\" target=\"_blank\"\u003e \u003c\/a\u003e\u003c\/p\u003e\n\u003cp\u003eA range of on-chip features including low power consumption, programmable interrupt engine, 1KB of volatile + 1 KB of non-volatile memory, integrated thermal sensor, onboard digital filtering, high resolution sampling, and more, make this sensor a perfect solution for various low power applications used to detect a magnetic and electromagnetic field (EMF) presence along all three axes. It can be used to detect a rotary or linear movement of the magnetic elements or to measures EMF from mains electrical devices and other (very low frequency) EMF sources, such as from mains electricity, power lines, high voltage lines, transformers, and so on.\u003c\/p\u003e\n\u003cp\u003e\u003cstrong\u003eHow does it work\u003c\/strong\u003e\u003c\/p\u003e\n\u003cp\u003eGaussmeter click employs the \u003ca href=\"https:\/\/download.mikroe.com\/documents\/datasheets\/MLX90393%20Datasheet.pdf\"\u003eMLX90393\u003c\/a\u003e, a micropower magnetometer based on the proprietary Triaxis\u003csup\u003e®\u003c\/sup\u003e technology, from \u003ca href=\"https:\/\/www.melexis.com\/en\"\u003eMelexis\u003c\/a\u003e. This IC is based on the Hall effect principle, which allows it to detect very small fluctuations in the magnetic field. The Hall sensor plates, featuring the patented IMC technology, are located in the center of the die, which is located in the center of the package.\u003cbr\u003e \u003cbr\u003e \u003cimg src=\"https:\/\/www.mikroe.com\/img\/cms\/gaussmeter-click-insdie-image.jpg\" alt=\"\"\u003e\u003c\/p\u003e\n\u003cp\u003eThe measurement current, generated as a result of the Hall effect, is passed through the transimpedance amplifier (TIA) and sampled by the 19-bit A\/D converter (ADC). The output is the truncated to 16-bits, by applying the bit-shifting operation, programmed by the user (RES_XYZ bits). This allows the range to be dynamically set, according to measurement conditions, leaving unused MSBs or LSBs out. Additionally, it is possible to set the TIA gain level in the range from 0 to 7 to best match the field strength. The value of the RES bits and the gain level both affect the sensitivity of the sensor. The MLX90393 datasheet contains a table with the RES and GAIN, and corresponding µT\/LSB values.\u003c\/p\u003e\n\u003cp\u003eWhen required, it is possible to set the oversampling rate of the ADC decimation filter. This will provide less noise and more consistent readings. However, oversampling affects the data acquisition time, as the sampling process has to be repeated a number of times, depending on the oversampling rate. If the fast response is required, the oversampling and digital filtering functions should be turned off.\u003c\/p\u003e\n\u003cp\u003eThe measurement is affected by the temperature. Therefore, the MLX90393 is also equipped with the temperature sensor, used to provide the required measurements. The thermal sensitivity drift compensation can be enabled by the appropriate bit in the configuration register. Two sensitivity drift compensation factors can be used, one for temperatures greater than the reference and other for the temperatures lesser than the reference value.\u003c\/p\u003e\n\u003cp\u003eWakeup on Change (WOC) mode is used to alert the MCU via the interrupt pin when certain conditions are met. It can be configured to trigger an interrupt on the INT pin if the difference between the reference measurement value and the current measurement value exceed a threshold defined by the user. The reference measurement value can be set in three different ways:\u003c\/p\u003e\n\u003cul\u003e\n\u003cli\u003eThe first measurement in WOC mode is set as the measurement reference value, which is then used for comparison.\u003c\/li\u003e\n\u003cli\u003eThe reference value is always the previous measurement. Every new measurement sets the previous one as the reference value.\u003c\/li\u003e\n\u003cli\u003eBoth the thresholds and the reference value are programmed by the user.\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003eThe interrupt is reported on the INT pin of the IC, routed to the INT pin of the mikroBUS™, and\/or on the INT\/TRIG pin, routed to the mikroBUS™ PWM pin (labeled as TRG), if it is configured that way. The INT\/TRIG pin can also be set as the trigger input, by configuring the corresponding bits (TRIG_INT_SEL and EXT_TRIG). These pins are active HIGH.\u003c\/p\u003e\n\u003cp\u003eBesides the WOC mode, there is also Burst and Single Measurement modes. Both of these modes can use the INT pin to signalize that there is a conversion data ready to be read. Once the MCU reads the data, the INT\/Data Ready event will be cleared. The Burst mode provides data in programmed intervals, while Single Measurement mode will provide one reading when commanded, signal it via the INT pin and revert to IDLE mode, consuming less power.\u003c\/p\u003e\n\u003cp\u003eThe MLX90393 sensor contains 1KB of volatile (RAM) memory. This memory is used to store config parameters and register values, but also there are some free locations for storing user information, e.g. compensation values and similar. Besides 1KB of volatile memory, there is also 1KB of non-volatile memory. During the POR, the complete content of the NV memory is automatically copied to the RAM restoring the saved working parameters that way. There are also commands available for the user, in order to store to or restore RAM data from the non-volatile (NV) memory. However, it is not recommended to write to the NV memory area too often, as this type of memory has an inherently limited life cycle.\u003c\/p\u003e\n\u003cp\u003eThis Click board™ allows both SPI and I2C communication protocols. To select a proper protocol, the SMD jumpers labeled as SEL COM should be moved to the appropriate position (I2C or SPI). Please note that both jumpers need to be at the same setting (both as SPI or both as I2C).\u003c\/p\u003e\n\u003cp\u003eThe I2C address of the Click board™ is selectable by the onboard SMD jumpers, labeled as I2C ADDR. These two jumpers directly set the values of the LSB address of the IC. The 7-bit address of the device is 00011XXZ, where XX are the values set by these jumpers, while Z is the R\/W bit. \u003cbr\u003e \u003c\/p\u003e\n\u003cp\u003e\u003cstrong\u003eSpecifications\u003c\/strong\u003e\u003c\/p\u003e\n\u003ctable\u003e\n\u003ctbody\u003e\n\u003ctr\u003e\n\u003ctd\u003eType\u003c\/td\u003e\n\u003ctd\u003eHall effect\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eApplications\u003c\/td\u003e\n\u003ctd\u003eIt can be used to detect a rotary or linear movement of the magnetic elements, or to measures EMF from mains electrical devices and other EMF sources, such as from mains electricity, power lines, high voltage lines, transformers, and so on\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eOn-board modules\u003c\/td\u003e\n\u003ctd\u003eMLX90393, a micropower magnetometer based on the proprietary Triaxis® technology, from Melexis\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eKey Features\u003c\/td\u003e\n\u003ctd\u003eA proprietary Triaxis® technology allows sensing of wide range of magnetic field values, high accuracy and low noise, thermal sensing element included, allows both I2C and SPI communication protocols, NV memory for storing config data after POR\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eInterface\u003c\/td\u003e\n\u003ctd\u003eI2C,SPI\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eInput Voltage\u003c\/td\u003e\n\u003ctd\u003e3.3V\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eClick board size\u003c\/td\u003e\n\u003ctd\u003eM (42.9 x 25.4 mm)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003c\/tbody\u003e\n\u003c\/table\u003e\n\u003cp\u003e \u003c\/p\u003e\n\u003cp\u003e\u003cstrong\u003ePinout diagram\u003c\/strong\u003e\u003c\/p\u003e\n\u003cp\u003eThis table shows how the pinout on \u003cstrong\u003eGaussmeter click\u003c\/strong\u003e corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).\u003c\/p\u003e\n\u003ctable style=\"width: 549px;\"\u003e\n\u003ctbody\u003e\n\u003ctr\u003e\n\u003cth\u003eNotes\u003c\/th\u003e\n\u003cth\u003ePin\u003c\/th\u003e\n\u003cth colspan=\"4\"\u003e\u003ca href=\"http:\/\/www.mikroe.com\/mikrobus\/\"\u003e\u003cimg src=\"https:\/\/cdn.mikroe.com\/img\/mikrobus\/mikroBUS-logo-black.png\" alt=\"Mikrobus logo.png\"\u003e\u003c\/a\u003e\u003c\/th\u003e\n\u003cth\u003ePin\u003c\/th\u003e\n\u003cth\u003eNotes\u003c\/th\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e \u003c\/td\u003e\n\u003ctd\u003eNC\u003c\/td\u003e\n\u003ctd\u003e1\u003c\/td\u003e\n\u003ctd\u003eAN\u003c\/td\u003e\n\u003ctd\u003ePWM\u003c\/td\u003e\n\u003ctd\u003e16\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eTRG\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003eInterrupt\/Trigger\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e \u003c\/td\u003e\n\u003ctd\u003eNC\u003c\/td\u003e\n\u003ctd\u003e2\u003c\/td\u003e\n\u003ctd\u003eRST\u003c\/td\u003e\n\u003ctd\u003eINT\u003c\/td\u003e\n\u003ctd\u003e15\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eINT\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003eInterrupt\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eSPI Chip Select\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eCS\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003e3\u003c\/td\u003e\n\u003ctd\u003eCS\u003c\/td\u003e\n\u003ctd\u003eRX\u003c\/td\u003e\n\u003ctd\u003e14\u003c\/td\u003e\n\u003ctd\u003eNC\u003c\/td\u003e\n\u003ctd\u003e \u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eSPI Clock\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eSCK\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003e4\u003c\/td\u003e\n\u003ctd\u003eSCK\u003c\/td\u003e\n\u003ctd\u003eTX\u003c\/td\u003e\n\u003ctd\u003e13\u003c\/td\u003e\n\u003ctd\u003eNC\u003c\/td\u003e\n\u003ctd\u003e \u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eSPI Data OUT\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eSDO\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003e5\u003c\/td\u003e\n\u003ctd\u003eMISO\u003c\/td\u003e\n\u003ctd\u003eSCL\u003c\/td\u003e\n\u003ctd\u003e12\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eSCL\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003eI2C Clock\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eSPI Data IN\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eSDI\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003e6\u003c\/td\u003e\n\u003ctd\u003eMOSI\u003c\/td\u003e\n\u003ctd\u003eSDA\u003c\/td\u003e\n\u003ctd\u003e11\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eSDA\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003eI2C Data\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003ePower supply\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003e3.3V\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003e7\u003c\/td\u003e\n\u003ctd\u003e3.3V\u003c\/td\u003e\n\u003ctd\u003e5V\u003c\/td\u003e\n\u003ctd\u003e10\u003c\/td\u003e\n\u003ctd\u003eNC\u003c\/td\u003e\n\u003ctd\u003e \u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eGround\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eGND\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003e8\u003c\/td\u003e\n\u003ctd\u003eGND\u003c\/td\u003e\n\u003ctd\u003eGND\u003c\/td\u003e\n\u003ctd\u003e9\u003c\/td\u003e\n\u003ctd\u003e\u003cstrong\u003eGND\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd\u003eGround\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003c\/tbody\u003e\n\u003c\/table\u003e\n\u003cp\u003e\u003cbr\u003e \u003cstrong\u003eOnboard jumpers and settings\u003c\/strong\u003e\u003c\/p\u003e\n\u003ctable\u003e\n\u003ctbody\u003e\n\u003ctr\u003e\n\u003cth\u003eLabel\u003c\/th\u003e\n\u003cth\u003eName\u003c\/th\u003e\n\u003cth\u003eDefault\u003c\/th\u003e\n\u003cth\u003eDescription\u003c\/th\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eLD1\u003c\/td\u003e\n\u003ctd\u003ePWR\u003c\/td\u003e\n\u003ctd\u003e-\u003c\/td\u003e\n\u003ctd\u003ePower LED indicator\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eJP_A0, JP_A1\u003c\/td\u003e\n\u003ctd\u003eI2C ADR\u003c\/td\u003e\n\u003ctd\u003eLeft\u003c\/td\u003e\n\u003ctd\u003eI2C address bit selection: left position 0, right position 1\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003eJP_1, JP_2\u003c\/td\u003e\n\u003ctd\u003eSEL COM\u003c\/td\u003e\n\u003ctd\u003eLeft\u003c\/td\u003e\n\u003ctd\u003eCommunication protocol selection: left position SPI, right position I2C\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003c\/tbody\u003e\n\u003c\/table\u003e\n\u003cp\u003e\u003cbr\u003e \u003cstrong\u003eSoftware Support\u003c\/strong\u003e\u003cbr\u003e \u003cbr\u003e We provide a library for the Gaussmeter Click on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.\u003cbr\u003e \u003cbr\u003e \u003cstrong\u003eLibrary Description\u003c\/strong\u003e\u003cbr\u003e \u003cbr\u003e Library initializes and defines I2C and SPI driver and has the ability to write to registers and read from registers by both driver communication. Library also performs magnetic field measurement via x, y and\/or z-axis and converts results to µT. The library can measure 16-bit temperature value. For more details check the documentation.\u003cbr\u003e \u003cbr\u003e Key functions \u003c\/p\u003e\n\u003cp\u003e\u003ccode\u003evoid gaussmeter_enableMeasure( uint8_t zAxis, uint8_t yAxis, uint8_t xAxis, uint8_t temp )\u003c\/code\u003e - Function determines which axis be included in the measurement.\u003cbr\u003e \u003cbr\u003e \u003ccode\u003euint8_t gaussmeter_sendCommand( uint8_t command_ )\u003c\/code\u003e - Function performs desired command.\u003cbr\u003e \u003cbr\u003e \u003ccode\u003euint8_t gaussmeter_readReg( uint8_t register_address, uint16_t *dataOut )\u003c\/code\u003e - Function reads 16-bit data from register.\u003cbr\u003e \u003cbr\u003e \u003ccode\u003euint8_t gaussmeter_writeReg( uint8_t register_address, uint16_t transfer_data )\u003c\/code\u003e - Function writes 16-bit data in register.\u003cbr\u003e \u003cbr\u003e \u003ccode\u003euint8_t gaussmeter_getData( float *dataOut )\u003c\/code\u003e - Function gets selected measured data.\u003c\/p\u003e\n\u003cp\u003e\u003cbr\u003e Examples Description\u003cbr\u003e \u003cbr\u003e The application is composed of three sections :\u003cbr\u003e \u003cbr\u003e System Initialization - Initializes peripherals and pins.\u003cbr\u003e Application Initialization - Initializes I2C or SPI driver and performs click configuration.\u003cbr\u003e The device is configured to work in Wake Up On Change mode.\u003cbr\u003e Application Task - (code snippet) - Gets x, y and z-axis measured data (without temperature) in µT.\u003cbr\u003e Logs the desired results on USBUART and repeats measurements every 400ms.\u003cbr\u003e \u003cbr\u003e \u003c\/p\u003e\n\u003cpre\u003evoid applicationTask()\n{\nerrorBit = gaussmeter_getData( \u0026amp;bufferData[ 0 ] );\n\nif (!errorBit)\n{\naxisCheck = 1;\nindx = 0;\n\nfor (counter = 0; counter \u0026lt; 4; counter++)\n{\nswitch (commandByteLow \u0026amp; axisCheck)\n{\ncase 1 : \n{\nmikrobus_logWrite( \"16-bit temperature value is: \", _LOG_TEXT );\nFloatToStr( bufferData[ indx ], text );\nfloatConv();\nmikrobus_logWrite( text, _LOG_LINE );\nindx++;\nbreak;\n}\ncase 2 : \n{\nmikrobus_logWrite( \"X axis is: \", _LOG_TEXT );\nFloatToStr( bufferData[ indx ], text );\nfloatConv();\nmikrobus_logWrite( text, _LOG_TEXT );\nmikrobus_logWrite( \" microT\", _LOG_LINE );\nindx++;\nbreak;\n}\ncase 4 : \n{\nmikrobus_logWrite( \"Y axis is: \", _LOG_TEXT );\nFloatToStr( bufferData[ indx ], text );\nfloatConv();\nmikrobus_logWrite( text, _LOG_TEXT );\nmikrobus_logWrite( \" microT\", _LOG_LINE );\nindx++;\nbreak;\n}\ncase 8 : \n{\nmikrobus_logWrite( \"Z axis is: \", _LOG_TEXT );\nFloatToStr( bufferData[ indx ], text );\nfloatConv();\nmikrobus_logWrite( text, _LOG_TEXT );\nmikrobus_logWrite( \" microT\", _LOG_LINE );\nindx++;\nbreak;\n}\ndefault :\n{\nbreak;\n}\n}\n\naxisCheck \u0026lt;\u0026lt;= 1;\n}\nmikrobus_logWrite( \"\", _LOG_LINE );\nDelay_ms( 400 );\n}\n}\u003c\/pre\u003e\n\u003cp\u003e\u003cbr\u003e Additional Functions :\u003c\/p\u003e\n\u003cul\u003e\n\u003cli\u003evoid floatConv() - Makes the float values be rounded to two decimal places\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003eThe complete application code, and ready to use projects can be found on our \u003cbr\u003e LibStock page.\u003cbr\u003e \u003cbr\u003e Other mikroE Libraries used in the example:\u003cbr\u003e \u003c\/p\u003e\n\u003cul\u003e\n\u003cli\u003eConversions\u003c\/li\u003e\n\u003cli\u003eI2C\u003c\/li\u003e\n\u003cli\u003eSPI\u003c\/li\u003e\n\u003cli\u003eUART\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003e \u003c\/p\u003e\n\u003cp\u003e\u003cstrong\u003eAdditional notes and information\u003c\/strong\u003e\u003c\/p\u003e\n\u003cp\u003eDepending on the development board you are using, you may need \u003ca href=\"https:\/\/shop.mikroe.com\/usb-uart-click\"\u003eUSB UART click\u003c\/a\u003e, \u003ca href=\"https:\/\/shop.mikroe.com\/usb-uart-2-click\"\u003eUSB UART 2 click\u003c\/a\u003e or \u003ca href=\"https:\/\/shop.mikroe.com\/rs232-click\"\u003eRS232 click\u003c\/a\u003e to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika \u003ca href=\"https:\/\/shop.mikroe.com\/compilers\"\u003ecompilers\u003c\/a\u003e, or any other terminal application of your choice, can be used to read the message.\u003c\/p\u003e\n\u003cp\u003e\u003cstrong\u003emikroSDK\u003c\/strong\u003e\u003c\/p\u003e\n\u003cp\u003eThis click board is supported with \u003ca href=\"https:\/\/www.mikroe.com\/mikrosdk\"\u003emikroSDK\u003c\/a\u003e - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant click board demo applications, mikroSDK should be downloaded from the \u003ca href=\"https:\/\/libstock.mikroe.com\/projects\/view\/2249\/mikrosdk\"\u003eLibStock\u003c\/a\u003e and installed for the compiler you are using.\u003cbr\u003e \u003cbr\u003e\u003cbr\u003e\u003c\/p\u003e","brand":"MikroElektronika","offers":[{"title":"Default Title","offer_id":47400890040603,"sku":"MIKROE-3099","price":1999.0,"currency_code":"INR","in_stock":false}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0676\/3325\/0587\/products\/gaussmeter-click-thickbox_default-275shHTmtTO9wa.jpg?v=1701962360","url":"https:\/\/mgsl.in\/products\/mikroe-3099","provider":"MG Super Labs","version":"1.0","type":"link"}