<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="https://script.spoken-tutorial.org/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=ElectroBlocks%2FC2%2FUltrasonic-Sensor%2FEnglish</id>
		<title>ElectroBlocks/C2/Ultrasonic-Sensor/English - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=ElectroBlocks%2FC2%2FUltrasonic-Sensor%2FEnglish"/>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;action=history"/>
		<updated>2026-05-13T00:02:37Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.23.17</generator>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;diff=57200&amp;oldid=prev</id>
		<title>Madhurig at 10:38, 21 October 2025</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;diff=57200&amp;oldid=prev"/>
				<updated>2025-10-21T10:38:29Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 10:38, 21 October 2025&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 259:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 259:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;# Check the output of experiment using simulator&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;# Check the output of experiment using simulator&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; 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;|| This brings us to the end of this tutorial. Let us summarise.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; 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;|| This brings us to the end of this tutorial. &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; 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;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; 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;Let us summarise.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; 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='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| '''Slide 7 '''&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| '''Slide 7 '''&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 265:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 267:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;'''Assignment''':&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;'''Assignment''':&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Turn '''ON the Buzzer '''when the ultrasonic sensor detects a distance equals to 10 cm.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Turn '''ON the Buzzer '''when the ultrasonic sensor detects a distance equals to 10 cm.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; 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;* Turn '''OFF the Buzzer '''if it is not 10 &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;cms&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; 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;* Turn '''OFF the Buzzer '''if it is not 10 &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;cm&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| As an assignment, please do the following.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| As an assignment, please do the following.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Madhurig</name></author>	</entry>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;diff=57199&amp;oldid=prev</id>
		<title>Madhurig at 10:34, 21 October 2025</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;diff=57199&amp;oldid=prev"/>
				<updated>2025-10-21T10:34:08Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;amp;diff=57199&amp;amp;oldid=57163&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>Madhurig</name></author>	</entry>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;diff=57163&amp;oldid=prev</id>
		<title>Nirmala Venkat: Created page with &quot;{| border=&quot;1&quot; |- || '''Visual Cue''' || '''Narration''' |- || &lt;div style=&quot;color:#000000;&quot;&gt;Show Slide: &lt;/div&gt;  &lt;div style=&quot;color:#000000;&quot;&gt;'''Title Slide'''&lt;/div&gt; || Welcome to...&quot;</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=ElectroBlocks/C2/Ultrasonic-Sensor/English&amp;diff=57163&amp;oldid=prev"/>
				<updated>2025-10-10T07:58:39Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;{| border=&amp;quot;1&amp;quot; |- || &amp;#039;&amp;#039;&amp;#039;Visual Cue&amp;#039;&amp;#039;&amp;#039; || &amp;#039;&amp;#039;&amp;#039;Narration&amp;#039;&amp;#039;&amp;#039; |- || &amp;lt;div style=&amp;quot;color:#000000;&amp;quot;&amp;gt;Show Slide: &amp;lt;/div&amp;gt;  &amp;lt;div style=&amp;quot;color:#000000;&amp;quot;&amp;gt;&amp;#039;&amp;#039;&amp;#039;Title Slide&amp;#039;&amp;#039;&amp;#039;&amp;lt;/div&amp;gt; || Welcome to...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|| '''Visual Cue'''&lt;br /&gt;
|| '''Narration'''&lt;br /&gt;
|-&lt;br /&gt;
|| &amp;lt;div style=&amp;quot;color:#000000;&amp;quot;&amp;gt;Show Slide: &amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;color:#000000;&amp;quot;&amp;gt;'''Title Slide'''&amp;lt;/div&amp;gt;&lt;br /&gt;
|| Welcome to the '''Spoken Tutorial''' on '''Ultrasonic Sensor''' using '''Electroblocks'''.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| '''Slide 2'''&lt;br /&gt;
&lt;br /&gt;
'''Learning Objectives'''&lt;br /&gt;
|| In this tutorial, we will learn to,&lt;br /&gt;
# &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Build a set of blocks for '''Ultrasonic sensor''' to detect an object in its range&amp;lt;/div&amp;gt;&lt;br /&gt;
# &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Check the output of the experiment using the simulator&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| '''Slide 3'''&lt;br /&gt;
&lt;br /&gt;
'''System Requirements'''&lt;br /&gt;
&lt;br /&gt;
|| To record this tutorial, I am using&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt; the following setup: &amp;lt;/span&amp;gt;&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Slide 4:&lt;br /&gt;
&lt;br /&gt;
Prerequisite&lt;br /&gt;
&lt;br /&gt;
|| To follow this tutorial,learner should have a basic knowledge of&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Electroblocks &amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Type &lt;br /&gt;
&lt;br /&gt;
https://electroblocks.org/&lt;br /&gt;
|| Let us open the '''ElectroBlocks''' website in the chrome browser.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Only narration&lt;br /&gt;
|| Let us open a new blank project.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| '''Slide:5'''&lt;br /&gt;
&lt;br /&gt;
Required section&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Logic&amp;lt;/div&amp;gt;&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Motion&amp;lt;/div&amp;gt;&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;LED&amp;lt;/div&amp;gt;&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Time&amp;lt;/div&amp;gt;&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Math&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|| We will need the following secti&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;ons f&amp;lt;/span&amp;gt;or this experiment.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| &lt;br /&gt;
|| Switch back to the '''Electroblocks''' interface.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Show '''Circuit Diagram.png'''&lt;br /&gt;
&lt;br /&gt;
|| This is the circuit diagram of an ultrasonic''' sensor''' experiment. &lt;br /&gt;
&lt;br /&gt;
Here, when an object comes in the defined range of the sensor the buzzer is turned ON.&lt;br /&gt;
&lt;br /&gt;
Otherwise the buzzer is turned OFF.&lt;br /&gt;
&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| &lt;br /&gt;
|| Let us build this circuit using '''ElectroBlocks'''.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| '''Keep the loop block in the middle area '''&lt;br /&gt;
&lt;br /&gt;
Click on the Logic section&lt;br /&gt;
&lt;br /&gt;
Point to if-then-else block&lt;br /&gt;
|| Click on the '''Logic''' section.&lt;br /&gt;
&lt;br /&gt;
Drag the '''if then else''' block and place inside the '''loop''' block.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Narration&lt;br /&gt;
&lt;br /&gt;
Click on the '''Sensors''' section&lt;br /&gt;
|| Now we will add an '''Ultrasonic sensor block.'''&lt;br /&gt;
&lt;br /&gt;
Click on the '''Sensors''' section and Click on the '''Motion'''.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Select the '''Setup Ultrasonic Sensor '''block and drag it in the working area.&lt;br /&gt;
&lt;br /&gt;
Point to the '''Setup Ultrasonic Sensor '''block.&lt;br /&gt;
|| Select the '''Setup Ultrasonic Sensor '''block and drag it to the working area.&lt;br /&gt;
&lt;br /&gt;
The '''Setup Ultrasonic Sensor '''block is used to configure the '''Ultrasonic sensor '''in the circuit. &lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Point toward trigger pin and echo pin.&lt;br /&gt;
&lt;br /&gt;
Point toward trigger pin&lt;br /&gt;
&lt;br /&gt;
Point towards echo pin &lt;br /&gt;
&lt;br /&gt;
|| I&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;n the &amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;'''setup'''&amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt; &amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;'''block, '''&amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;the &amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;'''trigger'''&amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt; pin and &amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;'''echo'''&amp;lt;/span&amp;gt;&amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt; pin are used for distance measurement.&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;color:#000000;&amp;quot;&amp;gt;'''Trigger''' pin emits ultrasonic sound waves.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;color:#000000;&amp;quot;&amp;gt;'''Echo''' pin receives the ultrasonic waves reflected from any object in its range.&amp;lt;/div&amp;gt;&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Point to '''trigger''' pin and '''echo''' pin&lt;br /&gt;
&lt;br /&gt;
|| Here, the '''trigger''' pin and '''echo''' pin are connected to '''pin 11 and 10 '''of the Arduino.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Only narration&lt;br /&gt;
&lt;br /&gt;
Point towards the number box&lt;br /&gt;
Click on the number box and change it to 5.&lt;br /&gt;
&lt;br /&gt;
Point to simulation window&lt;br /&gt;
&lt;br /&gt;
Point to the red rectangular box in front of the sensor.&lt;br /&gt;
|| We can change the distance by clicking on the '''Distance in Centimetre''' box.&lt;br /&gt;
&lt;br /&gt;
Click on the box and change the value to '''5.'''&lt;br /&gt;
&lt;br /&gt;
Check the '''Copy All''' checkbox.&lt;br /&gt;
&lt;br /&gt;
This setting will set the distance of the object to 5 centimeters for all the 3 loops.&lt;br /&gt;
&lt;br /&gt;
In the simulation window, the '''5''' cm distance is displayed on the ultrasonic sensor.&lt;br /&gt;
&lt;br /&gt;
Here the object is shown as a red rectangular box in front of the sensor.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Only narration&lt;br /&gt;
&lt;br /&gt;
Click on the '''logic''' option&lt;br /&gt;
&lt;br /&gt;
Select the''' (=) block''' and drag in the working area.&lt;br /&gt;
&lt;br /&gt;
Place the block in the '''if '''section of''' if then else block.'''&lt;br /&gt;
|| We need a '''comparison''' block.&lt;br /&gt;
&lt;br /&gt;
Click on the '''logic''' section.&lt;br /&gt;
&lt;br /&gt;
The third block represents the comparison block.&lt;br /&gt;
&lt;br /&gt;
Drag the''' comparison''' '''block''' and place it in the''' if '''section''' '''of the '''if then else block.'''&lt;br /&gt;
&lt;br /&gt;
This will compare the distance value of the object from the sensor.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Only narration&lt;br /&gt;
&lt;br /&gt;
Click on the '''Motion''',select distance (cm) block.&lt;br /&gt;
&lt;br /&gt;
Place this block in the '''first section '''of the '''logic''' block.&lt;br /&gt;
&lt;br /&gt;
Point to dropdown option&lt;br /&gt;
&lt;br /&gt;
Click on the dropdown option and select '''less than''' '''equal to''' option from the list.&lt;br /&gt;
|| Let us add a '''distance '''block'''.'''&lt;br /&gt;
&lt;br /&gt;
Click on the '''Motion'''.&lt;br /&gt;
&lt;br /&gt;
Drag the '''distance(cm)''' block and place this block in the '''first section '''of the '''comparison''' block.&lt;br /&gt;
&lt;br /&gt;
Click on the dropdown option and select '''less than equal to '''option from the list.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| click on the '''math''' option available on the left side on the screen.&lt;br /&gt;
&lt;br /&gt;
|| Next,&amp;lt;span style=&amp;quot;color:#ff0000;&amp;quot;&amp;gt; &amp;lt;/span&amp;gt;click on the '''Math''' section.&lt;br /&gt;
&lt;br /&gt;
We will add the distance value.&lt;br /&gt;
&lt;br /&gt;
Drag and place the first '''number''' '''block''' next to the '''less than equal to '''option.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Click on the '''number''' block and change to 10.&lt;br /&gt;
|| Click on the '''number''' block and change to 10.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| &lt;br /&gt;
&lt;br /&gt;
Click on the''' LED '''option.&lt;br /&gt;
&lt;br /&gt;
Select the '''Turn a LED '''block.&lt;br /&gt;
&lt;br /&gt;
Place the block in the ‘'''then’''' section of the '''if then else '''block.&lt;br /&gt;
|| Next let us add a '''Buzzer '''to the circuit.&lt;br /&gt;
&lt;br /&gt;
Click on the '''Add-ons''' and click on the '''Passive Buzzer'''.&lt;br /&gt;
&lt;br /&gt;
Drag and drop the '''Turn Passive buzzer''' block to the '''then''' section of the '''if then else''' block.&lt;br /&gt;
&lt;br /&gt;
By default the '''Buzzer '''is '''ON '''and connected to pin 9 of the '''arduino.'''&lt;br /&gt;
&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Right Click on the''' Turn a LED '''block and select the duplicate option.&lt;br /&gt;
&lt;br /&gt;
Place this new block in the '''else''' section of the '''If then else''' block.&lt;br /&gt;
&lt;br /&gt;
Click on the dropdown option in the''' Turn Passive LED '''block''' '''and select the &amp;quot;'''Off'''&amp;quot; state.&lt;br /&gt;
|| Right click on the''' Turn Passive buzzer '''block and select the duplicate option.&lt;br /&gt;
&lt;br /&gt;
Place this new block in the '''else''' section of the '''If then else''' block.&lt;br /&gt;
&lt;br /&gt;
Change the state of the Buzzer to '''OFF''' from the dropdown option.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Click on the '''Code''' icon to view the auto-generated Arduino code for the experiment.&lt;br /&gt;
&lt;br /&gt;
Highlight the code on right side&lt;br /&gt;
|| Click on the '''Code icon''' to view the automatically generated''' Arduino code'''.&lt;br /&gt;
&lt;br /&gt;
The code includes self-explanatory''' comments''' for better understanding.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Click the '''Home''' icon and press the '''Play button''' to start the simulation.&lt;br /&gt;
&lt;br /&gt;
Zoom and show the simulation area&lt;br /&gt;
&lt;br /&gt;
Highlight hand symbol and '''pressed''' word&lt;br /&gt;
&lt;br /&gt;
|| Click on the '''Home''' icon and press the '''Play button''' to start the simulation.&lt;br /&gt;
&lt;br /&gt;
We can see the '''Buzzer''' is turned ON.&lt;br /&gt;
&lt;br /&gt;
In the block we have specified the distance as 5cms and the range is less than 10 which is true.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Only narration&lt;br /&gt;
&lt;br /&gt;
Point towards '''Setup Ultrasonic sensor '''block.&lt;br /&gt;
&lt;br /&gt;
Point towards '''Distance in the Centimeter''' box.&lt;br /&gt;
&lt;br /&gt;
Click on the box and change the value to '''20'''&lt;br /&gt;
&lt;br /&gt;
Point towards the simulation window.&lt;br /&gt;
&lt;br /&gt;
Point to square box.drag this square box to the start point of the simulation.&lt;br /&gt;
|| Let us change the distance value and check the simulation output.&lt;br /&gt;
&lt;br /&gt;
In the '''Setup Ultrasonic sensor''' block, change the distance to 20 Centimeters.&lt;br /&gt;
&lt;br /&gt;
In the simulation window, note that the object has &amp;lt;span style=&amp;quot;color:#000000;&amp;quot;&amp;gt;moved&amp;lt;/span&amp;gt; to 20cms.&lt;br /&gt;
&lt;br /&gt;
Let us simulate and see the output again.&lt;br /&gt;
&lt;br /&gt;
Drag the box above the play button to the start position.&lt;br /&gt;
&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Click on the play button&lt;br /&gt;
&lt;br /&gt;
Point to OFF state&lt;br /&gt;
&lt;br /&gt;
|| Click on the '''Play''' button to see the output.&lt;br /&gt;
&lt;br /&gt;
Notice that the '''Buzzer '''remains in OFF state as the distance is above 10cms.&lt;br /&gt;
&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| Narration only&lt;br /&gt;
|| The '''XML '''file of this experiment is provided in the code files for your reference.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| '''Slide 6:'''&lt;br /&gt;
&lt;br /&gt;
'''Summary'''&lt;br /&gt;
&lt;br /&gt;
In this tutorial, we learnt about,&lt;br /&gt;
# &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Build a set of blocks for Ultrasonic sensor to detect an object in its range&amp;lt;/div&amp;gt;&lt;br /&gt;
# &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Check the output of experiment using simulator&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|| This brings us to the end of this tutorial. Let us summarise.&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| '''Slide 7 :'''&lt;br /&gt;
&lt;br /&gt;
'''Assignment''':&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Turn '''ON the Buzzer '''when the ultrasonic sensor detects a distance equals to 10 cm.&amp;lt;/div&amp;gt;&lt;br /&gt;
* &amp;lt;div style=&amp;quot;margin-left:1.27cm;margin-right:0cm;&amp;quot;&amp;gt;Turn '''OFF the Buzzer '''if it is not 10 cms.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|| As an assignment, please do the following&lt;br /&gt;
|- style=&amp;quot;border:1pt solid #000000;padding:0.176cm;&amp;quot;&lt;br /&gt;
|| '''Slide 8: Thank You'''&lt;br /&gt;
|| Thank you for joining.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Nirmala Venkat</name></author>	</entry>

	</feed>