<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://wiki.randomdata.nl/w/index.php?action=history&amp;feed=atom&amp;title=Roambot</id>
	<title>Roambot - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.randomdata.nl/w/index.php?action=history&amp;feed=atom&amp;title=Roambot"/>
	<link rel="alternate" type="text/html" href="https://wiki.randomdata.nl/w/index.php?title=Roambot&amp;action=history"/>
	<updated>2026-04-13T15:42:37Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.44.2</generator>
	<entry>
		<id>https://wiki.randomdata.nl/w/index.php?title=Roambot&amp;diff=1305&amp;oldid=prev</id>
		<title>imported&gt;Zkyp at 17:48, 7 June 2011</title>
		<link rel="alternate" type="text/html" href="https://wiki.randomdata.nl/w/index.php?title=Roambot&amp;diff=1305&amp;oldid=prev"/>
		<updated>2011-06-07T17:48:34Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en-GB&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 17:48, 7 June 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l2&quot;&gt;Line 2:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 2:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Is the bot that won the HiTB2011AMS hackerspaces challenge.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Is the bot that won the HiTB2011AMS hackerspaces challenge.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;http://www.randomdata.nl/blogs/node/42&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[File:P1050218.JPG]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Here&amp;#039;s the code!  &lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Here&amp;#039;s the code!  &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key my_wiki:diff:1.41:old-1304:rev-1305:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>imported&gt;Zkyp</name></author>
	</entry>
	<entry>
		<id>https://wiki.randomdata.nl/w/index.php?title=Roambot&amp;diff=1304&amp;oldid=prev</id>
		<title>imported&gt;Zkyp at 17:47, 7 June 2011</title>
		<link rel="alternate" type="text/html" href="https://wiki.randomdata.nl/w/index.php?title=Roambot&amp;diff=1304&amp;oldid=prev"/>
		<updated>2011-06-07T17:47:06Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en-GB&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 17:47, 7 June 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l4&quot;&gt;Line 4:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 4:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Here&amp;#039;s the code!  &lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Here&amp;#039;s the code!  &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;pre&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#define DROP_DISTANCE 25&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#define DROP_DISTANCE 25&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l127&quot;&gt;Line 127:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 127:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     }&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/pre&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key my_wiki:diff:1.41:old-1303:rev-1304:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>imported&gt;Zkyp</name></author>
	</entry>
	<entry>
		<id>https://wiki.randomdata.nl/w/index.php?title=Roambot&amp;diff=1303&amp;oldid=prev</id>
		<title>imported&gt;Zkyp: Created page with &quot;Roambot  Is the bot that won the HiTB2011AMS hackerspaces challenge.  Here&#039;s the code!    #define DROP_DISTANCE 25  task main() {     SetSensorLight(IN_1);     SetSensorLight(IN_...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.randomdata.nl/w/index.php?title=Roambot&amp;diff=1303&amp;oldid=prev"/>
		<updated>2011-06-07T17:44:14Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;Roambot  Is the bot that won the HiTB2011AMS hackerspaces challenge.  Here&amp;#039;s the code!    #define DROP_DISTANCE 25  task main() {     SetSensorLight(IN_1);     SetSensorLight(IN_...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Roambot&lt;br /&gt;
