<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
<link rel="self" type="application/atom+xml" href="http://forum.robosavvy.com/feed.php?f=4&amp;t=7525" />

<title>RoboSavvy Forum</title>
<subtitle>Robosavvy Forum: The largest online community of Humanoid Robot Builders</subtitle>
<link href="http://forum.robosavvy.com/index.php" />
<updated>2011-10-20T04:50:26+01:00</updated>

<author><name><![CDATA[RoboSavvy Forum]]></name></author>
<id>http://forum.robosavvy.com/feed.php?f=4&amp;t=7525</id>
<entry>
<author><name><![CDATA[serithseraki]]></name></author>
<updated>2011-10-20T04:50:26+01:00</updated>
<published>2011-10-20T04:50:26+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32532#p32532</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32532#p32532"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32532#p32532"><![CDATA[
That did it, thanks. The only thing different is &quot;f&quot; is the variable assigned to the joystick. Anyway this is the code that I inserted directly after the right_and_left_step routine.<br /><br /><dl class="codebox"><dt>Code: </dt><dd><code>char=&quot;f&quot; <br />ETX 19200,char<br />loop42:<br />ERX 19200,f,loop42<br />buffer = f<br />IF buffer &gt; 70 THEN GOTO stand_straight<br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br /></code></dd></dl><p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=1735">serithseraki</a> — Thu Oct 20, 2011 4:50 am</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[i-Bot]]></name></author>
<updated>2011-10-19T22:26:06+01:00</updated>
<published>2011-10-19T22:26:06+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32531#p32531</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32531#p32531"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32531#p32531"><![CDATA[
As I said it is difficult without seeing the whole of your code together.<br /><br />I don't see the lable 'retry:, so not sure if this helps.<br /><br />Since you seem to have got to 'right_and_left_step:' from the testing of the data returned from a 'd' command to the remote.<br /><dl class="codebox"><dt>Code: </dt><dd><code>char=&quot;d&quot; 'Byte 3 <br />ETX 19200,char <br /><br />loop6: <br />ERX 19200,d,loop6 <br /></code></dd></dl><br />then<br /><dl class="codebox"><dt>Code: </dt><dd><code>buffer = d <br />IF buffer &gt; 70 THEN GOTO stand_straight <br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br /><br /></code></dd></dl><br /><br />You need to include both of these parts in the test.<br /><dl class="codebox"><dt>Code: </dt><dd><code><br />char=&quot;d&quot; 'Byte 3 <br />ETX 19200,char <br /><br />newlooplable: <br />ERX 19200,d,newlooplable <br />buffer = d <br />IF buffer &gt; 70 THEN GOTO stand_straight <br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br /></code></dd></dl><p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=159">i-Bot</a> — Wed Oct 19, 2011 10:26 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[serithseraki]]></name></author>
<updated>2011-10-19T21:20:20+01:00</updated>
<published>2011-10-19T21:20:20+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32530#p32530</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32530#p32530"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32530#p32530"><![CDATA[
Okay, will inserting this line of code allow the buffer to update?<br /><br />ERX 19200, f, Retry<br />IF buffer &gt; 70 THEN GOTO stand_straight <br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br /><br />I would test this myself but my Robonova needs leg surgery.<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=1735">serithseraki</a> — Wed Oct 19, 2011 9:20 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[i-Bot]]></name></author>
<updated>2011-10-19T20:37:09+01:00</updated>
<published>2011-10-19T20:37:09+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32529#p32529</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32529#p32529"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32529#p32529"><![CDATA[
At the end of right_and_left_step: you check the value of buffer, but you did not update buffer with the current value from the joystick, so it just stays in a loop.<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=159">i-Bot</a> — Wed Oct 19, 2011 8:37 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[serithseraki]]></name></author>
<updated>2011-10-19T19:44:56+01:00</updated>
<published>2011-10-19T19:44:56+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32527#p32527</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32527#p32527"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32527#p32527"><![CDATA[
Sorry for the confusion, and the length of the code. I originally tried to post the full startup portion with the walking motions to make it understandable but I suppose the post was too long and was shorted when posting it. Furthermore, I have no idea how IF buffer &lt;70&gt; 70 THEN GOTO stand_straight was posted like that. The code for the walking motions should be as written below.<br /><br />'===============================================<br />forward_walk:<br />'stand straight, arms out<br />MOVE24 100,76,145,94,100, ,100,40,80, , , ,100,40,80, , , ,100,76,145,94,100, ,<br />SPEED 2<br />'shift weight right<br />MOVE24 82,76,145,94,114, ,100,40,80, , , ,100,40,80, , , ,112,76,145,94,90, ,<br />SPEED 5<br />'lift left leg<br />MOVE24 90,60,156,99,114, ,90,40,80, , , ,100,40,80, , , ,114,76,145,94,94, ,<br />SPEED 7<br />'bring left leg forward<br />MOVE24 90,63,156,96,114, ,80,40,80, , , ,105,40,80, , , ,114,98,117,99,94, ,<br />SPEED 2<br />RETURN<br />'===============================================<br />right_and_left_step:<br />'center body<br />MOVE24 100,63,156,96,100, ,90,40,80, , , ,105,40,80, , , ,100,100,117,99,100, ,<br />'shift weight left<br />MOVE24 112,76,145,96,90, ,100,40,80, , , ,105,40,80, , , ,82,100,117,99,114, ,<br />SPEED 5<br />'lift right leg<br />MOVE24 114,76,145,94,94, ,100,40,80, , , ,90,40,80, , , ,90,60,156,99,114, ,<br />SPEED 7<br />'bring right leg forward<br />MOVE24 114,98,117,99,94, ,105,40,80, , , ,80,40,80, , , ,90,63,156,96,114, ,<br />SPEED 2<br />'center body<br />MOVE24 100,100,117,99,100, ,105,40,80, , , ,90,40,80, , , ,100,63,156,96,100, ,<br />'shift weight right<br />MOVE24 82,100,117,99,114, ,105,40,80, , , ,100,40,80, , , ,112,76,145,96,90, ,<br />SPEED 5<br />'lift left leg<br />MOVE24 90,60,156,99,114, ,90,40,80, , , ,100,40,80, , , ,114,76,145,94,94, ,<br />SPEED 7<br />'bring left leg forward<br />MOVE24 90,63,156,96,114, ,80,40,80, , , ,105,40,80, , , ,114,98,117,99,94, ,<br />SPEED 2<br />'center body<br />MOVE24 100,63,156,96,100, ,90,40,80, , , ,105,40,80, , , ,100,100,117,99,100, ,<br />IF buffer &gt; 70 THEN GOTO stand_straight<br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br />'===============================================<br />stand_straight:<br />'shift weight left<br />MOVE24 112,76,145,96,90, ,100,40,80, , , ,105,40,80, , , ,82,100,117,99,114, ,<br />SPEED 5<br />'straighten right leg<br />MOVE24 112,76,145,96,94, ,100,40,80, , , ,100,40,80, , , ,88,77,140,96,114, ,<br />SPEED 2<br />'stand straight, arms out<br />MOVE24 100,76,145,94,100, ,100,40,80, , , ,100,40,80, , , ,100,76,145,94,100, ,<br />RETURN<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=1735">serithseraki</a> — Wed Oct 19, 2011 7:44 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[i-Bot]]></name></author>
<updated>2011-10-19T17:35:37+01:00</updated>
<published>2011-10-19T17:35:37+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32526#p32526</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32526#p32526"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32526#p32526"><![CDATA[
I did not understand the context of the code:<br /><dl class="codebox"><dt>Code: </dt><dd><code>buffer = d <br />IF buffer &lt;70&gt; 70 THEN GOTO stand_straight <br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br />'=============================================== <br />stand_straight: <br />'shift weight left <br />MOVE24 112,76,145,96,90, ,100,40,80, , , ,105,40,80, , , ,82,100,117,99,114, , <br />SPEED 5 <br />'straighten right leg <br />MOVE24 112,76,145,96,94, ,100,40,80, , , ,100,40,80, , , ,88,77,140,96,114, , <br />SPEED 2 <br />'stand straight, arms out <br />MOVE24 100,76,145,94,100, ,100,40,80, , , ,100,40,80, , , ,100,76,145,94,100, , <br />RETURN <br /></code></dd></dl><br /><br />There is an error on the second line, also I do not see if there is a goto main somewhere or if you fall through the stand straight, which has a return, without a call.<br /><br />Is right_and_left_step, your walking routine, which is continually called ?<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=159">i-Bot</a> — Wed Oct 19, 2011 5:35 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[serithseraki]]></name></author>
<updated>2011-10-19T16:17:03+01:00</updated>
<published>2011-10-19T16:17:03+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32525#p32525</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32525#p32525"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32525#p32525"><![CDATA[
Well the only important portion of the code that should allow the motion to loop or go to the next motion is this that is meant to be inserted after the right_and_left_step motion &quot;not sure why my actual post was condensed so I could not show this&quot;.<br /><br />IF buffer &gt; 70 THEN GOTO stand_straight <br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br /><br />Although this code seems to make it walk continually without ever stopping. But if I insert a wait command after the walk motion will the controller read the joystick position automatically or do I need to use a retry to allow it to read the current position?<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=1735">serithseraki</a> — Wed Oct 19, 2011 4:17 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[i-Bot]]></name></author>
<updated>2011-10-19T12:45:17+01:00</updated>
<published>2011-10-19T12:45:17+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32524#p32524</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32524#p32524"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32524#p32524"><![CDATA[
It is difficult to understand with such a large program and you only showing part of it.<br /><br />Why don't you cut the program down to simplify your own debugging and to enable others to help ?<br /><br />MOVE24 will WAIT if it is called again while still moving. MOVE24 without a WAIT following will test the buttons during a previous MOVE24.  If you put a WAIT after the MOVE24, the buttons will be tested after the MOVE24 is complete.<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=159">i-Bot</a> — Wed Oct 19, 2011 12:45 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[serithseraki]]></name></author>
<updated>2011-10-18T17:39:08+01:00</updated>
<published>2011-10-18T17:39:08+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32515#p32515</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32515#p32515"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32515#p32515"><![CDATA[
So I need a wait command to initiate a break in the code? I thought that wasn't needed for the move24 command. Also, for reading the placement of the joystick, should I use a Retry command? Regardless, here is my current code so you can see my failed attempt, and note my Robonova has a different leg configuration.<br /><br />DIM buffer AS BYTE<br />DIM char AS BYTE<br />DIM a AS BYTE<br />DIM b AS BYTE<br />DIM c AS BYTE<br />DIM d AS BYTE<br />DIM e AS BYTE<br />DIM f AS BYTE<br />DIM i AS BYTE<br />DIM X AS BYTE<br />DIM A16 AS BYTE<br /><br />ERX 19200, b, bemt1 'Empty the RX buffer<br />bemt1:<br />ERX 19200, b, bemt2<br />bemt2:<br />ERX 19200, a, bemt3 <br />bemt3:<br />ERX 19200, a, bemt4<br />bemt4:<br />ERX 19200, f, bemt5<br />bemt5:<br />ERX 19200, f,bemt6<br />bemt6:<br />ERX 19200, i, bemt7<br />bemt7:<br />ERX 19200, i,bemt8<br />bemt8:<br />ERX 19200, d, bemt9<br />bemt9:<br />ERX 19200, d, bemt10<br />bemt10:<br /><br /><br />'== motor diretion setting ======================<br />DIR G6A,1,0,0,1,0,0 <br />DIR G6B,1,1,1,1,1,1 <br />DIR G6C,0,0,0,0,0,0 <br />DIR G6D,0,1,1,0,1,0 <br /><br />'== motor start position read ===================<br />GETMOTORSET G6A,1,1,1,1,1,0<br />GETMOTORSET G6B,1,1,1,0,0,0<br />GETMOTORSET G6C,1,1,1,0,0,0<br />GETMOTORSET G6D,1,1,1,1,1,0<br />SPEED 5<br />'== motor power on =============================<br />MOTOR G24 <br />'===============================================GOSUB standard_pose<br /><br />main:<br />OUT 52,0<br />FPWM 2,1,0<br /><br />char=&quot;a&quot; 'Byte 0<br />ETX 19200,char 'Send character<br /><br />loop1:<br />ERX 19200,a,loop1 'Receive character<br /><br /><br />char=&quot;b&quot; 'Byte 1<br />ETX 19200,char 'Send character<br /><br />loop2:<br />ERX 19200,b,loop2 'Receive character<br /><br />char=&quot;e&quot; 'Byte 4<br />ETX 19200,char<br />loop3:<br />ERX 19200,e,loop3<br /><br />char=&quot;f&quot; 'Byte 5<br />ETX 19200,char<br /><br />loop4:<br />ERX 19200,f,loop4<br /><br />char=&quot;c&quot; 'Byte 2<br />ETX 19200,char<br /><br />loop5:<br />ERX 19200,c,loop5<br /><br />char=&quot;d&quot; 'Byte 3<br />ETX 19200,char<br /><br />loop6:<br />ERX 19200,d,loop6<br /><br />GOTO movement<br /><br />movement: 'Use single Bit<br /><br />buffer = a.0 <br />IF buffer = 0 THEN GOTO move14 'Select<br />buffer = a.1 <br />IF buffer = 0 THEN GOTO move3 'L3<br />buffer = a.2<br />IF buffer = 0 THEN GOTO move2 'R3<br />buffer = a.3 <br />IF buffer = 0 THEN GOTO move13 'Start<br />buffer = a.4 <br />IF buffer = 0 THEN GOTO move15 'Up<br />buffer = a.5 <br />IF buffer = 0 THEN GOTO move4 'Right<br />buffer = a.6 <br />IF buffer = 0 THEN GOTO move16 'Down<br />buffer = a.7 <br />IF buffer = 0 THEN GOTO move3 'Left<br /><br />buffer = b.0 <br />IF buffer = 0 THEN GOTO move12 'L2<br />buffer = b.1 <br />IF buffer = 0 THEN GOTO move10 'R2<br />buffer = b.2 <br />IF buffer = 0 THEN GOTO move11 'L1<br />buffer = b.3 <br />IF buffer = 0 THEN GOTO move9 'R1<br />buffer = b.4 <br />IF buffer = 0 THEN GOTO move6 'Triangle<br />buffer = b.5 <br />IF buffer = 0 THEN GOTO move5 'Square<br />buffer = b.6 <br />IF buffer = 0 THEN GOTO move8 'Cross<br />buffer = b.7 <br />IF buffer = 0 THEN GOTO move7 'Circle<br /><br />buffer = e<br />IF buffer &lt; 70 THEN GOTO move12 'Left Joystick Left<br />IF buffer &gt; 180 THEN GOTO move10'Left Joystick Right<br /><br />buffer = f<br />IF buffer &lt;70 THEN GOTO move1 'Left Joystick Up<br />IF buffer &gt; 180 THEN GOTO move2'Left Joystick Down<br /><br />buffer = c<br />IF buffer &lt; 70 THEN GOTO move7'Right Joystick Left<br />IF buffer &gt; 180 THEN GOTO move5'Right Joystick Right<br /><br />buffer = d<br />IF buffer &lt;70&gt; 70 THEN GOTO stand_straight<br />IF buffer &lt; 70 THEN GOTO right_and_left_step <br />'===============================================<br />stand_straight:<br />'shift weight left<br />MOVE24 112,76,145,96,90, ,100,40,80, , , ,105,40,80, , , ,82,100,117,99,114, ,<br />SPEED 5<br />'straighten right leg<br />MOVE24 112,76,145,96,94, ,100,40,80, , , ,100,40,80, , , ,88,77,140,96,114, ,<br />SPEED 2<br />'stand straight, arms out<br />MOVE24 100,76,145,94,100, ,100,40,80, , , ,100,40,80, , , ,100,76,145,94,100, ,<br />RETURN<br />'===============================================<br />standard_pose:<br />MOVE G6A,98, 76, 145,  93, 102<br />MOVE G6D,98, 76, 145,  93, 102<br />MOVE G6B,100,  30,  80<br />MOVE G6C,100,  30,  80<br />WAIT<br />RETURN<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=1735">serithseraki</a> — Tue Oct 18, 2011 5:39 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[i-Bot]]></name></author>
<updated>2011-10-18T12:33:53+01:00</updated>
<published>2011-10-18T12:33:53+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32514#p32514</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32514#p32514"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32514#p32514"><![CDATA[
When you develop your program you need to remember that the MOVE takes a finite time to execute. After starting a MOVE you can execute other program steps to read the controller. However it you do a WAIT, then the program will pause until the MOVE is complete. A MOVE command also has a WAIT integrated into the start of itself. So executing MOVE a second time will wait until the first move is complete and pause the program.<br /><br />Try to use tones as feedback of the state of buttons and program.<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=159">i-Bot</a> — Tue Oct 18, 2011 12:33 pm</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[serithseraki]]></name></author>
<updated>2011-10-17T22:43:37+01:00</updated>
<published>2011-10-17T22:43:37+01:00</published>
<id>http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32511#p32511</id>
<link href="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32511#p32511"/>
<title type="html"><![CDATA[Code for continual motion?]]></title>

<content type="html" xml:base="http://forum.robosavvy.com/viewtopic.php?t=7525&amp;p=32511#p32511"><![CDATA[
Looking at the Robonova Wiki I saw a link for continual walking that apparently has become a dead link. Anyway, would someone have a sample code they are willing to share for this ability? I have currently been playing with the 2.4GHz controller and am trying to create a motion that has the robot walk forward continually when the joystick value is less than seventy and then stop when the joystick is at a greater value. Which it does walk continually but does not stop. Another idea I had was setting one button as a return command and having select motions be associated to it so certain motions would loop until said button was pressed. But I have no idea how to create such a code if it would even work at all.<p>Statistics: Posted by <a href="http://forum.robosavvy.com/memberlist.php?mode=viewprofile&amp;u=1735">serithseraki</a> — Mon Oct 17, 2011 10:43 pm</p><hr />
]]></content>
</entry>
</feed>