<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>MPU6050 bare metal program</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/113025/mpu6050-bare-metal-program</link><description>I am looking to program the nRF52840 development board to get data from the mpu6050 sensor. I want to use bare metal code for the same. Is there any available code or sources to establish i2c communication with nRF52840 using bare metal code?</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 16 Jul 2024 02:59:18 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/113025/mpu6050-bare-metal-program" /><item><title>RE: MPU6050 bare metal program</title><link>https://devzone.nordicsemi.com/thread/494012?ContentTypeID=1</link><pubDate>Tue, 16 Jul 2024 02:59:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:42524027-e67f-4faa-aa97-003b3cde6ec1</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;div&gt;The &lt;a href="https://docs.nordicsemi.com/bundle/sdk_nrf5_v17.1.0/page/group__nrf__drivers__mpu6050.html"&gt;nRF5 SDK includes a driver &lt;/a&gt;for the MPU6050 gyro/accelerometer. The driver provides functions for initializing the MPU6050, reading and writing to its registers, and verifying its product ID. Here are the main functions provided by the driver:&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div&gt;&lt;span&gt;&lt;code dir="ltr"&gt;mpu6050_init(uint8_t device_address)&lt;/code&gt;: This function initializes the MPU6050 and verifies it&amp;#39;s on the bus.&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;&lt;span&gt;&lt;code dir="ltr"&gt;mpu6050_register_write(uint8_t register_address, const uint8_t value)&lt;/code&gt;: This function writes a value to a specific MPU6050 register over TWI.&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;&lt;span&gt;&lt;code dir="ltr"&gt;mpu6050_register_read(uint8_t register_address, uint8_t *destination, uint8_t number_of_bytes)&lt;/code&gt;: This function reads one or more consecutive registers of the MPU6050 over TWI.&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;&lt;span&gt;&lt;code dir="ltr"&gt;mpu6050_verify_product_id(void)&lt;/code&gt;: This function reads and verifies the MPU6050 product ID.&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>