&lt;br /&gt;
Is the bot that won the HiTB2011AMS hackerspaces challenge.&lt;br /&gt;
&lt;br /&gt;
Here&amp;#039;s the code! &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#define DROP_DISTANCE 25&lt;br /&gt;
&lt;br /&gt;
task main()&lt;br /&gt;
{&lt;br /&gt;
    SetSensorLight(IN_1);&lt;br /&gt;
    SetSensorLight(IN_2);&lt;br /&gt;
    SetSensorType(IN_1,IN_TYPE_LIGHT_INACTIVE);&lt;br /&gt;
    SetSensorType(IN_2,IN_TYPE_LIGHT_INACTIVE);&lt;br /&gt;
    SetSensorMode(IN_1,SENSOR_MODE_PERCENT);&lt;br /&gt;
    SetSensorMode(IN_2,SENSOR_MODE_PERCENT);&lt;br /&gt;
    &lt;br /&gt;
    SetSensorLowspeed(IN_3);&lt;br /&gt;
    SetSensorTouch(IN_4);&lt;br /&gt;
    &lt;br /&gt;
    int lightambient = 100;&lt;br /&gt;
    int lighttreshold = 75;&lt;br /&gt;
    for (int i = 0; i &amp;lt; 3; i++)&lt;br /&gt;
    {&lt;br /&gt;
        PlayTone(440, 100);&lt;br /&gt;
        Wait(1000);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    int bouncecounter = 0;&lt;br /&gt;
    int lightsource = 0;&lt;br /&gt;
    &lt;br /&gt;
    OnFwd(OUT_A, 40);&lt;br /&gt;
    OnRev(OUT_B, 40);&lt;br /&gt;
    for (int i = 0; i &amp;lt; 20; i++)&lt;br /&gt;
    {&lt;br /&gt;
        if (Sensor(IN_1) &amp;lt; lightambient) lightambient = Sensor(IN_1);&lt;br /&gt;
        if (Sensor(IN_2) &amp;lt; lightambient) lightambient = Sensor(IN_2);&lt;br /&gt;
        if (Sensor(IN_1) &amp;gt; lightsource) lightsource = Sensor(IN_1);&lt;br /&gt;
        if (Sensor(IN_2) &amp;gt; lightsource) lightsource = Sensor(IN_2);&lt;br /&gt;
        PlayTone(440, 20);&lt;br /&gt;
        Wait(100);&lt;br /&gt;
    }&lt;br /&gt;
    Off(OUT_AB);&lt;br /&gt;
    lighttreshold = 5 + (lightambient + lightsource) / 2;&lt;br /&gt;
    &lt;br /&gt;
    PlayTone(784, 125);&lt;br /&gt;
    Wait(150);&lt;br /&gt;
    PlayTone(660, 125);&lt;br /&gt;
    Wait(150);&lt;br /&gt;
    PlayTone(660, 275);&lt;br /&gt;
    Wait(300);&lt;br /&gt;
    PlayTone(588, 125);&lt;br /&gt;
    Wait(150);&lt;br /&gt;
    PlayTone(660, 125);&lt;br /&gt;
    Wait(150);&lt;br /&gt;
    PlayTone(784, 125);&lt;br /&gt;
   &lt;br /&gt;
    OnFwd(OUT_C, 50);&lt;br /&gt;
   &lt;br /&gt;
    while(1) &lt;br /&gt;
    {&lt;br /&gt;
        ClearScreen();&lt;br /&gt;
        NumOut(1, 20, SensorUS(IN_3));&lt;br /&gt;
        //NumOut(1, 30, Sensor(IN_4));        &lt;br /&gt;
        NumOut(1, 40, lighttreshold);&lt;br /&gt;
        NumOut(1, 50, lightambient);&lt;br /&gt;
&lt;br /&gt;
        if (Sensor(IN_4) || SensorUS(IN_3) &amp;gt; DROP_DISTANCE)&lt;br /&gt;
        {&lt;br /&gt;
            OnFwd(OUT_AB, 30);&lt;br /&gt;
            Wait(1000);&lt;br /&gt;
            bouncecounter++;&lt;br /&gt;
            if (bouncecounter == 10)&lt;br /&gt;
            {&lt;br /&gt;
                bouncecounter = 0;&lt;br /&gt;
                lightambient = 100;&lt;br /&gt;
                lightsource = 0;&lt;br /&gt;
                OnFwd(OUT_A, 40);&lt;br /&gt;
                OnRev(OUT_B, 40);&lt;br /&gt;
                for (int i = 0; i &amp;lt; 20; i++)&lt;br /&gt;
                {&lt;br /&gt;
                    if (Sensor(IN_1) &amp;lt; lightambient) lightambient = Sensor(IN_1);&lt;br /&gt;
                    if (Sensor(IN_2) &amp;lt; lightambient) lightambient = Sensor(IN_2);&lt;br /&gt;
                    if (Sensor(IN_1) &amp;gt; lightsource) lightsource = Sensor(IN_1);&lt;br /&gt;
                    if (Sensor(IN_2) &amp;gt; lightsource) lightsource = Sensor(IN_2);&lt;br /&gt;
                    PlayTone(440, 20);&lt;br /&gt;
                    Wait(100);&lt;br /&gt;
                }&lt;br /&gt;
                Off(OUT_AB);&lt;br /&gt;
                lighttreshold = 5 + (lightambient + lightsource) / 2;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
        &lt;br /&gt;
            int x1 = SENSOR_1;&lt;br /&gt;
            int x2 = SENSOR_2;&lt;br /&gt;
            NumOut(1, 1, x1);&lt;br /&gt;
            NumOut(1, 10, x2);&lt;br /&gt;
            if ((x1 &amp;lt; lighttreshold) &amp;amp;&amp;amp; (x2 &amp;lt; lighttreshold))&lt;br /&gt;
            {&lt;br /&gt;
                TextOut(1,20,&amp;quot;A&amp;quot;);&lt;br /&gt;
                OnRev(OUT_A, 75);&lt;br /&gt;
                OnFwd(OUT_B, 75);&lt;br /&gt;
            }&lt;br /&gt;
            else if (x1 &amp;lt; lighttreshold)&lt;br /&gt;
            {&lt;br /&gt;
                TextOut(1,20,&amp;quot;D&amp;quot;);&lt;br /&gt;
                int d1 = x2 - x1;&lt;br /&gt;
                OnRev(OUT_A, 50 - d1);&lt;br /&gt;
                OnRev(OUT_B, 60);&lt;br /&gt;
            }&lt;br /&gt;
            else if (x2 &amp;lt; lighttreshold)&lt;br /&gt;
            {&lt;br /&gt;
                TextOut(1,20,&amp;quot;C&amp;quot;);&lt;br /&gt;
                int d1 = x1 - x2;&lt;br /&gt;
                OnRev(OUT_B, 50 - d1);&lt;br /&gt;
                OnRev(OUT_A, 60);&lt;br /&gt;
            }&lt;br /&gt;
            else&lt;br /&gt;
            {&lt;br /&gt;
                TextOut(1,20,&amp;quot;B&amp;quot;);&lt;br /&gt;
                OnRev(OUT_AB, 75);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;/div&gt;</summary>
		<author><name>imported&gt;Zkyp</name></author>
	</entry>
</feed>