<?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>defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/52808/defining-mpu-in-ses-insted-of-keil---target-options</link><description>Hello, 
 I have two quastions 
 (1) 
 I am trying to run nrf5-mpu-simple written by , but there are just Keil&amp;#39;s examples on Github and I am working in SES. There is written : Define your MPU in Keil&amp;#39;s &amp;quot;Target Options -&amp;gt; C/C++&amp;quot;. Use define &amp;quot;MPU9255&amp;quot;, </description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 14 Oct 2019 06:02:33 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/52808/defining-mpu-in-ses-insted-of-keil---target-options" /><item><title>RE: defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/thread/214724?ContentTypeID=1</link><pubDate>Mon, 14 Oct 2019 06:02:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4ff79209-5633-4a72-bbfe-e674f5162e47</guid><dc:creator>Susheel Nuguru</dc:creator><description>[quote user="Pepam"]What are these &amp;quot;/033[3;1H&amp;quot; ?[/quote]
&lt;p&gt;&amp;nbsp;looks to me like syntax for t&lt;a href="http://ozzmaker.com/add-colour-to-text-in-python/"&gt;ext coloring&amp;nbsp;&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/thread/214652?ContentTypeID=1</link><pubDate>Fri, 11 Oct 2019 21:00:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5442974f-717c-45e9-86d3-54b534754778</guid><dc:creator>Pepam</dc:creator><description>&lt;p&gt;Thanks for answer. I tried it, but it was eventually better to use that library I attached in my first question. It is working but i do not understand this part of code in printing&amp;nbsp; function. What are these &amp;quot;/033[3;1H&amp;quot; ?&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;err_code = app_mpu_read_gyro(&amp;amp;gyro_values);
            APP_ERROR_CHECK(err_code);
            int16_t sampleX = (gyro_values.x+700)*0.07;
            int32_t average = 0;
            average = calculate_ema(average,sampleX);
 
            NRF_LOG_INFO(&amp;quot;\033[3;1HSample # %d\r\nX:&amp;quot;, sampleX); &lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;thanks&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/thread/213325?ContentTypeID=1</link><pubDate>Fri, 04 Oct 2019 08:07:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3f980cb4-8d0e-49c8-83ff-5cb6f0fe711d</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;Go on - the description seems perfectly clear to me:&lt;/p&gt;
&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/pastedimage1570176283689v1.png" /&gt;&lt;/p&gt;
&lt;p&gt;Parameters&lt;/p&gt;
&lt;table class="params"&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td class="paramdir" colspan="1" rowspan="1"&gt;[in]&lt;/td&gt;
&lt;td class="paramname" colspan="1" rowspan="1"&gt;register_address&lt;/td&gt;
&lt;td colspan="1" rowspan="1"&gt;Register address to start writing to&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class="paramdir" colspan="1" rowspan="1"&gt;[in]&lt;/td&gt;
&lt;td class="paramname" colspan="1" rowspan="1"&gt;value&lt;/td&gt;
&lt;td colspan="1" rowspan="1"&gt;Value to write to register&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;What&amp;#39;s unclear about that?&lt;/p&gt;
&lt;p&gt;If you want to write the value X to register R, you just do:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;success = mpu6050_register_write( R, X );&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Simples!&lt;/p&gt;
&lt;p&gt;The value you write is a single&amp;nbsp;&lt;em&gt;&lt;strong&gt;byte&lt;/strong&gt;&lt;/em&gt;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/thread/213304?ContentTypeID=1</link><pubDate>Fri, 04 Oct 2019 06:06:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5a232b92-0780-4a89-8443-626899119ce8</guid><dc:creator>Pepam</dc:creator><description>&lt;p&gt;I have read it already, but problem is that don&amp;#39;t know in which format and how to pass data to function. Let me explain you, there is written in attached screen I sended that bits 0 to 2 in register 26&amp;nbsp; are responsible for lowpass filter. There is that when you pass number 7 to these bits, it will do some setup, if you pass 6 another setup... So may I pass data to this register by array format? Like this uint8_t data[8] {0,0,0,0,0,1,1,1} ? Is it right?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Thanks&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/thread/213269?ContentTypeID=1</link><pubDate>Thu, 03 Oct 2019 21:24:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c89edd20-8507-4ef3-8c3f-7a49ebcdb8a2</guid><dc:creator>awneil</dc:creator><description>[quote userid="82470" url="~/f/nordic-q-a/52808/defining-mpu-in-ses-insted-of-keil---target-options/213267"]how to do this with mpu6050 driver provided in sdk15.2 using function &amp;quot;bool mpu6050_register_write(uint8_t register_address, const uint8_t value)[/quote]
&lt;p&gt;What does the &lt;strong&gt;documentation&lt;/strong&gt; for&amp;nbsp;the driver tell you?&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.3.0/group__nrf__drivers__mpu6050.html"&gt;infocenter.nordicsemi.com/.../group__nrf__drivers__mpu6050.html&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/thread/213267?ContentTypeID=1</link><pubDate>Thu, 03 Oct 2019 21:12:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7ff8ce37-eb30-42e6-a4c1-2d5630141c2b</guid><dc:creator>Pepam</dc:creator><description>&lt;p&gt;Thank you for your answer. It compiled, but crashed on some error in hardfault handler. Anyway, I wanted run this example just to demonstrate myself if it works and see basics of how it works. I really want to move to sdk15.2 and run mpu6050 with driver provided by Nordic which is placed in sdk. I understand basically how it works, but I have one question. I just want read gyro data from register and do some basic setup but I don&amp;#39;t understand how to write values to registers. For example , here in attached screen shot from mpu register map, there is register 26 (decimal) and there are numbers you can write the numbers to make required setup. Please, can you guide me a bit, how to do this with mpu6050 driver provided in sdk15.2 using function &amp;quot;bool mpu6050_register_write(uint8_t register_address, const uint8_t value)&lt;/p&gt;
&lt;p style="text-align:center;"&gt;Thanks a lot&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;​&lt;/p&gt;
&lt;p&gt;&lt;img style="font-family:inherit;text-align:center;" src="https://devzone.nordicsemi.com/resized-image/__size/960x720/__key/communityserver-discussions-components-files/4/Screenshot_5F00_20191003_2D00_230343.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: defining MPU in SES insted of Keil - Target options</title><link>https://devzone.nordicsemi.com/thread/212954?ContentTypeID=1</link><pubDate>Wed, 02 Oct 2019 09:50:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cabefb89-37c7-445c-bce5-d9731a8cd4ff</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;No, you don&amp;#39;t write #define on the command line like that!&lt;/p&gt;
&lt;p&gt;The place to do it is in the Preprocessor defines.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://wiki.segger.com/Embedded_Studio_Code_Options#Preprocessor"&gt;https://wiki.segger.com/Embedded_Studio_Code_Options#Preprocessor&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Have you tried contacting the Author via Github ?&lt;/p&gt;
&lt;p&gt;When changing SDK, it&amp;#39;s often simpler to just start with a fresh, clean project for that SDK, and merge-in your specific application stuff ...&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>