<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[GO Plus motor stop]]></title><description><![CDATA[<p dir="auto">Hi all,</p>
<p dir="auto">is the code in</p>
<p dir="auto"><a href="https://github.com/m5stack/GoPlus/blob/master/src/src.ino" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/m5stack/GoPlus/blob/master/src/src.ino</a></p>
<p dir="auto">The actual code that it is shipped with? Apart from the fact that it is a bit of a mess, if i read it right then the dc motors should stop if you send a speed of 0</p>
<p dir="auto">//duty_motor_num = motor_num;<br />
if(motor_speed == 0){<br />
if(motor_num == 0){</p>
<pre><code>  digitalWrite(IN_0, 0);
  digitalWrite(IN_1, 0);
  duty_trun0 = trun;
  duty_speed0 =  motor_speed;
  //MsTimer2::stop(); 
  //time_flag = 0;
  duty0 = 0;
  duty_motor_0_flag = 0;

  //analogWrite(IN_0, 0);
  //analogWrite(IN_1, 0);
}else if(motor_num == 2)
{
 // digitalWrite(IN_2, 0);
  //digitalWrite(IN_3, 0);

  digitalWrite(IN_2, 0);
  digitalWrite(IN_3, 0);
  duty_trun1 = trun;
  duty_speed1 =  motor_speed;
  //MsTimer2::stop(); 
  //time_flag = 0;
  duty1 = 0;
  duty_motor_1_flag = 0;

  // analogWrite(IN_2, 0);
  // analogWrite(IN_3, 0);
} 
</code></pre>
<p dir="auto">}</p>
<p dir="auto">it seems like it shoudl first check if the motor speed is 0 and if that is true then check which motor is send. And if the motorspeed &lt;&gt; 0 then it should look at the direction etc.</p>
<p dir="auto">But the motor never seems to stop... Can anybody confirm that this is a true?</p>
]]></description><link>https://community.m5stack.com/topic/1935/go-plus-motor-stop</link><generator>RSS for Node</generator><lastBuildDate>Wed, 29 Apr 2026 12:21:37 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/1935.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 07 May 2020 14:22:19 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to GO Plus motor stop on Thu, 07 May 2020 16:09:35 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/percramer" aria-label="Profile: percramer">@<bdi>percramer</bdi></a> you have to use a value just below the motors stall value.<br />
To make a motor hard stop you perposely stall the motor however, you have to stall and release the motor as soon as it stops or current will ramp up and possibly damage components.</p>
]]></description><link>https://community.m5stack.com/post/8550</link><guid isPermaLink="true">https://community.m5stack.com/post/8550</guid><dc:creator><![CDATA[ajb2k3]]></dc:creator><pubDate>Thu, 07 May 2020 16:09:35 GMT</pubDate></item></channel></rss>