tag:blogger.com,1999:blog-385873825017773302024-02-19T08:02:21.531+05:30Electronics Based Projects 4 UAnonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.comBlogger24125tag:blogger.com,1999:blog-38587382501777330.post-57539566950642204892013-01-29T21:17:00.000+05:302013-01-29T21:18:37.247+05:30ASK Transmitter and Receiver Module<div dir="ltr" style="text-align: left;" trbidi="on">
<div dir="ltr" style="text-align: left;" trbidi="on">
Since ASK (Amplitude Shift Keying) Technology is a kind of Wireless Communication from Transmitter to Receiver end, as you all know this type of Technology is suitable for One way Transmission i.e, Half Duplex Communication.<br />
Here we use ASK Rx and Tx Modules of 434 MHz which is suitable for 20 meters of distance. As you all know for long range wireless transmission we require Carrier Signal for effective transmission of Information Bits.<br />
<br />
Thus the function of these ASK Modules is to provide Carrier Signal to our Data Signal which is 30KHz, thus the distortions are undertook under 434MHz and Data (30KHz) Signal remains safe or Un-Disturbed.<br />
Here in this technology we use Decoder and Encoder, which is used to decode and encode the data signals, as 4 Bit Data is Converted into 1 Bit Data and Vice Versa.<br />
<br />
In Electronics Market both 4 Bit and 8 Bit Encoder and Decoder are Available, Namely<br />
HT12D (4 Bit Decoder IC) (HT- HolTek, 12- 8 Bit Address 4 Bit Data, D- Decoder)<br />
HT12E (4 Bit Encoder IC) (HT- HolTek, 12- 8 Bit Address 4 Bit Data, E- Encoder)<br />
HT640 (8 Bit Encoder IC)<br />
HT648 (8 Bit Decoder IC)<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj4m3c5NU_RFmy723YSjrJBKT8KH9dfY_BZToItEIp4j_SZ7Du4FQ5yEAVY91DtXNwvW84TBQz35CDghmVFzpKd5HuP4d3B5QQhL_T37i0s49p3PeuhftSqGqpvl9UlESClhRbzmOEBehc/s1600/ASK+Rx+with+Multi+Add+with+8051+Microcontroller.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="228" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj4m3c5NU_RFmy723YSjrJBKT8KH9dfY_BZToItEIp4j_SZ7Du4FQ5yEAVY91DtXNwvW84TBQz35CDghmVFzpKd5HuP4d3B5QQhL_T37i0s49p3PeuhftSqGqpvl9UlESClhRbzmOEBehc/s320/ASK+Rx+with+Multi+Add+with+8051+Microcontroller.png" width="320" /></a></div>
<br />
ASK Receiver using HT12D with use of Microcontroller<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPc9YRxUvmKdcYhWToafmqxdnQLLKVyYIhj_4hStB9FqOt8180_fY6Tepq6i6FkhJdyN4FcuUSfEg1Q8n5mmnP76v0S-NCYdt1MgT2xYitxHkDtRhbPD_WvjXXraFMMdQ_ts8Jp8sxcYU/s1600/ASK+Tx+with+Multi+Add+with+8051+Microcontroller.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="119" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPc9YRxUvmKdcYhWToafmqxdnQLLKVyYIhj_4hStB9FqOt8180_fY6Tepq6i6FkhJdyN4FcuUSfEg1Q8n5mmnP76v0S-NCYdt1MgT2xYitxHkDtRhbPD_WvjXXraFMMdQ_ts8Jp8sxcYU/s320/ASK+Tx+with+Multi+Add+with+8051+Microcontroller.png" width="320" /></a></div>
<br />
ASK 4 Bit Transmitter using HT12E<br />
<br />
<u>Applications</u>: -<br />
<br />
1) Home Automation<br />
2) Wireless Robot<br />
3) Industrial Purpose</div>
<script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script></div>
Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com0Lucknow, Uttar Pradesh, India26.8465108 80.94668320000005226.3931148 80.301236200000048 27.299906800000002 81.592130200000057tag:blogger.com,1999:blog-38587382501777330.post-52695850403126769912012-08-08T22:31:00.004+05:302012-08-08T22:43:31.472+05:30Smart 8051 Board<a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/-lDMQaZDv5vY/UCKeJoItanI/AAAAAAAAAE0/tHyeYfhH_pc/s1600/Untitled.jpg"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 263px;" src="http://4.bp.blogspot.com/-lDMQaZDv5vY/UCKeJoItanI/AAAAAAAAAE0/tHyeYfhH_pc/s400/Untitled.jpg" alt="" id="BLOGGER_PHOTO_ID_5774351560472357490" border="0" /></a><br /><span style="font-family:arial;">In this Board, Microcontroller interfaced with MT8870 DTMF IC, decoder ic, L293D, ULN2803, & segment, LED, LCD, and many more.</span><br /><br /><span style="font-family:arial;">In this board every interfacing is done through male buck strip via jumper wires of 8 pins.....</span><br /><br /><span style="font-family:arial;">so it is a complete board which provides u each and every interfacings which u need,...</span><br /><br /><span style="font-family:arial;">like if u like this board......</span><br /><br /><span style="font-family:arial;">Its cost is just INR 895</span><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com1tag:blogger.com,1999:blog-38587382501777330.post-6147974774611035952012-06-05T10:10:00.005+05:302012-06-05T10:20:33.201+05:30AVR Programmer<a href="http://2.bp.blogspot.com/-39rWUa2oMpQ/T82N6GD68bI/AAAAAAAAAEQ/6xfw0YbFsb0/s1600/AVR%2BProgrammer.jpg"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 297px;" src="http://2.bp.blogspot.com/-39rWUa2oMpQ/T82N6GD68bI/AAAAAAAAAEQ/6xfw0YbFsb0/s400/AVR%2BProgrammer.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5750408328420979122" /></a><div style="text-align: left;"><span><u>this is the circuit diagram or PCB Latyout of AVR Programmer uses DB9 Connector</u></span></div><div style="text-align: left;"><span><u>i am going to upload 1 more image later which is used to show Component places....<br /></u></span><br /></div><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-60783630257077496382012-05-25T11:40:00.000+05:302013-01-29T22:07:59.705+05:30Program for LED Blinking in Fashion<div dir="ltr" style="text-align: left;" trbidi="on">
<div>
#include<8051.h></div>
<div>
#include<stdio.h><stdio .h=""></stdio></div>
<div>
void delay (int time)</div>
<div>
{</div>
<div>
unsigned int i,j;</div>
<div>
for (i=0;i<=time*10;i++)</div>
<div>
{</div>
<div>
for (j=0;j<=time*10;j++)</div>
<div>
{</div>
<div>
}}}</div>
<div>
void main()</div>
<div>
{</div>
<div>
P1=0xff;</div>
<div>
while(1)</div>
<div>
{</div>
<div>
P1=0x00;</div>
<div>
delay(10);</div>
<div>
P1_0=1;</div>
<div>
delay(10);</div>
<div>
P1_1=1;</div>
<div>
delay(10);</div>
<div>
P1_2=1;</div>
<div>
delay(10);</div>
<div>
P1_3=1;</div>
<div>
delay(10);</div>
<div>
P1_4=1;</div>
<div>
delay(10);</div>
<div>
P1_5=1;</div>
<div>
delay(10);</div>
<div>
P1_6=1;</div>
<div>
delay(10);</div>
<div>
P1_7=1;</div>
<div>
delay(10);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(10);</div>
<div>
P1_7=1;</div>
<div>
delay(10);</div>
<div>
P1_6=1;</div>
<div>
delay(10);</div>
<div>
P1_5=1;</div>
<div>
delay(10);</div>
<div>
P1_4=1;</div>
<div>
delay(10);</div>
<div>
P1_3=1;</div>
<div>
delay(10);</div>
<div>
P1_2=1;</div>
<div>
delay(10);</div>
<div>
P1_1=1;</div>
<div>
delay(10);</div>
<div>
P1_0=1;</div>
<div>
delay(10);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(10);</div>
<div>
P1=0x81;</div>
<div>
delay(10);</div>
<div>
P1=0xc3;</div>
<div>
delay(10);</div>
<div>
P1=0xe7;</div>
<div>
delay(10);</div>
<div>
P1=0xff;</div>
<div>
delay(10);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(10);</div>
<div>
P1=0x18;</div>
<div>
delay(10);</div>
<div>
P1=0x3c;</div>
<div>
delay(10);</div>
<div>
P1=0x7e;</div>
<div>
delay(10);</div>
<div>
P1=0xff;</div>
<div>
delay(10);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1_0=1;</div>
<div>
delay(15);</div>
<div>
P1_1=1;</div>
<div>
delay(15);</div>
<div>
P1_2=1;</div>
<div>
delay(15);</div>
<div>
P1_3=1;</div>
<div>
delay(15);</div>
<div>
P1_4=1;</div>
<div>
delay(15);</div>
<div>
P1_5=1;</div>
<div>
delay(15);</div>
<div>
P1_6=1;</div>
<div>
delay(15);</div>
<div>
P1_7=1;</div>
<div>
delay(15);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1_7=1;</div>
<div>
delay(15);</div>
<div>
P1_6=1;</div>
<div>
delay(15);</div>
<div>
P1_5=1;</div>
<div>
delay(15);</div>
<div>
P1_4=1;</div>
<div>
delay(15);</div>
<div>
P1_3=1;</div>
<div>
delay(15);</div>
<div>
P1_2=1;</div>
<div>
delay(15);</div>
<div>
P1_1=1;</div>
<div>
delay(15);</div>
<div>
P1_0=1;</div>
<div>
delay(15);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1=0x81;</div>
<div>
delay(15);</div>
<div>
P1=0xc3;</div>
<div>
delay(15);</div>
<div>
P1=0xe7;</div>
<div>
delay(15);</div>
<div>
P1=0xff;</div>
<div>
delay(15);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1=0x18;</div>
<div>
delay(15);</div>
<div>
P1=0x3c;</div>
<div>
delay(15);</div>
<div>
P1=0x7e;</div>
<div>
delay(15);</div>
<div>
P1=0xff;</div>
<div>
delay(15);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1=0x80;</div>
<div>
delay(15);</div>
<div>
P1=0x40;</div>
<div>
delay(15);</div>
<div>
P1=0x20;</div>
<div>
delay(15);</div>
<div>
P1=0x10;</div>
<div>
delay(15);</div>
<div>
P1=0x08;</div>
<div>
delay(15);</div>
<div>
P1=0x04;</div>
<div>
delay(15);</div>
<div>
P1=0x02;</div>
<div>
delay(15);</div>
<div>
P1=0x01;</div>
<div>
delay(15);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1=0x01;</div>
<div>
delay(15);</div>
<div>
P1=0x02;</div>
<div>
delay(15);</div>
<div>
P1=0x04;</div>
<div>
delay(15);</div>
<div>
P1=0x08;</div>
<div>
delay(15);</div>
<div>
p1=0x10;</div>
<div>
delay(15);</div>
<div>
P1=0x20;</div>
<div>
delay(15);</div>
<div>
P1=0x40;</div>
<div>
delay(15);</div>
<div>
P1=0x80;</div>
<div>
delay(15);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1=0x81;</div>
<div>
delay(15);</div>
<div>
P1=0x42;</div>
<div>
delay(15);</div>
<div>
P1=0x24;</div>
<div>
delay(15);</div>
<div>
P1=0x18;</div>
<div>
delay(15);</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
P1=0x00;</div>
<div>
delay(15);</div>
<div>
P1=0x18;</div>
<div>
delay(15);</div>
<div>
P1=0x24;</div>
<div>
delay(15);</div>
<div>
P1=0x42;</div>
<div>
delay(15);</div>
<div>
P1=0x81;</div>
<div>
delay(15);</div>
<div>
}</div>
<div>
}</div>
<br />
<script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script></div>
Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-87492738947816215242012-05-25T11:38:00.001+05:302013-01-29T22:06:48.595+05:30Program for LCD interface with 8051<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">#include<REGX51.H></span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">#include<stdio.h></span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">sfr ldata=0x90;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">sbit rs=P2^0;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">sbit rw=P2^1;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">sbit en=P2^2;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">void delay(int a);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">void lcdcmd(unsigned char value);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">void lcddata(unsigned char value);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">void lcdcmd(unsigned char value)</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">{</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">ldata=value;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">rs=0;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">rw=0;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">en=1;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(2);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">en=0;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">return;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">}</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">void lcddata(unsigned char value)</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">{</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">ldata=value;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">rs=1;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">rw=0;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">en=1;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(2);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">en=0;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">return;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">}</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">void delay(int a)</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">{</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">unsigned int i,j;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">for(i=0;i<=100;i++)</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">{</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">for(j=0;j<=10*a;j++)</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">{</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">}}}</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">void main()</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">{</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">P1=0x00;</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcdcmd(0x38);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(2);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcdcmd(0x0E);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(2);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcdcmd(0x01);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(2);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcdcmd(0x06);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(2);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">while(1)</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">{</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcdcmd(0x82);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘T’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘E’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘C’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘H’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘F’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘O’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘R’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘M’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘E’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘R’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘S’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcdcmd(0xC2);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘T’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘E’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘C’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘H’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘N’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘O’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘L’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘O’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘G’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘I’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘E’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">lcddata(‘S’);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">delay(10);</span></div>
<div class="MsoNormal" style="margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-bidi-font-size: 11.0pt;">}}</span></div>
</div>
Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-29993919354757540712012-05-25T11:35:00.001+05:302012-05-25T11:38:33.268+05:30Program for Keypad interface with 8051 and Displayed on LCD<div><span >#include<8051.h></span></div><div><span >#include<stdio.h></stdio.h></span></div><div><span >#define EN P1_7</span></div><div><span >#define RW P1_6</span></div><div><span >#define RS P1_5</span></div><div><span >#define DL P3</span></div><div><span >#define c0 P2_0</span></div><div><span >#define c1 P2_1</span></div><div><span >#define c2 P2_2</span></div><div><span >#define c3 P2_3</span></div><div><span >#define r1 P2_4</span></div><div><span >#define r2 P2_5</span></div><div><span >#define r3 P2_6</span></div><div><span >#define r4 P2_7</span></div><div><span >
<br /></span></div><div><span >void delay(int time);</span></div><div><span >void lcd_init();</span></div><div><span >void cmd(char cmdbyte);</span></div><div><span >void dataa(char ch);</span></div><div><span >void clear();</span></div><div><span >void mov_cur(char pos);</span></div><div><span >void writeat(char ch,char pos);</span></div><div><span >void enterword();</span></div><div><span >
<br /></span></div><div><span >void delay(int time)</span></div><div><span >{</span></div><div><span >int i,j;</span></div><div><span >for(i=0;i<time*10;i++)< font=""></time*10;i++)<></span></div><div><span ><span >{</span></span></div><div><span ><span >for(j=0;j<time*10;j++)< font=""></time*10;j++)<></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >
<br /></span></span></span></div><div><span ><span ><span >void cmd(char cmdbyte)</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >EN=1;</span></span></span></div><div><span ><span ><span >RW=0;</span></span></span></div><div><span ><span ><span >RS=0;</span></span></span></div><div><span ><span ><span >DL=cmdbyte;</span></span></span></div><div><span ><span ><span >EN=0;</span></span></span></div><div><span ><span ><span >delay(10);</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >
<br /></span></span></span></div><div><span ><span ><span >void dataa(char ch)</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >EN=1;</span></span></span></div><div><span ><span ><span >RW=0;</span></span></span></div><div><span ><span ><span >RS=1;</span></span></span></div><div><span ><span ><span >DL=ch;</span></span></span></div><div><span ><span ><span >EN=0;</span></span></span></div><div><span ><span ><span >delay(10);</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >
<br /></span></span></span></div><div><span ><span ><span >void lcd_init()</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >cmd(0x38);</span></span></span></div><div><span ><span ><span >cmd(0x05);</span></span></span></div><div><span ><span ><span >cmd(0x0F);</span></span></span></div><div><span ><span ><span >cmd(0x06);</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >
<br /></span></span></span></div><div><span ><span ><span >void clear()</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >cmd(0x01);</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >
<br /></span></span></span></div><div><span ><span ><span >void mov_cur(char pos)</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >cmd(pos);</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >
<br /></span></span></span></div><div><span ><span ><span >void keypad()</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >if ((r1==0) && (r2==1) && (r3==1) && (r4==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >if ((c0==0) && (c1==1) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('a');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==0) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('b');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==0) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('c');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==1) && (c3==0))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('d');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((r1==1) && (r2==0) && (r3==1) && (r4==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >if ((c0==0) && (c1==1) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('e');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==0) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('f');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==0) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('g');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==1) && (c3==0))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('h');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((r1==1) && (r2==1) && (r3==0) && (r4==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >if ((c0==0) && (c1==1) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('i');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==0) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('j');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==0) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('k');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==1) && (c3==0))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('l');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((r1==1) && (r2==1) && (r3==1) && (r4==0))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >if ((c0==0) && (c1==1) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('m');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==0) && (c2==1) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('n');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==0) && (c3==1))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('o');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >if ((c0==1) && (c1==1) && (c2==1) && (c3==0))</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >dataa('p');</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >}</span></span></span></div><div><span ><span ><span >
<br /></span></span></span></div><div><span ><span ><span >void main()</span></span></span></div><div><span ><span ><span >{</span></span></span></div><div><span ><span ><span >P1=0xFF;</span></span></span></div><div><span ><span ><span >P2=0xFF;</span></span></span></div><div><span ><span ><span >P3=0xFF;</span></span></span></div><div><span ><span ><span >lcd_init();</span></span></span></div><div><span ><span ><span >clear();</span></span></span></div><div><span ><span ><span >RW=0;</span></span></span></div><div><span ><span ><span >keypad();</span></span></span></div><div><span ><span ><span >delay(10);</span></span></span></div><div><span ><span ><span >}</span></span></span></div>
<br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-7211562495043299502012-05-25T11:33:00.001+05:302013-01-29T22:08:40.069+05:30Program for ADC interface with 8051<div dir="ltr" style="text-align: left;" trbidi="on">
<div>
#include<8051.h></div>
<div>
#include<stdio .h=""></stdio></div>
<div>
void delay (int time)</div>
<div>
{</div>
<div>
unsigned int i,j;</div>
<div>
for (i=0;i<=time*10;i++)</div>
<div>
{</div>
<div>
for (j=0;j<=time*10;j++)</div>
<div>
{</div>
<div>
}</div>
<div>
}</div>
<div>
}</div>
<div>
void adc( )</div>
<div>
{</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==0 && P1_1==0 && P1_0==0))</div>
<div>
{</div>
<div>
P0=0xc0;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==0 && P1_1==0 && P1_0==1))</div>
<div>
{</div>
<div>
P0=0xf9;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==0 && P1_1==1 && P1_0==0))</div>
<div>
{</div>
<div>
P0=0xa4;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==0 && P1_1==1 && P1_0==1))</div>
<div>
{</div>
<div>
P0=0xb0;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==1 && P1_1==0 && P1_0==0))</div>
<div>
{</div>
<div>
P0=0x99;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==1 && P1_1==0 && P1_0==1))</div>
<div>
{</div>
<div>
P0=0x92;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==1 && P1_1==1 && P1_0==0))</div>
<div>
{</div>
<div>
P0=0x82;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==0 && P1_2==1 && P1_1==1 && P1_0==1))</div>
<div>
{</div>
<div>
P0=0xf8;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==1 && P1_2==0 && P1_1==0 && P1_0==0))</div>
<div>
{</div>
<div>
P0=0x80;</div>
<div>
}</div>
<div>
if ((P1_7==0 && P1_6==0 && P1_5==0 && P1_4==0 && P1_3==1 && P1_2==0 && P1_1==0 && P1_0==1))</div>
<div>
{</div>
<div>
P0=0x90;</div>
<div>
}</div>
<div>
}</div>
<div>
void main( ) </div>
<div>
{</div>
<div>
P0=0xff;</div>
<div>
P1=0xff;</div>
<div>
delay(10);</div>
<div>
while(1)</div>
<div>
{</div>
<div>
adc( );</div>
<div>
delay(10);</div>
<div>
}</div>
<div>
}</div>
<br />
<script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script></div>
Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-60947356362000112062012-05-25T11:04:00.004+05:302012-05-25T11:31:09.618+05:30Audio and Video Capturing Robot using RF Communication<a href="http://2.bp.blogspot.com/-raxDQY7H04M/T78bkVmb-rI/AAAAAAAAAD8/5mWtgx5E3ec/s1600/block.jpg" style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 252px;" src="http://2.bp.blogspot.com/-raxDQY7H04M/T78bkVmb-rI/AAAAAAAAAD8/5mWtgx5E3ec/s320/block.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5746341960635644594" /></a><div><div style="text-align: center;"><span ><u><br /></u></span></div><div style="text-align: left;"><span ><u>In our project keypad is interfaced with RF Transmitter through RF Encoder, so if we press any of the key from forward, backward, right and left, then after pressing any it will generate a signal Which is of 4 bit corresponding to four keys, because firstly we are providing high logic which means 1 and in electronics it means we are providing 5 volt supply to each of the keys, and another pin of keypad is connected is connected to ground so by pressing any key we provide logic 0 means ground. Thus one bit of data has been changed and remaining 3 data remains unchanged, means if we press forward key then we are sending signal 0111 which is of four bit. Now this 4 bit data is converted to 1 bit by RF Encoder (HT12E) which is then transmitted to receiving end via RF Transmitter. Then particular 1 bit data is received at receiving end through RF Receiver, which is then provided to RF Decoder whose work is to decode the data which is being transmitted from transmitter end or through the keypad. Thus 1 bit data is received which is then converted to 4 bit Through RF decoder (HT12D) which is then given to Microcontroller where we programmed our microcontroller, here the 2 motors which are interfaced with microcontroller are moving in either direction through H-Bridge (L293D) which is known as motor driver because this IC is Used to drive 2 dc motors, and another function of this motor driver is to protect our microcontroller from back EMF generated through DC Motor because in this IC Buffer is used which works as feedback diode. Now the motor runs in forward, backward, right and left direction through motors, so by pressing any key the Robot moved in that particular direction. Now for extra features we installed or placed wireless camera over the robot, so the camera captures any audio and video is directly transferred to Television through Camera receiver and TV Tuner. Thus we can easily capture anything through our Project without going anywhere. This wireless robot with camera is very much effective in Warfield zone as we can capture audio and video as well as in night also by attaching Night Vision Camera. There are several Applications of this Robot.</u></span></div><div style="text-align: left;"><span ><u><br /></u></span></div><div style="text-align: left;"><span ><u>PCB of Basic AVR ckt: -</u></span></div><br /><a href="http://1.bp.blogspot.com/-2Id7RQB4Frs/T78bkO3vO1I/AAAAAAAAAD0/yWR4DIubIsY/s1600/Basic%2BAVR.jpg" style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 251px;" src="http://1.bp.blogspot.com/-2Id7RQB4Frs/T78bkO3vO1I/AAAAAAAAAD0/yWR4DIubIsY/s320/Basic%2BAVR.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5746341958829161298" /></a></div><div><div style="text-align: center;"><span ><u><br /></u></span></div>Schematic Diagram of Basic AVR: -</div><div><br /><a href="http://2.bp.blogspot.com/-R7FNSYPUoXU/T78bUSNngBI/AAAAAAAAADo/0FSA0S05ZeE/s1600/AVR%2BBasic.jpg" style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 233px;" src="http://2.bp.blogspot.com/-R7FNSYPUoXU/T78bUSNngBI/AAAAAAAAADo/0FSA0S05ZeE/s320/AVR%2BBasic.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5746341684848328722" /></a></div><div><div style="text-align: left;"><span ><u>Schematic Diagram of RF Transmitter: -</u></span></div><br /><a href="http://3.bp.blogspot.com/-Y-GzkrzvrAQ/T78bT6TCvAI/AAAAAAAAADg/0zZnEMN3VWc/s1600/RF%2BTx%2BSchematic.jpg" style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 166px;" src="http://3.bp.blogspot.com/-Y-GzkrzvrAQ/T78bT6TCvAI/AAAAAAAAADg/0zZnEMN3VWc/s320/RF%2BTx%2BSchematic.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5746341678428634114" /></a></div><div><div style="text-align: left;"><span ><u>PCB Layout of RF Transmitter: -</u></span></div><br /><a href="http://2.bp.blogspot.com/-CupcOVCn2_A/T78bToBiwqI/AAAAAAAAADQ/As-K7Zp-2js/s1600/RF%2BTx.jpg" style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 200px;" src="http://2.bp.blogspot.com/-CupcOVCn2_A/T78bToBiwqI/AAAAAAAAADQ/As-K7Zp-2js/s320/RF%2BTx.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5746341673523397282" /></a></div><div><div style="text-align: left;"><span ><u>Schematic Diagram of RF Receiver: -</u></span></div><br /><a href="http://3.bp.blogspot.com/-ZGvjifR4I2g/T78bTmmHGdI/AAAAAAAAADE/FBkOgbVRTLY/s1600/RF%2BRx%2BSchematic%2B.jpg" style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 180px;" src="http://3.bp.blogspot.com/-ZGvjifR4I2g/T78bTmmHGdI/AAAAAAAAADE/FBkOgbVRTLY/s320/RF%2BRx%2BSchematic%2B.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5746341673139902930" /></a></div><div><div style="text-align: left;"><span ><u>PCB Layout RF Receiver: -</u></span></div><br /><a href="http://3.bp.blogspot.com/-JFXho-k5VkI/T78bTXyUrhI/AAAAAAAAAC4/t8jH_Riofmk/s1600/RF%2BRx%2BPCB.jpg" style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 177px;" src="http://3.bp.blogspot.com/-JFXho-k5VkI/T78bTXyUrhI/AAAAAAAAAC4/t8jH_Riofmk/s320/RF%2BRx%2BPCB.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5746341669164592658" /></a><br /></div><div>Program with PPT of this Project can be downloaded through below given link</div><div><br /></div><div><a href="http://www.mediafire.com/download.php?hz7j705ddr0n3xg">Download</a></div><div><br /></div><div>To download Project report click the link given below</div><div><br /></div><div><a href="http://www.mediafire.com/download.php?a6ck3q5ppju8jn9">Download</a></div><div><br /></div><div>To download the video related to project click the link given below</div><div><br /></div><div><a href="http://www.mediafire.com/download.php?m68ualqmal5qguh">Download</a></div><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-26615048558686058112012-04-01T22:31:00.006+05:302013-01-29T21:35:59.187+05:30Interfacing Temperature Sensor – LM35 with AVR Microcontroller<div dir="ltr" style="text-align: left;" trbidi="on">
<div style="text-align: left;">
<span style="background-color: #f6f6f6; font-size: 13px; line-height: 20px; text-align: -webkit-auto;">By interfacing different types of sensors with our MCU we can sense the environment and take decisions, in this way we can create "smart" applications. There are wide variety of sensors available. In this tutorial we will learn about a popular sensor LM35 which is precision centigrade temperature sensor. It can be used to measure temperature with accuracy of 0.5 degree centigrade. We can interface it easily with AVR MCUs and can create thermometers, temperature controller, fire alarms etc.</span></div>
<div style="text-align: left;">
<span style="background-color: #f6f6f6; font-size: 13px; line-height: 20px; text-align: -webkit-auto;">
</span></div>
<h2 style="background-color: #f6f6f6; clear: both; font-size: 25px; font-style: normal; font-variant: normal; font-weight: normal; height: auto; line-height: 20px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; width: 510px;">
LM35</h2>
<div style="background-color: #f6f6f6; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; line-height: 20px; text-align: -webkit-auto;">
LM35 by National Semiconductor is a popular and low cost temperature sensor. It is also easily available. It has three pins as follows.</div>
<div style="background-color: #f6f6f6; font-family: Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; line-height: 20px; text-align: -webkit-auto;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhy0nCEgd1bdl4dYSNeO6l-u_lbi575WfXEN8NfJnhyyP-26QQuk7UoyLlmuRFKrlfmnFvnUkYwmX1g_SHA1VsoQQc43OydNMMoHJWW1PXaRD-6mxX7-pToy3qmFlA1iiT4HHiNONi0SK4/s1600/lm35.GIF" style="font-family: Georgia, serif; font-size: 16px; line-height: normal; text-align: left;"><img alt="" border="0" id="BLOGGER_PHOTO_ID_5726482077077904226" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhy0nCEgd1bdl4dYSNeO6l-u_lbi575WfXEN8NfJnhyyP-26QQuk7UoyLlmuRFKrlfmnFvnUkYwmX1g_SHA1VsoQQc43OydNMMoHJWW1PXaRD-6mxX7-pToy3qmFlA1iiT4HHiNONi0SK4/s400/lm35.GIF" style="cursor: pointer; display: block; height: 366px; margin-bottom: 10px; margin-left: auto; margin-right: auto; margin-top: 0px; text-align: center; width: 144px;" /></a></div>
<div style="background-color: #f6f6f6; font-family: Arial, Helvetica, sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; line-height: 20px; text-align: -webkit-auto;">
</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
The Vcc can be from 4V to 20V as specified by the datasheet. To use the sensor simply connect the Vcc to 5V ,GND to Gnd and the Out to one of the ADC (analog to digital converter channel). The output linearly varies with temperature. The output is</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
<b>10MilliVolts per degree centigrade.</b></div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
So if the output is 310 mV then temperature is 31 degree C. To make this project you should be familiar with the ADC of AVRs and also using seven segment displays. Please refer to following articles.</div>
<ul style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
<li>Using the ADC of AVRs.</li>
<li>Using Seven Segment Display.</li>
<li>Using Seven Segment Display in Multiplexed Mode.</li>
</ul>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
The resolution of AVRs ADC is 10bit and for reference voltage we are using 5V so the resolution in terms of voltage is</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
5/1024 = 5mV approx</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
So if ADCs result corresponds to 5mV i.e. if ADC reading is 10 it means</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
10 x 5mV = 50mV</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
You can get read the value of any ADC channel using the function</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
ReadADC(ch);</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
Where ch is channel number (0-5) in case of ATmega8. If you have connected the LM35's out put to ADC channel 0 then call</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
adc_value = ReadADC(0)</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
this will store the current ADC reading in variable adc_value. The data type of adc_value should be int as ADC value can range from 0-1023.</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
As we saw ADC results are in factor of 5mV and for 1 degree C the output of LM35 is 10mV, So 2 units of ADC = 1 degree.</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
So to get the temperature we divide the adc_value by to</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
temperature = adc_value/2;</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
Finally you can display this value in either the 7 segment displays by using the Print() function we developed in last tutorial or you can display it in LCD Module. To know how to display integer in 7 segment displays and LCD Modules see the articles.</div>
<ul style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
<li>Multiplexed Seven Segment Display.</li>
<li>Using LCD Modules with AVRs.</li>
</ul>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
In this tutorial I have used three 7 segment displays to show the temperature. I have used the xBoard MINI<a href="http://extremeelectronics.co.in/tools/xboard-mini/" style="color: #0066cc; text-decoration: none;"> - </a>ATmega8 board to make the project. The complete program is given below.</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
</div>
<h2 style="clear: both; height: auto; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left; width: 510px;">
</h2>
<h2 style="background-color: #f6f6f6; clear: both; font-family: Arial, Helvetica, sans-serif; font-size: 25px; font-style: normal; font-variant: normal; font-weight: normal; height: auto; line-height: 20px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; width: 510px;">
Program (AVR GCC)</h2>
<div style="font-style: normal; font-variant: normal; font-weight: normal;">
<br /></div>
<div>
<div>
<span style="font-weight: normal;">#include <avr h=""></avr></span></div>
<div>
<span style="font-weight: normal;">#include <avr h=""></avr></span></div>
<div>
<span style="font-weight: normal;">#include <util h=""></util></span></div>
<div>
<span style="font-weight: normal;">#define SEVEN_SEGMENT_PORT PORTD</span></div>
<div>
<span style="font-weight: normal;">#define SEVEN_SEGMENT_DDR DDRD</span></div>
<div>
<span style="font-weight: normal;">uint8_t digits[3]; //Holds the digits for 3 displays</span></div>
<div>
<span style="font-weight: normal;">void SevenSegment(uint8_t n,uint8_t dp)</span></div>
<div>
<span style="font-weight: normal;">{</span></div>
<div>
<span style="font-weight: normal;">/*</span></div>
<div>
<span style="font-weight: normal;">This function writes a digits given by n to the display</span></div>
<div>
<span style="font-weight: normal;">the decimal point is displayed if dp=1</span></div>
<div>
<span style="font-weight: normal;">Note:</span></div>
<div>
<span style="font-weight: normal;">n must be less than 9</span></div>
<div>
<span style="font-weight: normal;">*/</span></div>
<div>
<span style="font-weight: normal;"> if(n<10)</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> switch (n)</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> case 0:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b00000011;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 1:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b10011111;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 2:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b00100101;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 3:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b00001101;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 4:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b10011001;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 5:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b01001001;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 6:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b01000001;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 7:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b00011111;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 8:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b00000001;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> case 9:</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b00001001;</span></div>
<div>
<span style="font-weight: normal;"> break;</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;"> if(dp)</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> //if decimal point should be displayed</span></div>
<div>
<span style="font-weight: normal;">
</span></div>
<div>
<span style="font-weight: normal;"> //make 0th bit Low</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT&=0b11111110;</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;"> else</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> //This symbol on display tells that n was greater than 9</span></div>
<div>
<span style="font-weight: normal;"> //so display can't handle it</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0b11111101;</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;">}</span></div>
<div>
<span style="font-weight: normal;">void Wait()</span></div>
<div>
<span style="font-weight: normal;">{</span></div>
<div>
<span style="font-weight: normal;"> uint8_t i;</span></div>
<div>
<span style="font-weight: normal;"> for(i=0;i<10;i++)</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> _delay_loop_2(0);</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;">}</span></div>
<div>
<span style="font-weight: normal;">void Print(uint16_t num)</span></div>
<div>
<span style="font-weight: normal;">{</span></div>
<div>
<span style="font-weight: normal;"> uint8_t i=0;</span></div>
<div>
<span style="font-weight: normal;"> uint8_t j;</span></div>
<div>
<span style="font-weight: normal;"> if(num>999) return;</span></div>
<div>
<span style="font-weight: normal;"> while(num)</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> digits[i]=num%10;</span></div>
<div>
<span style="font-weight: normal;"> i++;</span></div>
<div>
<span style="font-weight: normal;"> num=num/10;</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;"> for(j=i;j<3;j++) digits[j]=0;</span></div>
<div>
<span style="font-weight: normal;">}</span></div>
<div>
<span style="font-weight: normal;">void InitADC()</span></div>
<div>
<span style="font-weight: normal;">{</span></div>
<div>
<span style="font-weight: normal;">ADMUX=(1<<refs0 aref="AVcc;</font" for=""></refs0></span></div>
<div>
<span style="font-weight: normal;">ADCSRA=(1<<aden adps0="" font=""></aden></span></div>
<div>
<span style="font-weight: normal;">}</span></div>
<div>
<span style="font-weight: normal;">uint16_t ReadADC(uint8_t ch)</span></div>
<div>
<span style="font-weight: normal;">{</span></div>
<div>
<span style="font-weight: normal;"> //Select ADC Channel ch must be 0-7</span></div>
<div>
<span style="font-weight: normal;"> ch=ch&0b00000111;</span></div>
<div>
<span style="font-weight: normal;"> ADMUX|=ch;</span></div>
<div>
<span style="font-weight: normal;"> //Start Single conversion</span></div>
<div>
<span style="font-weight: normal;"> ADCSRA|=(1<<adsc font=""></adsc></span></div>
<div>
<span style="font-weight: normal;"> //Wait for conversion to complete</span></div>
<div>
<span style="font-weight: normal;"> while(!(ADCSRA & (1<<adif font=""></adif></span></div>
<div>
<span style="font-weight: normal;"> //Clear ADIF by writing one to it</span></div>
<div>
<span style="font-weight: normal;"> ADCSRA|=(1<<adif font=""></adif></span></div>
<div>
<span style="font-weight: normal;"> return(ADC);</span></div>
<div>
<span style="font-weight: normal;">}</span></div>
<div>
<span style="font-weight: normal;">void main()</span></div>
<div>
<span style="font-weight: normal;">{</span></div>
<div>
<span style="font-weight: normal;"> uint16_t adc_value;</span></div>
<div>
<span style="font-weight: normal;"> uint8_t t;</span></div>
<div>
<span style="font-weight: normal;"> // Prescaler = FCPU/1024</span></div>
<div>
<span style="font-weight: normal;"> TCCR0|=(1<<cs02 font=""></cs02></span></div>
<div>
<span style="font-weight: normal;"> //Enable Overflow Interrupt Enable</span></div>
<div>
<span style="font-weight: normal;"> TIMSK|=(1<<toie0 font=""></toie0></span></div>
<div>
<span style="font-weight: normal;"> //Initialize Counter</span></div>
<div>
<span style="font-weight: normal;"> TCNT0=0;</span></div>
<div>
<span style="font-weight: normal;"> //Port C[2,1,0] as out put</span></div>
<div>
<span style="font-weight: normal;"> DDRB|=0b00000111;</span></div>
<div>
<span style="font-weight: normal;"> PORTB=0b00000110;</span></div>
<div>
<span style="font-weight: normal;"> //Port D</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_DDR=0XFF;</span></div>
<div>
<span style="font-weight: normal;"> //Turn off all segments</span></div>
<div>
<span style="font-weight: normal;"> SEVEN_SEGMENT_PORT=0XFF;</span></div>
<div>
<span style="font-weight: normal;"> //Enable Global Interrupts</span></div>
<div>
<span style="font-weight: normal;"> sei();</span></div>
<div>
<span style="font-weight: normal;"> //Enable ADC</span></div>
<div>
<span style="font-weight: normal;"> InitADC();</span></div>
<div>
<span style="font-weight: normal;"> //Infinite loop</span></div>
<div>
<span style="font-weight: normal;"> while(1)</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> //Read ADC</span></div>
<div>
<span style="font-weight: normal;"> adc_value=ReadADC(0);</span></div>
<div>
<span style="font-weight: normal;"> //Convert to degree Centrigrade</span></div>
<div>
<span style="font-weight: normal;"> t=adc_value/2;</span></div>
<div>
<span style="font-weight: normal;"> //Print to display</span></div>
<div>
<span style="font-weight: normal;"> Print(t);</span></div>
<div>
<span style="font-weight: normal;"> //Wait some time</span></div>
<div>
<span style="font-weight: normal;"> Wait();</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;">}</span></div>
<div>
<span style="font-weight: normal;">ISR(TIMER0_OVF_vect)</span></div>
<div>
<span style="font-weight: normal;">{</span></div>
<div>
<span style="font-weight: normal;"> static uint8_t i=0;</span></div>
<div>
<span style="font-weight: normal;"> if(i==2)</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> i=0;</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;"> else</span></div>
<div>
<span style="font-weight: normal;"> {</span></div>
<div>
<span style="font-weight: normal;"> i++;</span></div>
<div>
<span style="font-weight: normal;"> }</span></div>
<div>
<span style="font-weight: normal;"> PORTB=~(1<<i font=""></i></span></div>
<div>
<span style="font-weight: normal;"> SevenSegment(digits[i],0);</span></div>
<div>
<span style="font-weight: normal;">}</span></div>
</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
</div>
<div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;">
</div>
<br />
<script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script></div>
Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-70691726231202488102012-03-25T16:25:00.004+05:302012-03-25T16:43:11.040+05:30How to interface keypad with AVR microcontroller (ATmega16)<div style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9hM_Uhy9vi0-ukNiBALpiJVBzGFyjIVCmQ_78HTfmS3Cp95jtNwQEhDc_HLwVjiNDiDXOik_6RFuhcyk66RLPi4weFXPWnmQIY2u5MKpk6sXTEkYg-6QLxxPe2qiVMk96H9k1X1M1dOs/s1600/Interfacing-keypad-with-AVR-Microcontroller.jpg" style="text-align: left; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 300px;" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9hM_Uhy9vi0-ukNiBALpiJVBzGFyjIVCmQ_78HTfmS3Cp95jtNwQEhDc_HLwVjiNDiDXOik_6RFuhcyk66RLPi4weFXPWnmQIY2u5MKpk6sXTEkYg-6QLxxPe2qiVMk96H9k1X1M1dOs/s400/Interfacing-keypad-with-AVR-Microcontroller.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5723789941578554210" /></a></div>
<br /><span style="font-style: normal; font-variant: normal; font-weight: normal; font-size: 100%; line-height: normal; font-family: Georgia, serif; "><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">Keypad is most widely used input device to provide input from the outside world to the microcontroller</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">. The keypad makes an application more users interactive. The concept of interfacing a keypad with the ATmega16</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "> is similar to interfacing it with any other microcontroller. The article of Interfacing keypad with 8051</span></span><span style="font-style: normal; font-variant: normal; font-weight: normal; color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "> can be referred for detailed description of the methodology used here. This article explains the interfacing of a 4x3 keypad with AVR Microcontroller </span><span style="font-style: normal; font-variant: normal; font-weight: normal; color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">(ATmega16) and displaying the output on a LCD</span><span style="font-style: normal; font-variant: normal; font-weight: normal; color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">.</span><div style="font-style: normal; font-variant: normal; "><div style="font-weight: normal; margin-top: 0px; margin-right: 0px; margin-bottom: 0.0001pt; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">The algorithm and detailed explanation for keypad interfacing is given in above mentioned article. The brief steps to interface the keypad with AVR are written below:</span></span></span></div><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">1.<span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 7pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: 'Times New Roman'; line-height: normal; "> </span>Configure the row pins or column pins.</span></span></span></div><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">2.<span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 7pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: 'Times New Roman'; line-height: normal; "> </span>Make all output pins to low and input pins to high.</span></span></span></div><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">3.<span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 7pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: 'Times New Roman'; line-height: normal; "> </span>Keep monitoring the port value, where the key pad is connected.</span></span></span></div><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">
<br /></span></span></span></div><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; "><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhedrrlvFu-WuU9V5BNA_4dceS0HcLKzg8U7SgUsX9cUjE4bpvk5vko8ZkDDNlIc1_trKKiJZCdx2nWAF5DZDSzdWC731lhrLB5CdsAmib2Yi8RaTsCeoFUaqcLqqca6AHIJbIJ-DANL2M/s1600/Interface+keypad+with+AVR+microcontroller+circuit.gif" style="font-family: 'Times New Roman'; line-height: normal; text-align: left; font-size: medium; "><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhedrrlvFu-WuU9V5BNA_4dceS0HcLKzg8U7SgUsX9cUjE4bpvk5vko8ZkDDNlIc1_trKKiJZCdx2nWAF5DZDSzdWC731lhrLB5CdsAmib2Yi8RaTsCeoFUaqcLqqca6AHIJbIJ-DANL2M/s400/Interface+keypad+with+AVR+microcontroller+circuit.gif" border="0" alt="" id="BLOGGER_PHOTO_ID_5723790413601833266" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 314px; " /></a></span></span></span></div><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">
<br /></span></span></span></div><div style="margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); text-indent: 0in; text-align: justify; "><span><span style="line-height: 26px; "><b>Program related to this Project: -</b></span></span></div><div style="margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); text-indent: 0in; text-align: justify; "><span><span style="line-height: 26px; "><b>
<br /></b></span></span></div><div style="margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); text-indent: 0in; text-align: justify; "><pre style="margin-top: 15px; margin-bottom: 15px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 5px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 0.92em; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-left-style: solid; border-left-color: rgb(205, 205, 205); font-family: Monaco, Consolas, 'Courier News', monospace; line-height: 1.5; color: rgb(51, 51, 51); text-align: -webkit-auto; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">// Program to get input from keypad and display it on LCD.</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#include<avr h=""></avr></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#include<util h=""></util></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define pad PORTD</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define r1 PD0</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define r2 PD1</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define r3 PD2</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define r4 PD3</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define c1 PD4</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define c2 PD5</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define c3 PD6</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check1(void);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check2(void); </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check3(void);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check4(void);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define LCD_DATA PORTA<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//LCD data port</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define ctrl PORTB</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define en PB2<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//enable signal</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define rw PB1<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//read/write signal</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">#define rs PB0<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//resister select signal</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void LCD_cmd(unsigned char cmd);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void init_LCD(void);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void LCD_write(unsigned char data);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">unsigned int press;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">int main()</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>unsigned char value; </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>DDRA=0xff;<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//LCD_DATA port as output port</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>DDRB=0x07;<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//signal as out put</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>DDRD=0x0F;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>pad=0xf0;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>init_LCD();<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//initialization of LCD</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write_string("press a key");</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_cmd(0xc0);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>while(1)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>PORTD=0xF0;<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//set all the input to one</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>value=PIND;<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//get the PORTD value in variable “value”</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>if(value!=0xf0)<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//if any key is pressed value changed</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check1();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check2();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check3();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check4();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>return 0;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check1(void)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//DDRD = 0xf0;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>pad =0b11111110;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//pad &= (0<<r1);< div=""><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_us(10);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>if(bit_is_clear(PIND,c1))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('1');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c2))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('2');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c3))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('3');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check2(void)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>pad=0b11111101;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>/pad &= (0<<r2);< div=""><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_us(10);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>if(bit_is_clear(PIND,c1))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('4');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c2))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('5');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c3))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('6');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check3(void)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>pad=0b11111011;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//pad &= (0<<r3);< div=""><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_us(10);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>if(bit_is_clear(PIND,c1))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('7');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c2))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('8');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c3))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('9');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check4(void)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>pad =0b11110111;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//pad &= (0<<r4);< div=""><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_us(10);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>if(bit_is_clear(PIND,c1))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('#');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c2))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('0');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c3))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('*');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void init_LCD(void)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_cmd(0x38);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//initializtion of 16X2 LCD in 8bit mode</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(1);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_cmd(0x01);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//clear LCD</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(1);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_cmd(0x0E);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//cursor ON</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(1);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_cmd(0x80);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>// ---8 go to first line and --0 is for 0th position</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(1);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>return;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void LCD_cmd(unsigned char cmd)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_DATA=cmd;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>ctrl =(0<<rs)|(0<<rw)|(1<<en);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> // making RS and RW as LOW and EN as HIGH</rs)|(0<<rw)|(1<<en);<span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(1);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>ctrl =(0<<rs)|(0<<rw)|(0<<en);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> // making RS, RW , LOW and EN as LOW</rs)|(0<<rw)|(0<<en);<span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(50);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>return;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void LCD_write(unsigned char data)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_DATA= data;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>ctrl = (1<<rs)|(0<<rw)|(1<<en);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> // making RW as LOW and RS, EN as HIGH</rs)|(0<<rw)|(1<<en);<span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(1);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>ctrl = (1<<rs)|(0<<rw)|(0<<en);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> // making EN and RW as LOW and RS HIGH</rs)|(0<<rw)|(0<<en);<span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_ms(50);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>// give a 10 milli second delay to get thigs executed</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>return ;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "> </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void LCD_write_string(unsigned char *str)<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//take address vaue of the string in pionter *str</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>int i=0;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>while(str[i]!='\0')<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>// loop will go on till the NULL charaters is soon in string </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write(str[i]);<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>// sending data on CD byte by byte</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>i++;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>return;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div></r4);<></div></r3);<></div></r2);<></div></r1);<></div></span></pre></div><pre style="font-weight: normal; margin-top: 15px; margin-bottom: 15px; margin-left: 40px; padding-top: 10px !important; padding-right: 15px !important; padding-bottom: 10px !important; padding-left: 15px !important; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 5px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 0.92em; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 204); border-left-style: solid; border-left-color: rgb(205, 205, 205); font-family: Monaco, Consolas, 'Courier News', monospace; line-height: 1.5; color: rgb(51, 51, 51); text-align: -webkit-auto; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">while(1)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>PORTD=0xF0;<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//set all the input to one</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>value=PIND;<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//get the PORTD value in variable “value”</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>if(value!=0xf0)<span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//if any key is pressed value changed</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check1();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check2();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check3();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>check4();</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>}</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>}</div></span></pre><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">4.<span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 7pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: 'Times New Roman'; line-height: normal; "> </span>If there is any change in port value, make one of the output pin of port to zero and rest all high.</span></span></span> </div><pre style="font-weight: normal; margin-top: 15px; margin-bottom: 15px; margin-left: 40px; padding-top: 10px !important; padding-right: 15px !important; padding-bottom: 10px !important; padding-left: 15px !important; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 5px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 0.92em; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 204); border-left-style: solid; border-left-color: rgb(205, 205, 205); font-family: Monaco, Consolas, 'Courier News', monospace; line-height: 1.5; color: rgb(51, 51, 51); text-align: -webkit-auto; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">void check1(void)</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">{</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//DDRD = 0xf0;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>pad =0b11111110;</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>//pad &= (0<<r1);< div=""><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>_delay_us(10);</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>if(bit_is_clear(PIND,c1))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('1');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c2))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('2');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>else if(bit_is_clear(PIND,c3))</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span class="Apple-tab-span" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "> </span>LCD_write('3');</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">}</div></r1);<></div></span></pre><div style="font-weight: normal; margin-top: 0in; margin-right: 0in; margin-bottom: 0.0001pt; margin-left: 40px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(255, 255, 255); color: rgb(51, 51, 51); font-family: Tahoma, Arial, sans-serif; text-indent: 0in; text-align: justify; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">5.<span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 7pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: 'Times New Roman'; line-height: normal; "> </span>If any of input pin found zero, write the particular pin data to LCD, else continue with the step (4).</span></span></span></div></div>
<br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com8tag:blogger.com,1999:blog-38587382501777330.post-43457651620542656692012-03-16T12:54:00.004+05:302012-03-18T17:08:16.788+05:30Interfacing GSM Module with 8051 microcontroller (AT89C51) without using PC<div style="text-align: center;"><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">This project presents a way to interface GSM Module</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "> with microcontroller AT89c51</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "> without making use of computer to send AT commands</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "> to the module. This is an improvement over the previous projects (see MC074</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "> & MC075</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">). Instead of using HyperTerminal or any other PC interface, the controller itself sends a fixed AT command to the GSM/GPRS module. The information response and result codes are received and displayed on a 16x2 LCD</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">.</span></div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "><br /></span></div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">Instead of sending commands from the HyperTerminal, AT commands</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "> are sent to the GSM/GPRS module by the microcontroller itself. In this case, the receive (Rx) and transmit (Tx) pin of the GSM module’s RS232 port are connected to the transmit (Tx) and receive (Rx) pin of AT89c51</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); ">’s serial port, respectively. This eliminated the role of computer and just the controller’s circuit provides a complete user interface for the module.</span> </div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "><br /></span></div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 13px; line-height: 26px; text-align: justify; background-color: rgb(255, 255, 255); "><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiTbrhlVMZvF99EsQSmgfgeo3IBh3Bv1mrjKbMCQDCraZz1xLBjOt6qmZg9hCNV5mCQD7tsGUNWiXRR5VoDAp83Rb8jupzFTEOCq5TI3blcxIZMfsbAVo7XaIvRJwkqBIMkjCQYOm5ECEA/s1600/Interfacing+GSM+Module+with+8051+microcontroller+%2528AT89C51%2529+without+using+PC.jpg" style="font-family: Georgia, serif; font-size: 16px; line-height: normal; text-align: left; "><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiTbrhlVMZvF99EsQSmgfgeo3IBh3Bv1mrjKbMCQDCraZz1xLBjOt6qmZg9hCNV5mCQD7tsGUNWiXRR5VoDAp83Rb8jupzFTEOCq5TI3blcxIZMfsbAVo7XaIvRJwkqBIMkjCQYOm5ECEA/s400/Interfacing+GSM+Module+with+8051+microcontroller+%2528AT89C51%2529+without+using+PC.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5720394897808563506" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 138px; " /></a><br class="Apple-interchange-newline"></span></div><div><span style="text-align: justify; background-color: rgb(255, 255, 255); "><div style="font-style: normal; font-variant: normal; font-weight: normal; color: rgb(51, 51, 51); margin-top: 0px; margin-right: 0px; margin-bottom: 0.0001pt; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; font-family: Tahoma, Arial, sans-serif; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">The controller is programmed to send a fixed command ‘AT’ to the module. The command AT is used to check the communication with module. It returns a result code OK if the module and the controller are connected properly. If either of the module or SIM are not working, it returns a result code ERROR.</span></span></span></div><div style="font-style: normal; font-variant: normal; font-weight: normal; color: rgb(51, 51, 51); margin-top: 0px; margin-right: 0px; margin-bottom: 0.0001pt; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 12px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; font-family: Tahoma, Arial, sans-serif; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 13px; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; background-position: initial initial; background-repeat: initial initial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; ">The program complexities for display of information responses and result codes on LCD mentioned in MC075 remain same here as well.</span></span></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0.0001pt; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; "><div style="text-align: justify;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhA580Ofq7MIjB8InJDdFcx7Lr6kJtKjRNsMU4gw_k-f3wN6C6xzxLeUAPy4ukqUQuQMOSUwCgrg1SB5DUVN1TyXiyzadDjMd0aP9i4A3XFhU8KCTNbODYLDwzs-MXHvLjvlrUHaFSMUWE/s1600/circuit+of+Interfacing+GSM+Module+with+8051+microcontroller+%2528AT89C51%2529+without+using+PC1.gif" style="text-align: left; "><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhA580Ofq7MIjB8InJDdFcx7Lr6kJtKjRNsMU4gw_k-f3wN6C6xzxLeUAPy4ukqUQuQMOSUwCgrg1SB5DUVN1TyXiyzadDjMd0aP9i4A3XFhU8KCTNbODYLDwzs-MXHvLjvlrUHaFSMUWE/s400/circuit+of+Interfacing+GSM+Module+with+8051+microcontroller+%2528AT89C51%2529+without+using+PC1.gif" border="0" alt="" id="BLOGGER_PHOTO_ID_5721199862317144402" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 236px; " /></a></div></div><div style="font-style: normal; font-variant: normal; font-weight: normal; margin-top: 0px; margin-right: 0px; margin-bottom: 0.0001pt; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; "><b style="background-color: transparent; line-height: 26px; font-family: Arial; font-size: 100%; ">Program Code: -</b></div><div style="font-style: normal; font-variant: normal; font-weight: normal; font-size: 100%; margin-top: 0px; margin-right: 0px; margin-bottom: 0.0001pt; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; font-family: Tahoma, Arial, sans-serif; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; "><span><b><br /></b></span></span></span></span></div><div style="font-style: normal; font-variant: normal; font-weight: normal; font-size: 100%; margin-top: 0px; margin-right: 0px; margin-bottom: 0.0001pt; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; font-family: Tahoma, Arial, sans-serif; line-height: 24px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; font-family: Arial; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; line-height: 26px; "><pre style="margin-top: 15px; margin-bottom: 15px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 5px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: 0.92em; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-left-style: solid; border-left-color: rgb(205, 205, 205); font-family: Monaco, Consolas, 'Courier News', monospace; line-height: 1.5; color: rgb(51, 51, 51); text-align: -webkit-auto; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; border-image: initial; outline-width: 0px; outline-style: initial; outline-color: initial; font-size: small; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; background-position: initial initial; background-repeat: initial initial; ">// Program to Interface GSM Module with 8051 microcontroller (AT89C51) without using PC<br /><br />#include<reg51.h><br />#define port P1<br />#define dataport P2 // Data port for LCD<br />sbit rs = port^2;<br />sbit rw = port^3;<br />sbit en = port^4;<br />int count,i;<br />unsigned char check,str[15];<br />bit check_space;<br /><br />void init_serial() // Initialize serial port<br />{<br />TMOD=0x20; // Mode2<br />TH1=0xfd; // 9600 baud<br />SCON=0x50; // Serial mode=1 ,8-Bit data,1 Stop bit ,1 Start bit, Receiving on<br />TR1=1; // Start timer<br />}<br />void delay(unsigned int msec) // Function for delay<br />{<br />int i,j;<br />for(i=0;i<msec;i++) j="0;" void="" unsigned="" char="" function="" to="" send="" command="" lcd="" dataport="item;" rs="0;" rw="0;" en="1;" display="" character="" string="" int="" i="0;" for="" using="" bit="" 2="" row="" cursor="" blinking="" set="" the="" first="" position="" of="" transmit="" data="" through="" serial="" port="" sbuf="str;" store="" in="" ti="=0);" wait="" till="" transmits="" interrupt="" 4="" recieve="" serialy="" from="" rs232="" into="" microcontroller="" ri="0;" read="" check="" carraige="" return="" and="" new="" line="" case="" 0x00="" break="" 0x01="" carriage="" default="" 0x02="" characters="" except="" initialize="" count="(-1);" ie="0x94;" on="">=0)<br />{<br />check=byte_check(); // Check the character<br />if(check!=0x00)<br />{<br /> if(check==0x01)<br /> {<br /> if(check_space==1) // Check previous character<br /> {<br /> lcd_data(0x20);<br /> check_space=0;<br /> }<br /> }<br /> else<br /> {<br /> lcd_data(str[0]);<br /> check_space=1;<br /> }<br />}<br />count--; <br />for(i=0;i<count;i++) shift="" the="" whole="" array="" to="" left="" span="" one=""></count;i++)></msec;i++)></reg51.h></span></pre></span></span></span></div></span></div><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com6tag:blogger.com,1999:blog-38587382501777330.post-59216056677970668032012-03-16T10:53:00.004+05:302012-03-16T11:11:07.393+05:30Interface GSM Module with 8051<div style="text-align: center;"><span style="text-align: left; font-size: 11pt; line-height: 115%; font-family: Calibri, sans-serif; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-top-color: windowtext; border-right-color: windowtext; border-bottom-color: windowtext; border-left-color: windowtext; border-top-width: 1pt; border-right-width: 1pt; border-bottom-width: 1pt; border-left-width: 1pt; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; ">The project explains interfacing of the AT89C51 microcontroller with the</span><span style="text-align: left; font-size: 11pt; line-height: 115%; font-family: Calibri, sans-serif; "> <span style="border:none windowtext 1.0pt; mso-border-alt:none windowtext 0in;padding:0in"><a href="http://www.engineersgarage.com/articles/gsm-gprs-modules"><span style="font-size:12.0pt;line-height:115%;color:#0088CC;border:none"><span style="border:none">GSM module</span></span></a></span></span><span style="text-align: left; font-size: 12pt; line-height: 115%; font-family: Calibri, sans-serif; "> <span style="border:none windowtext 1.0pt;mso-border-alt:none windowtext 0in; padding:0in">and the HyperTerminal. HyperTerminal is a Windows application. The</span></span><span style="text-align: left; font-size: 11pt; line-height: 115%; font-family: Calibri, sans-serif; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-top-color: windowtext; border-right-color: windowtext; border-bottom-color: windowtext; border-left-color: windowtext; border-top-width: 1pt; border-right-width: 1pt; border-bottom-width: 1pt; border-left-width: 1pt; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; "><a href="http://www.engineersgarage.com/tutorials/at-commands"><span style="font-size:12.0pt;line-height:115%;color:#0088CC;border:none"><span style="border:none">AT commands</span></span></a></span><span style="text-align: left; font-size: 11pt; line-height: 115%; font-family: Calibri, sans-serif; "> <span style="border:none windowtext 1.0pt;mso-border-alt:none windowtext 0in; padding:0in">are sent by the HyperTerminal to the GSM module. The Information Response and/or Result Codes are received at the microcontroller and retransmitted to the HyperTerminal by the controller.</span></span></div><span style="font-style: normal; font-variant: normal; font-weight: normal; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-top-color: windowtext; border-right-color: windowtext; border-bottom-color: windowtext; border-left-color: windowtext; border-top-width: 1pt; border-right-width: 1pt; border-bottom-width: 1pt; border-left-width: 1pt; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; "><!--[if !supportLineBreakNewLine]--><br /><!--[endif]--></span><div><span style="border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-top-color: windowtext; border-right-color: windowtext; border-bottom-color: windowtext; border-left-color: windowtext; border-top-width: 1pt; border-right-width: 1pt; border-bottom-width: 1pt; border-left-width: 1pt; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; "><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiQyqcTa8k8dlgcqB9s1EyX-xRuTgJ4zEsR6UdHZwUQmAAx7AaIlioLSI90caqkKUVIaAaePLI_0OHv4YzLmmjljGcGUInmV-rlkLYMtkxlSg0THg9rqMv_3nnHO2nUVS51RQJGWRu0J_o/s1600/Interface+GSM+Module+with+8051+microcontroller+%2528AT89C51%2529+using+PC+circuit.gif" style="font-style: normal; font-variant: normal; font-weight: normal; font-size: 12pt; font-family: Georgia, serif; line-height: normal; "><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiQyqcTa8k8dlgcqB9s1EyX-xRuTgJ4zEsR6UdHZwUQmAAx7AaIlioLSI90caqkKUVIaAaePLI_0OHv4YzLmmjljGcGUInmV-rlkLYMtkxlSg0THg9rqMv_3nnHO2nUVS51RQJGWRu0J_o/s400/Interface+GSM+Module+with+8051+microcontroller+%2528AT89C51%2529+using+PC+circuit.gif" border="0" alt="" id="BLOGGER_PHOTO_ID_5720363239173874658" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 400px; " /></a><p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="border:none windowtext 1.0pt;mso-border-alt: none windowtext 0in;padding:0in">A GSM module has an RS232 interface for serial communication with an external peripheral. In this case, the transmit pin (Tx) of the computer’s Serial port is connected with the receive pin (Rx) of the GSM module’s RS-232 interface. The transmit pin (Tx) of the RS-232 of GSM module is connected to receive pin (Rx) of microcontroller’s serial transmission pin. And the serial transmit pin of the microcontroller is connected to the receive pin of the computer’s Serial port. Therefore the commands and their results are transmitted and received in a triangular fashion as depicted below.</span><span style="font-size:9.0pt;font-family:"Tahoma","sans-serif""><o:p></o:p></span></p> <p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="font-size:9.0pt;border:none windowtext 1.0pt; mso-border-alt:none windowtext 0in;padding:0in"> </span><span style="font-size:9.0pt;font-family:"Tahoma","sans-serif""><o:p></o:p></span></p> <p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="font-size:12.0pt; border:none windowtext 1.0pt;mso-border-alt:none windowtext 0in;padding:0in"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihImeFOx9mfJ8aDTH4dCg8fdxX9K_GWaGGGdLau_1unvzCxqBUVt8E_HwSa_V0ciZXA789H40YWST3TO7pIT22W8s1E1AAP3-2WfAmPanTF-xV55WT6A4IIHQYL_3GJZ811e_ki9jLHbc/s1600/qwerty.jpg" style="font-family: 'Times New Roman'; line-height: normal; font-size: medium; "><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihImeFOx9mfJ8aDTH4dCg8fdxX9K_GWaGGGdLau_1unvzCxqBUVt8E_HwSa_V0ciZXA789H40YWST3TO7pIT22W8s1E1AAP3-2WfAmPanTF-xV55WT6A4IIHQYL_3GJZ811e_ki9jLHbc/s400/qwerty.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5720364532431671202" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 400px; height: 138px; " /></a><br class="Apple-interchange-newline"><!--[endif]--></span><span style="font-size:9.0pt;font-family:"Tahoma","sans-serif""><o:p></o:p></span></p> <p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="border:none windowtext 1.0pt;mso-border-alt: none windowtext 0in;padding:0in">[In subsequent projects (see</span> <span style="border:none windowtext 1.0pt;mso-border-alt:none windowtext 0in; padding:0in"><a href="http://www.engineersgarage.com/microcontroller/8051projects/interface-gsm-module-8051-microcontroller-circuit-code"><span style="color:#0088CC;border:none"><span style="border:none">MC075</span></span></a></span> <span style="border:none windowtext 1.0pt;mso-border-alt:none windowtext 0in; padding:0in">&</span> <span style="border:none windowtext 1.0pt; mso-border-alt:none windowtext 0in;padding:0in"><a href="http://www.engineersgarage.com/microcontroller/8051projects/interfacing-gsm-8051-microcontroller-circuit-code"><span style="color:#0088CC;border:none"><span style="border:none">MC076</span></span></a>), the HyperTerminal will be replaced by the microcontroller itself; thus avoiding the need of using a Computer to establish an interface. This would lead to an independent GSM based system.]</span><span style="font-size:12.0pt;border:none windowtext 1.0pt; mso-border-alt:none windowtext 0in;padding:0in"><br /></span><span style="border:none windowtext 1.0pt;mso-border-alt:none windowtext 0in; padding:0in">The microcontroller is programmed to receive and transmit data at a baud rate of 9600. For more details on setting the baud rate of microcontroller, refer</span> <span style="border:none windowtext 1.0pt; mso-border-alt:none windowtext 0in;padding:0in"><a href="http://www.engineersgarage.com/microcontroller/8051projects/interface-serialport-RS232-AT89C51"><span style="color:#0088CC;border:none"><span style="border:none">serial communication with 8051</span></span></a>.<br /><!--[if !supportLineBreakNewLine]--><br /><!--[endif]--></span><span style="font-size:9.0pt;font-family:"Tahoma","sans-serif""><o:p></o:p></span></p> <p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="font-size:9.0pt;border:none windowtext 1.0pt; mso-border-alt:none windowtext 0in;padding:0in"> </span><span style="font-size:9.0pt;font-family:"Tahoma","sans-serif""><o:p></o:p></span></p> <p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="border:none windowtext 1.0pt;mso-border-alt: none windowtext 0in;padding:0in">The controller can receive data signals either by polling or by making use of serial interrupt (ES). Serial interrupt has been explained in</span> <span style="border:none windowtext 1.0pt;mso-border-alt: none windowtext 0in;padding:0in"><a href="http://www.engineersgarage.com/tutorials/8051-interrupts-programming"><span style="color:#0088CC;border:none"><span style="border:none">interrupt programming</span></span></a>. In polling, the controller continuously scans serial port for incoming data from the GSM module.<br /><!--[if !supportLineBreakNewLine]--><br /><!--[endif]--></span><span style="font-size:9.0pt;font-family:"Tahoma","sans-serif""><o:p></o:p></span></p> <p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="border:none windowtext 1.0pt;mso-border-alt: none windowtext 0in;padding:0in">In this project, interrupt has been used for monitoring and controlling the flow of data by the controller instead of the polling method.</span><span style="font-size:9.0pt;font-family:"Tahoma","sans-serif""><o:p></o:p></span></p><p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; font-weight: normal; font-size: 12pt; "><span style="border:none windowtext 1.0pt;mso-border-alt: none windowtext 0in;padding:0in"><br /></span></p><p class="MsoNoSpacing" style="font-family: Calibri, sans-serif; font-style: normal; font-variant: normal; line-height: 115%; "><span ><b>PROGRAM RELATED TO PROJECT: -</b></span></p><p class="MsoNoSpacing"><span ><span style="line-height: 18px; "></span></span></p><p class="MsoNoSpacing"><span >// Program to interface GSM Module with 8051 microcontroller (AT89C51) using PC</span></p><p class="MsoNoSpacing"><span >#include<reg51.h></reg51.h></span></p><p class="MsoNoSpacing"><span >unsigned char str;</span></p><p class="MsoNoSpacing"><span style="font-family: Calibri, sans-serif; ">void init_serial()</span><span class="Apple-tab-span" style="font-family: Calibri, sans-serif; white-space: pre; "> </span><span style="font-family: Calibri, sans-serif; "> // Initialize serial port</span></p><p class="MsoNoSpacing"><span >{</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>TMOD=0x20; // Mode=2</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>TH1=0xfd;<span class="Apple-tab-span" style="white-space:pre"> </span> // 9600 baud</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>SCON=0x50; // Serial mode=1 ,8-Bit data,1 Stop bit ,1 Start bit , Receiving on</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>TR1=1;<span class="Apple-tab-span" style="white-space:pre"> </span> // Start timer</span></p><p class="MsoNoSpacing"><span >}</span></p><p class="MsoNoSpacing"><span style="font-family: Calibri, sans-serif; ">void transmit_data(unsigned char str)</span><span class="Apple-tab-span" style="font-family: Calibri, sans-serif; white-space: pre; "> </span><span style="font-family: Calibri, sans-serif; ">// Function to transmit data through serial port</span></p><p class="MsoNoSpacing"><span >{</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>SBUF=str;<span class="Apple-tab-span" style="white-space:pre"> </span> // Store data in sbuf</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>while(TI==0);<span class="Apple-tab-span" style="white-space:pre"> </span> // Wait till data transmit</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>TI=0;<span class="Apple-tab-span" style="white-space:pre"> </span> </span></p><p class="MsoNoSpacing"><span >}</span></p><p class="MsoNoSpacing"><span style="font-family: Calibri, sans-serif; ">void receive_data() interrupt 4</span><span class="Apple-tab-span" style="font-family: Calibri, sans-serif; white-space: pre; "> </span><span style="font-family: Calibri, sans-serif; "> // Function to recieve data serialy from RS232 into microcontroller</span></p><p class="MsoNoSpacing"><span > {</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span> str=SBUF; // Read sbuf</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span> RI=0;</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span> transmit_data(str); // Transmit to HyperTerminal</span></p><p class="MsoNoSpacing"><span > }</span></p><p class="MsoNoSpacing"><span style="font-family: Calibri, sans-serif; ">void main()</span></p><p class="MsoNoSpacing"><span >{</span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>init_serial();<span class="Apple-tab-span" style="white-space:pre"> </span> // Initialize serial port<span class="Apple-tab-span" style="white-space:pre"> </span></span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>IE=0x90; </span></p><p class="MsoNoSpacing"><span ><span class="Apple-tab-span" style="white-space:pre"> </span>while(1);</span></p><p class="MsoNoSpacing"><span >}</span></p><p class="MsoNoSpacing"><span ><b>VIDEO RELATED TO PROJECT: -</b></span></p><p class="MsoNoSpacing"><span ><b><br /></b></span></p><p></p></span></div><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.blogger.com/video.g?token=AD6v5dy1UDJYqrVa5M-KYYyRR11vHY5D_WGtfNdLc3Bp-046WvCB51H_hVeNlo9wOwC64vXopGNSKvZbwsh3FF37' class='b-hbp-video b-uploaded' frameborder='0'></iframe><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com1tag:blogger.com,1999:blog-38587382501777330.post-8246605506137016962012-03-05T23:51:00.004+05:302012-03-05T23:54:54.772+05:304x4 Matrix Keypad<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiv9o_0-ebLErCGo89HMETa2GiI1IB35y0xfVvLWWaVsdu7XPsJ_o4sx-4TiEA086NglD59E8433HvTWWAKxypl_egVuAOLSR4bkTFW7O82JT8qSCleZvvqZs-8H-oH-qfnjnzGnmDr3vM/s1600/Untitled+1.jpg"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 198px; height: 152px;" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiv9o_0-ebLErCGo89HMETa2GiI1IB35y0xfVvLWWaVsdu7XPsJ_o4sx-4TiEA086NglD59E8433HvTWWAKxypl_egVuAOLSR4bkTFW7O82JT8qSCleZvvqZs-8H-oH-qfnjnzGnmDr3vM/s400/Untitled+1.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5716480523565532626" /></a><br /><p class="MsoNormal" style="font-family: Georgia, serif; margin-top: 6pt; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; line-height: 13.4pt; "><span style="font-family:"Arial","sans-serif"">This is as simple routine how to read 4x4 keypad keys using AVR-GCC language. The keypad is connected to AVR microcontroller 8 bit port. In this example it is B port. You can change ports depending on your needs – this is only an example ant it is not the only way to this.<o:p></o:p></span></p> <p class="MsoNormal" align="center" style="margin-top: 6pt; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; text-align: center; line-height: 13.4pt; "><span ><br /></span></p> <p class="MsoNormal" style="font-family: Georgia, serif; margin-top: 6pt; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; line-height: 13.4pt; "><span style="font-family:"Arial","sans-serif"">How it works. Well very simply. PORTB is divided into two nibbles PINB0 – PINB3 as inputs (as rows) and PINB4-PINB7 as outputs (columns). The keys are checked in a loop in series. Lets say if we set first row output (PORTB bit 7) to 0 then when checking rows we are looking which bit is set to 0, because of key pressed with function bit_is_set(PINB, bitNo). This function gives non-zero if bit is clear.<o:p></o:p></span></p> <p class="MsoNormal" style="font-family: Georgia, serif; margin-top: 6pt; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; line-height: 13.4pt; "><span style="font-family:"Arial","sans-serif"">10k resistors protect AVR from shortcuts.<o:p></o:p></span></p> <div style="font-family: Georgia, serif; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: rgb(221, 221, 221); border-right-color: rgb(221, 221, 221); border-bottom-color: rgb(221, 221, 221); border-left-color: rgb(221, 221, 221); border-top-width: 1pt; border-right-width: 1pt; border-bottom-width: 1pt; border-left-width: 1pt; border-image: initial; padding-top: 9pt; padding-right: 0.25in; padding-bottom: 9pt; padding-left: 0.25in; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); background-position: initial initial; background-repeat: initial initial; "> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">#include <avr h=""><o:p></o:p></avr></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">int main()<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">{<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">//high nibble for output(columns) low for input(rows);<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">DDRB=0xF0;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">//enable internal pullups for PB0-PB3<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">PORTB=0x0F;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">//Port D for indication only<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">DDRD=0xFF;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">while (1) //loop key check forever<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> {<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> //first column<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> PORTB =0b01111111;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> //check for rows and send key number to portD<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> //instead sending key number to PORTD you can use<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> // any function that serves pressed button<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 3)) PORTD=1;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 2)) PORTD=2;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 1)) PORTD=3;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 0)) PORTD=4;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> //second column<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> PORTB =0b10111111;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 3)) PORTD=5;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 2)) PORTD=6;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 1)) PORTD=7;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 0)) PORTD=8;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> //third column<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> PORTB =0b11011111;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 3)) PORTD=9;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 2)) PORTD=10;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 1)) PORTD=11;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 0)) PORTD=12;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> //fourth column<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> PORTB =0b11101111;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 3)) PORTD=13;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 2)) PORTD=14;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 1)) PORTD=15;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> if (bit_is_set(PINB, 0)) PORTD=16;<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""> }<o:p></o:p></span></p> <p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New"">}<o:p></o:p></span></p><p class="MsoNormal" style="margin-bottom: 0.0001pt; line-height: 13.4pt; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; border-image: initial; padding-top: 0in; padding-right: 0in; padding-bottom: 0in; padding-left: 0in; background-position: initial initial; background-repeat: initial initial; "><span style="font-size:10.0pt; font-family:"Courier New""><br /></span></p> </div> <p class="MsoNormal" style="font-family: Georgia, serif; "><o:p> </o:p></p><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-17578529962085993742012-03-05T23:28:00.002+05:302012-03-05T23:50:03.249+05:308051 Microcontroller based Digital alarm clok with Thermometer circuit<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhPrY1DRl3b90gdlaKOrhjHkG_wbm-OjvoW1cBpzkf_jR7sRTn9OEzkwhZIzzeTv_D_4Eh8BHV2RvvyJIPdOYKXMmkQFwGqpUBSniyHxqSCmBVNCp60is-TUA5DLjrdQhD384zwxQQd_dE/s1600/8051+Microcontroller+based+Digital+alarm+clok+with+Thermometer+circuit.gif"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 400px;" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhPrY1DRl3b90gdlaKOrhjHkG_wbm-OjvoW1cBpzkf_jR7sRTn9OEzkwhZIzzeTv_D_4Eh8BHV2RvvyJIPdOYKXMmkQFwGqpUBSniyHxqSCmBVNCp60is-TUA5DLjrdQhD384zwxQQd_dE/s400/8051+Microcontroller+based+Digital+alarm+clok+with+Thermometer+circuit.gif" border="0" alt="" id="BLOGGER_PHOTO_ID_5716474346106257282" /></a><br /><div style="text-align: center;"><span ><u><br /></u></span></div>In this project you can develop digital watch, also with timer facility, and also temperature sensor with which you can measure room temperature in which you placed this device.<br /><div style="text-align: center;"><span ><u><br /></u></span></div><span ><b>Components Used in this Project: -</b></span><div><span ><b><br /></b></span></div><div><b>1) LM35 (Temperature Sensor)</b></div><div><b>2) Buzzer (which work as hooter)</b></div><div><b>3) 5 Volt Power Supply</b></div><div><b>4) ADC 0804 (Analog to Digital Convertor)</b></div><div><b>5) AT89C51 Microcontroller</b></div><div><b>6) 16x2 LCD</b></div><div><b>7) 11.0592 Crystal Oscillator</b></div><div><b>8) Resistor</b></div><div><b>9) Capacitor</b></div><div><b>10) Variable Resistor</b></div><div><b><br /></b></div><div><b><br /></b></div><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.blogger.com/video.g?token=AD6v5dyI-F7KCNGIrnmfpdE87LbJDQLQhkbx63FzKm7TCC5nSmfs_qIpvwjIhI-NUBrUbhvo3OKfx2cIKCqOuLRU' class='b-hbp-video b-uploaded' frameborder='0'></iframe><div><br /></div><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com2tag:blogger.com,1999:blog-38587382501777330.post-11226282798997709222012-03-05T23:10:00.005+05:302012-03-05T23:58:07.809+05:30Fixed Voltage Power Supply<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEikTpniOLlHf2Cdsj54tWoYkgP3DX6gcPUJdTiCGJT4kaqTNCWUQaZqBhaOJYsL4veJIUmIkAKC1paGS4-f5Cpy_1pyb1UifyQUNVwurlNM0h237nJINsx9KayMbGenVkHyAyTHUc2ohd0/s1600/Audio+amplifier.gif"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 267px;" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEikTpniOLlHf2Cdsj54tWoYkgP3DX6gcPUJdTiCGJT4kaqTNCWUQaZqBhaOJYsL4veJIUmIkAKC1paGS4-f5Cpy_1pyb1UifyQUNVwurlNM0h237nJINsx9KayMbGenVkHyAyTHUc2ohd0/s400/Audio+amplifier.gif" border="0" alt="" id="BLOGGER_PHOTO_ID_5716481537995650322" /></a><br /><div style="text-align: center;"><span ><u><br /></u></span></div><span ><span style="font-size: 100%;">this is a fixed voltage power supply, in this power supply we use certain components:-</span></span><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><br /></div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; ">1) Transformer (12 volts)</div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; ">2) Bridge Rectifier</div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; ">3) Voltage Regulator (7805 for 5 volt supply, 7809 for 9 volt supply)</div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; ">4) Capacitor as shown in circuit diagram</div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; ">5) Diode (D5 IN4007)</div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><br /></div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; ">In this voltage regulator regulates the power supply to such a extent which is required in the project, so you can use 7805 for preparing 5 volt supply and for 9 volt supply you use 7809.</div><div style="font-family: Georgia, serif; font-size: 100%; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal; "><br /></div><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymoushttp://www.blogger.com/profile/08385003622896756581noreply@blogger.com4tag:blogger.com,1999:blog-38587382501777330.post-75673587057620732362012-01-01T19:45:00.002+05:302012-02-20T01:56:17.873+05:30General Electronics projects<ol><li><b>PRE STAMPEDE MONITORING AND ALERT SYSTEM:</b> A large number of pressure actuated switches interfaced to microcontroller to provide pre stampede warning by a buzzer, once the crowd concentrate at place for a long time with little forward movements taking place .</li><li><b>Modern home automation system using intelligent touch screen:</b> A touch screen based transmitting unit is used to manage home lighting system remotely with RF receiver to avoid complicated wiring in existing buildings.</li><li><b>WIRELESS POWER TRANSFER:</b> The project is to develop a system of wireless power transfer for pace makers battery charging (An electronic device implanted in body that works in place of a defective heart valve) .Otherwise the patient is required to be operated every year to replace the battery .</li><li><b>PC CONTROLLED SCROLLING MESSAGE DISPLAY FOR COLLEGE NOTICE BOARD: </b>Message sent from the PC is transmitted to the notice board over cable ,goes on scrolling in a LCD display in 2 lines until the next message is entered or cancelled.</li><li><b>Propeller display: </b>Indication of name/time etc using a set of lads rotating at high speed to give a virtual display being wirelessly powered.</li><li><b>RASH DRIVING WARNING SYSTEM FOR HIGHWAY POLICE:</b> The time difference between 2 spots with ,one in advance to the other in the direction of the traffic flow, is fed to a circuit to convert the same to the speed of a vehicle and warn if the same exceeds a specified limit by a buzzer sound.</li><li><b>Density based traffic light timing control (Using PIC Microcontroller):</b> The project is to solve traffic congestion by a dynamic and automatic traffic light control system based on the traffic density using appropriate system and hardware. IR sensors across the road used to monitor the length of vehicles blocking the road traffic. The signals from the IR receivers are fed to the MC to follow the program with the time as desired.</li><li><b>Street lights that glow for 1/2km only on detecting vehicle movement:</b> Light Emitting Diode (LED) replaces HID lamps by engaging a programmable microcontroller that controls intensity by pulse width modulation which enables energy saving during late nights considering low traffic density. The pulse width becomes very narrow on sensing no movement of vehicles. As the vehicle forwards, the intensity goes on increasing for few lights ahead, and as it passes away the intensity goes on falling.</li><li><b>Dynamically changing signal light time allotment in street junctions based on traffic density:</b> The project is to solve traffic congestion by a dynamic and automatic traffic light control system based on the traffic density using appropriate system and hardware. IR sensors across the road used to monitor the length of vehicles blocking the road traffic. The signals from the IR receivers are fed to the Microcontroller to follow different time for different level of traffic.</li><li><b>Low cost Programmable Logic Control ( PLC) for industrial automation in repetitive nature of work: </b>Objective is designing a microcontroller based programmable time setting by the user through microcontroller architecture loaded with an application program. Switches are provided for set mode, auto mode , manual mode and time change mode. Machines will run based on/off sequentially in auto mode in default time settings or set mode time setting or manual mode depending on the user’s need and flexibility.</li><li><b>WIRELESS AUDIO TRANSMITTER FOR TV:</b> The audio output of the TV is fed to an FM transmitter that transmits the audio to be received by any FM receiver (or a cell phone having FM radio).It can be used to listen to TV sound without disturbing any one else.</li><li><b>Automatic irrigation system on sensing soil moisture content:</b> The circuit comprises of sensor parts built using op-amp and are configured here as a comparator. Two stiff copper wires are inserted in the soil to sense whether it is dry. The Microcontroller turns the motor ON and OFF based on sensors condition that is dry or wet respectively. Sensor signals are operated with the control of software that is stored in ROM of the MC.</li><li><b>PRECISE ILLUMINATION CONTROL OF LAMP:</b> Precise percentage of illumination entered through a numeric key pad is interfaced to a micro controller to maintain illumination of a lamp. The firing angle would be automatically adjusted to maintain the load power to the lamp such that the entered intensity matches the required one.</li><li><b>PROGRAMABLE ENERGY AUDITING EQIPMENT FOR INDUSTRY FOR INSTANTANEOUS ELECTRICAL LOAD SURVEY:</b> Auto calculation of energy details in a minute ,to indicate the load consumption in units and cost in rupees while the load is assumed to run for specific number of hours, with displays on a 16X2 LCD duly interfaced with the microcontroller.</li><li><b>HOME AUTOMATION USING DIGITAL CONTROL:</b> A circuit interfaced to a land line telephone is used to control on off of home / office load remotely using DTMF technology but without using any microcontroller or any program.</li><li><b>HIDDEN ACTIVE CELLPHONE DETECTOR:</b> A 555 timer in mono-stable mode along with a high gain op amp is used to detect Giga Hertz induced signals so produced by an active cell phone with in closer proximity to sound a buzzer alarm.</li><li><b>STAMP VALUE CALCULATOR FOR POST OFFICE:</b> Calculating the weight of the letters & value by a balancing arrangement is used to control a potentiometer the output of which is fed to an ADC interfaced to microcontroller having a display.</li><li><b>Life cycle testing of electrical loads by down counter:</b> A preset able counter with keypad entry that counts down from the set number till it reaches zero with relay operation connected to a load that switches ON & OFF is used for life cycle test of the gadget under test say a lamp to determine its life.</li><li><b>A LOW COST LONG RANGE FM TRANSMITTER WITH AUDIO MODULATION: </b>A low cost FM transmitter with audio modulation consisting of 106 MHz oscillator circuit, VFO and RF power amplifier connected to a tuned Yagi antenna to cover about 5 km line of site distance or 1Km by GP antenna.</li><li><b>User programmable password based hotel room door lock:</b> The microcontroller based Door locker is an access control system that allows only authorized persons to access a restricted area. The password is stored in another dedicated EEPROM which can be changed at any time unlike a fixed one burnt permanently on to the microcontroller.</li><li><b>REMOTE JAMMING DEVICE:</b> The IR rays of standard TV remote frequency at 38 KHz transmitted at a higher intensity to overpower the TV remote signals as they also work on 38 KHz.</li><li><b>IR OBSTACLE DETECTION TO ACTUATE LOAD:</b> 38 KHz IR signals generated by 555 timer feeding IR diode received by tuned IR receiver generates an interrupt while obstructed to actuate a load.</li><li><b>SPEED CHECKER TO DETECT RASH DRIVING ON HIGHWAYS: </b>The time difference between 2 spots with ,one in advance to the other in the direction of the traffic flow, is fed to a programmed microcontroller to convert the same to the speed of a vehicle and warn if the same exceeds a specified limit by a buzzer sound.</li><li><b>AUTOMATIC DUSK TO DAWN (EVENING ON TO MORNING OFF):</b> LDR input compared op amp turns ON the appliances on through relay at falling light intensity in evening and OFF at the morning light.</li><li><b>RHYTHM FOLLOWING FLASHING LIGHTS:</b> Sound signals sensed by condenser microphone are amplified to feed triacs to drive the bulbs or LED via opto isolator to increase or decrease the lamp intensity according to the music level.</li><li><b>SUN TRACKING SOLAR PANEL:</b> Microcontroller interfaced to a stepper motor to rotate the solar panel during day, in steps from zero to 180 degrees to track the sun for maximum power delivery (solar panel not supplied).</li><li><b>Programmable load shedding time management for utility department:</b> Time Operated Electrical Appliance Controlling System is a reliable circuit that takes over the manual task of switch on/off the electrical devices with respect to time. It has an Inbuilt Real Time Clock (RTC) which tracks over the Real Time. When this time equals to the programmed time, then the corresponding Relay for the device is switched ON. Multiple time programming is also available.</li><li><b>Auto power supply control from 4 different sources:</b> Solar, Mains, Generator & Inverter to ensure no break power: The main scope of the project is to consume the power from supply mains, generator, and wind power and solar optimally by using appropriate program through microcontroller in most cost effective way.</li><li><b>Control unit designed for a DC motor:</b> The speed of motor is directly proportional to the DC voltage applied across its terminals where the voltage is applied to control motor speed with Pulse Width Modulation wave. Here based on the pulse duty cycle provided by microcontroller the speed of motor is controlled.</li><li><b>Intelligent, real time auto intensity control of highway lights:</b> White Light Emitting Diode (LED) replaces HID lamps by engaging a programmable microcontroller that controls intensity by pulse width modulation duty cycle which enables energy saving during late nights considering low traffic density.</li><li><b>Industrial drafting fan in stepped speed control using BLDC motor:</b> Eight step control of BLDC motor speed by microcontroller fed MOSFET for meeting industrial needs.</li><li><b>ELECTRONIC EYE CONTROLLED SECURITY SYSTEM:</b> A pair of photo sensors detecting movements to activate a relay to switch ON any load together with an alarm system</li><li><b>FASTEST FINGER PRESS QUIZ BUZZER:</b> A set of 8 switches interfaced to an octal transparent CMOS digital latch wired as priority encoder to activate a buzzer.</li><li><b>PRE-PROGRAMMED DIGITAL SCROLLING MESSAGE SYSTEM:</b> Bright alphanumeric LED display scrolling advertisement system in show windows.</li><li><b>INTELLIGENT OVERHEAD TANK WATER LEVEL INDICATOR:</b> 10 to 4 priority encoder interfaced to a BCD to 7 segment decoder for display of water level in a scale of 0 to 10.</li><li><b>MAINS OPERATED LED LIGHT IN STRING:</b> A string of LED’s are made to operate at 230V AC by series capacitor drop and current limit resistor and then being rectified to DC for maintaining a safe operating voltage for the LEDs.</li><li><b>THERMISTER BASED TEMPERATURE CONTROL WITHOUT MICRO CONTROLLER: </b>Negative co-efficient thermistor used along with an operational amplifier used as comparator to actuate a relay in the event of temperature going out of range.</li><li><b>STEP UP 6 VOLT DC TO 12 VOLT DC USING 555 TIMER:</b> A 555 timer used in astable mode outputs twice the PWM AC from 6 volt DC and then by voltage multiplication to generate 12 volt DC by capacitor charge pump method.</li><li><b>OVER VOLTAGE OR UNDER VOLTAGE ALERT SYSTEM:</b> Two 555 timers used on window comparator, the output of which gets active LED indication when voltage exceeds or falls the set threshold value.</li><li><b>OBJECT COUNTER WITH 7 SEGMENT DISPLAY:</b> An IR sensor receives the interrupt pulses to count and send the data to microcontroller for displaying it on 7-segment LED’s.</li><li><b>INCOMING PHONE RING LIGHT FLASHER:</b> Phone line is connected through an opto isolator that drives a relay / triac through a transistor whenever ring is detected to switch on a 230V lamp to flash in accordance to ring.</li><li><b>SOLAR POWER CHARGE CONTROLLER:</b> A set of comparators used to drive MOSFETs for bypassing the solar panel power in the event of excess charging. Also providing overload and under battery protection to the load used.</li><li><b>WIRE LOOP BREAKING ALARM SIGNAL:</b> A circuit using transistors to operate a load used to drive the transistor in to saturation while loop breaks to switch on a buzzer.</li><li><b>VIDEO ACTIVATED RELAY TO CONTROL THE LOAD:</b> A circuit using transistors to operate a load whenever a composite video signal from TV is detected at the input.</li><li><b>TOUCH CONTROLLED LOAD SWITCH:</b> A touch sensitive switch with 555 being formed out of a monostable arrangement to switch on relay at output to drive any load.</li><li><b>TIME DELAY BASED RELAY OPERATED LOAD:</b> The 555 timer based circuit switches the load after certain delay (0 to 20 seconds) which is adjustable by the varying resistance in the RC time constant.</li><li><b>Beacon flasher using microcontroller and PWM fed MOSFET:</b> Slow flashing of LED lamps at one second interval for beacon light warning system at sea shores.</li><li><b>Discotheque light stroboscopic flasher:</b> Cluster of high power LED replacing stroboscopic light flasher driven by microcontroller controlled solid state power switch.</li><li><b>Automobile head light lamp intensity dimmer to control glare:</b> 12 volt, 10 watt automobile lamp dimmer by varying pulse width signal.</li><li><b>Password based circuit breaker control to ensure electric line man's safety:</b> Microcontroller based mains circuit breaker ON/OFF arrangement by password controlled such that unauthorized person can never accidentally switch ON the power system for Line man's safety.</li><li><b>Large digit display of dialed telephone numbers for STD billing centers:</b> Dialed telephone numbers are picked up by a DTMF decoder to feed to a micro controller to drive ten numbers seven segment LED displays for better visibility.</li><li><b>FUZZY LOGIC CONTROL for a brushless DC motor to run at the exactly entered speed:</b> Precise speed entered through a numeric key pad interfaced to a micro controller maintains the entered speed of a BLDC motor by sensing shaft mounted IR sensors working on a closed loop circuit by a half bridge ac to Dc circuit comprising 2 SCRs and 2 Diodes .</li><li><b>Hall effect sensor based speed measurement of DC motor:</b> Hall effect controlled microcontroller based non contact type speed measurement system and display.</li><li><b>Three digit preset counter warning system for limit cross operation of industrial loads:</b> A countdown timer with programmable features for meeting industrial load schedule maintenance.</li><li><b>Induction heating by high frequency power output:</b> 25 KHz power generation for a very low impedance coil to work as instant induction heating for medical sterilization applications.</li><li><b>CAN based security system:</b> Message based monitoring tool using the RS232 Rx Tx features of the MC to communicate between 3 Microcontrollers, one for input, one for display and the other for some load in semi CAN protocol.</li><li><b>Password based secured area entry with wrong attempt alarm:</b> Password stored in dedicated EEPROM with I2C protocol by user entry keypad is used to lock or unlock the door, by a motor and an alarm is sounded in case of wrong password attempt.</li><li><b>Time operated motor control with LCD display:</b> Specific timed programmed pump motor operation by microcontroller based RTC, real time clock.</li><li><b>Automatic gate opening system for parking lot:</b> Sonar sensor based microcontroller controlled parking gate opening system for automatic entry at the gate.</li><li><b>Automatic bell system for schools/ colleges:</b> Period over class room bell system for each period using microcontroller and real time clock.</li><li><b>Password based jail chamber gate operation by motor:</b> Numeric keypad interfaced microcontroller to sense exact password for door opening and closing in high security area.</li><li><b>Overload alarm warning system in a passenger lift with number of occupants indication:</b> 2 digit 7 segment LED display of occupants ,driven from microcontroller along with warning system on excess people in a lift.</li><li><b>Temperature warning system for Nuclear plants:</b> Early warning alarm system of temperature rise in Nuclear plants to avoid future disasters.</li><li><b>Automatic washing machine control with manual override:</b> Sequential operation of washing machine having programmable time for each operation and manual also operation alternatively.</li><li><b>TV remote operated curtain closer/opener:</b> Synchronous motor operated either direction movement of curtains remotely by standard TV remotes in commercial complexes.</li><li><b>Auto selection of Fan available from multiple supply sources:</b> Un-interrupted supply to critical cooling fans from any available supply source.</li><li><b>Street light that glows showing the road ahead for ½ km only on sensing vehicles or any movement (Using PIC Microcontroller):</b> Light Emitting Diode (LED) replaces HID lamps by engaging a programmable microcontroller that controls intensity by pulse width modulation which enables energy saving during late nights considering low traffic density. The pulse width becomes very narrow on sensing no movement of vehicles. As the vehicle forwards, the intensity goes on increasing for few lights ahead and as it passes away the intensity goes on falling.</li></ol><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-56594968828812119872011-12-30T03:19:00.001+05:302012-02-20T02:02:53.031+05:30Robotics based projects<ol><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Bomb displacing Robot with tension controlled soft catching arm: </b>A moving robot controlled wirelessly to reach the suspected bomb site to relocate the bomb at different place while handling the same carefully by a soft catching arm duly controlled by interrupt monitored motor to avoid extra pressure on the suspected object for safety reasons.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Bomb-diffusing Robot by RF controlled, laser beam managed hand held unit:</b> In this RF remote control is used to control a robot. A laser beam is actuated after the robot reaches the suspected site on to the object to diffuse the bomb, remotely.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Cell phone operated robotic vehicle: </b>Robotic vehicle that can be operated from any where using cell phone sent commands. Once the contact is established over dialing the cell phone mounted on the robotic vehicle it accepts the tone commands thereafter for the operation of the vehicle.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>War field land Rover that alerts on sensing planted Land Mine ahead:</b> Wirelessly controlled land rover mounted with metal detecting sensors to generate alarms on sensing planted land mine. The movement is wirelessly controlled by a hand held RF transmitter to send commands to the RF receiver mounted on the land rover.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Wireless operated Fire extinguisher vehicles with water jet spray:</b> Fire extinguishing vehicle loaded with water tanker and pump controlled remotely over wireless to throw water jet to the fire. The movement and the pump control are wirelessly controlled by a hand held RF transmitter to send commands to the RF receiver mounted on the fire extinguisher vehicle.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Auto metro train to shuttle between stations:</b> A robotic train with sensors for limiting the number of passengers entering the train by auto door management with auto start and stop run feature from origin to the destination to & fro.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;">Touch screen based remote controlled robotic vehicle for stores management: Hand held touch screen based remote control which transmits RF signal that is received by a robotic vehicle with 3D catching arm to carry out material movement at industries.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Laser beam guided robotic vehicle: </b>A set of sensors mounted on a moving vehicle that automatically adjusts its path following a hand held guided laser beam .</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>War field sage robot that alerts on sensing planted land mine ahead:</b> Remotely controlled robot using RF mode with encoder and decoder duly interfaced to a pair of microcontrollers for movement and metal detection by a metal detector (land mine detector) being actuated after the robot reaches the suspected site.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>A land rover remotely controlled by hand held IR transmitter:</b> It is a Robot that can move through any path by IR control and while it senses the infrared signals from a handheld TV remote. The receiver is interfaced to a microcontroller to drive motors for its movement.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>IR controlled sage robot: </b>Land rover robot that moves by hand held TV remote infrared based ,being driven by a set of 2 motors duly interfaced through motor driver IC.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Line following robotic Vehicle that does not require any microcontroller interface or program: </b>An array of two pair of photo sensors comprising IR transmitter and photo diode fitted in the car to detect a black path as well as any turns in the path. The motors are able to turn the steering left or right, depending on what logic signal the sensor sends.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Cell phone operated sage robot: </b>Digit commands from one cell phone sent to another cell phone mounted on the robot to receive the DTMF (Dual Tone Multi Frequency) mode commands to feed to a microcontroller, to operate 2nos DC motors through motor driver IC for any direction movement.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>War field spying Robot with night vision wireless camera: </b>A RF based moving vehicle mounted with wireless night vision camera controlled remotely over wireless to send real time pictures of enemy activities in war field. The movement is wirelessly controlled by a hand held RF transmitter to send commands to the RF receiver mounted on the moving vehicle.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Line following robotic Vehicle using microcontroller interface: </b>Using IR reflected light falling on photodiodes form as input to IO parts of MC to drive a robotic vehicle motor through motor driver IC in a specified black path by reflection from the white surface and then by disabling any one motor in the event of reflection being stopped while going away from the black path to take turn till the reflection resumes.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Obstacle avoidance robot:</b> Ultrasonic sensor based robotic vehicle that avoids any obstacle and changes its direction as required.</span></li></ol><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-7390877840501555592011-12-30T03:13:00.001+05:302012-02-20T02:03:54.674+05:30Projects for Electrical Branch<div style="text-align: center;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>Electrical/PowerElectronics/</b></span></div><div style="text-align: center;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>Machines/Transmission Lines/PLC/HV projects</b></span></div><div style="text-align: center;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"></div><ol><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>SVPWM Space Vector Pulse Width Modulation: </b>Generating 3 Phase from single phase using 6 nos MOSFETs / IGBTs in 3 phase bridge connected inverter being fed from a DC BUS after being full wave rectified from a single phase 230 v ,50 Hz source. Cost includes a 1HP 3phase motor.</span></li><li><b style="font-family: Arial, Helvetica, sans-serif;">FACTS by SVC ,Flexible AC transmission System: </b><span style="font-family: Arial, Helvetica, sans-serif;">Static VAR Compensation under FACTS using TSC, Thyristor switched capacitors based on shunt compensation duly controlled from a programmed microcontroller.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>WIRELESS POWER TRANSFER:</b> The project is to develop a system of wireless power transfer for pace makers battery charging (An electronic device implanted in body that works in place of a defective heart valve) .Otherwise the patient is required to be operated every year to replace the battery.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>PHASE SEQUENCE CHECKER FOR THREE PHASE SUPPLY: </b>3-ph supply of 440V AC 50Hz is fed to a logic circuit comprising of NAND gates and OR gates to detect the sequence of R Y B by triggering a timer for a LED to indicate output phase out of sequence .</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Sine Pulse Width Modulation (SPWM):</b> Adaptive sine weighted pulse width modulated, 50Hz three phase AC from single phase AC. Cost includes a 1HP 3phase motor.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Four quadrant DC motor speed control with microcontroller:</b> Forward/Reverse rotation and instantaneous Forward Brake and Reverse Brake of DC motor under four quadrant operation.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>UPFC Unified Power Factor Control: </b>Compensation of power factor achieved both for inductive and capacitive circuits automatically from a programmed microcontroller.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>High Voltage DC by Marx Generator Principles: </b>A number of capacitors are charged in parallel by pulsed voltage to V with 50% or less duty cycle from a DC source. The capacitors are automatically then placed in series such that all the V gets added to deliver higher voltage.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Propeller display:</b> Indication of name/time etc using a set of LEDs rotating at high speed to give a virtual display being wirelessly powered.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Four quadrant DC motor speed control without microcontroller:</b>Forward/Reverse rotation and instantaneous Forward Brake and Reverse Brake under four quadrant operation using timer controlled, H bridge fed DC motor.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Induction heating by high frequency power ouput: </b>25 KHz power generation for a very low impedance coil to work as instant induction heating for medical sterilization applications.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Three phase fault analysis with auto reset on temporary fault and permanent trip otherwise: </b>Six numbers of step down transformers used for forming one star and another delta at the output with a set of switches to input LL, LG, 3L fault that triggers a 555 timer in monostable to reset or permanently trip the output relay connected to another 555 timer in astable.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Industrial furnace power control by Integral cycle switching without generating harmonics: </b>Integral cycle control is a method to remove portions of full cycles/one cycle of an AC signal for controlling AC power across AC heater loads interfaced to a programmed microcontroller. This process of power control generates 1% THD as against 61% of firing angle control.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Precise kilometer calculation by underground cable fault detector: </b>Feeding a voltage through a fixed set of resistors representing distance in kilometers and resulting varying current fed to a ADC interfaced to a microcontroller outputs the display in kilometers based on current flow at specific fault created by a set of switches for testing purposes.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Electronic starter with Soft start for smooth operation of 3 phase induction motor: </b>6nos. of SCRs i.e., two in anti parallel in each phase are phase controlled in a similar manner to a light dimmer, where they are gradually turned ON for a part of each cycle to control the voltage by varying the conduction angle of the SCR. By variation of the conduction angle, the output voltage is reduced during start and then smoothly increased to full. Cost includes a 1HP 3 phase motor.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>FUZZY LOGIC CONTROL for a brushless DC motor to run at the exactly entered speed: </b>Precise speed entered through a numeric keypad interfaced to a microcontroller maintains the entered speed of a BLDC motor by sensing shaft mounted IR sensors working on a closed loop circuit by a half bridge AC to DC circuit comprising 2 SCRs and 2 Diodes .</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Detecting power grid synchronization failure on sensing out of range frequency or voltage: </b>Microcontroller based islanding detection for grid connected inverter with under/over voltage and under/over frequency islanding detection algorithms ,where the processed value of voltage and frequency are used for turning ON/OFF the relay between a grid connected inverter and the utility grid.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Low cost Programmable logic control ( PLC) for industrial automation in repetitive nature of work: </b>Objective is designing a microcontroller based programmable time setting by the user through microcontroller architecture loaded with an application program. Switches are provided for set mode, auto mode , manual mode and time change mode. Machine will run ON/OFF sequentially in auto mode in default time settings or set mode time setting or manual mode depending on the user’s need and flexibility.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Ultra fast acting electronic circuit breaker: </b>The project is to shut down the power supply when it is overload. Conventional circuit breaker is based on thermal bimetal lever trip mechanism is very slow and the trip time is dependant upon the percentage of overload. Here the current sensed from a CT is compared against the preset voltage proportional to the current by a level comparator to generate an output for the contactor to trip the load.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>PROGRAMABLE ENERGY AUDITTING EQIPMENT FOR INDUSTRY FOR INSTANEOUS ELECTRICAL LOAD SURVEY: </b>Auto calculation of energy details in a minute ,to indicate the load consumption in units and cost in rupees while the load is assumed to run for specific number of hours, with displays on a 16X2 LCD duly interfaced with the microcontroller.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>MINIMISING PENALITY IN INDUSTRIAL POWER CONSUMPTION BY ENGAGING APFC UNIT: </b>Automatic Power Factor Compensation (APFC) by engaging number of shunt capacitor for inductive loads. The time lag between the zero voltage and zero current are fed to the microcontroller that drives relays at its output for bringing shunt capacitors into the load circuit to get the power factor till it reaches 0.9.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Power saver for industries & commercial establishments:</b>A smart method of lagging current compensation by engaging shunt capacitors automatically as per the requirement.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Lagging and leading power factor display in industrial environment:</b> Display of lagging and leading power factor by measuring the time difference between voltage and the current in AC circuits.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>High voltage dc upto 3kv from AC by using diode and capacitors in ladder network: </b>1000 PIV diodes in combination with 100uF electrolytic capacitors forming a ladder network multiplies the input AC to develop 12 times approximately DC output.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>AUTO SELECTION OF ANY AVAILABLE PHASE, IN 3 PHASE SUPPLY SYSTEM: </b>The project is to provide ac mains supply 230 volt to the single phase load if any of the phases, out of the 3 phases in a house goes missing.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>2 PHASE BLDC MOTOR SPEED CONTROL USING FUZZY LOGIC CONTROL : </b>The Project consists of an input stage, a microcontroller processing stage, and an output stage. The input stage maps sensor to the appropriate membership functions and truth values, processing stage invokes them and the output stage results back into specific control output value.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>A PLD, (PROGRAMMABLE LOGIC DEVICE) BASED BLDC MOTOR OPERATION: </b>The project uses a microcontroller and a EEPROM to store the logic configuration for operation of the motor which is driven by a motor driver IC. The input is set by a set of switches with display.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Automatic Star Delta starter using relays and adjustable electronic timer for induction motor: </b>Star/Delta starters are probably the most common reduced voltage starters in the 50Hz industrial motor world. This project can operate a 3 phase motor at 440 volt AC mains supply 50 Hz with a set of 12 volt DC relays, an electronically adjustable timer and a set of relays, but supplied with six lamps instead of a 3 phase motor.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Bidirectional rotation of an exhaust fan motor with a remote control device: </b>The controller receives the Infrared Signal from the IR remote, the code of which is identified by the receiver that switches on/off the appropriate relay for a split phase induction motor to achieve desired direction, remotely.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Password based circuit breaker control to ensure electric line man's safety: </b>Microcontroller based mains circuit breaker ON/OFF arrangement by password controlled such that unauthorized person can never accidentally switch ON the power system for Line man's safety.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Three step high performance induction motor speed control by Cyclo converter using thyristors: </b>The induction motor is a constant-speed machine. The difficulty of varying its speed economically constitutes one of its main disadvantages which is overcome by using a thyristor controlled cycloconverter that enables the speed to be lowered in steps by Microcontroller triggering a SCR bank of 8nos duly isolated by opto isolators for a F/2 & F/3 achieved by appropriate program. F stands for frequency. Cost of motor included.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Single phase induction motor soft start by stepped delay of reducing firing angle: </b>Charge and discharge of a capacitor at the switch on time and generating a saw tooth voltage is then compared by a comparator to reduce the firing angle from 180 degree to 0 degree progressively to achieve soft start of a induction motor supplied.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Overhead Projector lamp life extender by ZVS (Zero Voltage Switching): </b>Incandescent lamps exhibit very low resistance in cold condition due to which it draws high current while switched on, resulting in fast failure . Engaging two SCRs in anti parallel or a triac the switching on time can be precisely controlled by firing after detecting the zero cross point of the waveform.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Pump motor/lift motor burn out protection: </b>Protecting a 3 phase induction motor from single phasing, and over temperature using sensors interfaced to comparators for disconnecting the motor. Supplied with lamps in place of 3 phase motor.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>300 WATT DOMESTIC USE PWM INVERTER CUM BATTERY CHARGER: </b>PWM technology using Signet SG 3524 for switching from 12 volt battery through a half bridge MOSFET power devices connected to the main inverting transformer that delivers automatically 300 watt 50 Hz power during mains fail and then auto battery charging on mains resume.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Pure Sine Wave UPS using microcontroller to develop adaptive PWM (Pulse Width Modulation) under DSP: </b>Using DSP based program using microcontroller for generating sine wave by 'H' bridge MOSFET bank for 300 watts output with controlled battery charging and auto change over.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>FACTS by TSR, flexible AC transmission System: </b>Static compensation under FACTS using TSR, thyristor switch reactor based on shunt capacitor duly controlled by a microcontroller.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Non contact tachometer: </b>This project uses the IR transmitting and receiving technique by reflection of modulated IR rays from any rotating object such as a motor shaft to send interrupt signal to a programmed microcontroller to enable display of the speed. The display can either be a LCD or simple 7 segment LED type. This becomes a contact less tachometer.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Soft start of 3 phase induction motor by using 2 nos. Back to back scrs in each phase(using lamps only): </b>Understanding soft start of IM by watching the lamps connected in place of the 3 phase motor from low voltage low intensity to full voltage full intensity at the time of start.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Password based jail chamber gate operation by motor: </b>Numeric keypad interfaced microcontroller to sense exact password for door opening and closing in high security area.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>TV remote operated curtain closer/opener: </b>Synchronous motor operated either direction movement of curtains remotely by standard TV remotes in commercial complexes.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Life cycle testing of electrical loads by down counter: </b>A preset able counter with key pad entry that counts down from the set number till it reaches zero with relay operation connected to a load that switches ON & OFF is used for life cycle test of the gadget under test say a lamp to determine its life.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Industrial battery charger with high power DC by thyristor firing angle control: </b>DC power is controlled with zero crossing detectors and sending to the microcontroller to fire thyristors using the opto isolator. The ac power is applied to the bridge rectifier comprising of diodes ,triacs and SCRs to get manually controlled DC at the output.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Super fast solid state relay switching on time analysis on CRO: </b>A three phase solid state relay that incorporates three single phase units where each phase is controlled individually by a power triac with optional snubber network and an optically isolated triac driver. The zero crossing feature of an opto-isolator ensures lower generated noise and avoid sudden inrush currents of load.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>A low cost microcontroller based system high performance AC motor drives: </b>Based on the principle of firing angle control of two thyristors connected in anti parallel is fed for the output to the control circuit. The firing angle would be manually adjusted to maintain the load power in the event of fluctuating AC voltage from high to low and vice versa.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>High power AC lamp flasher for aviation obstruction indication purpose: </b>Aviation obstruction lamp flasher from AC source to warn air crafts for possible crash.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Mixer grinder speed control by using a TV remote: </b>Using a standard TV remote with IR sensors interfaced to a micro controller , reads the coded data from the remote to activate the corresponding output pin to change the time delay for the thyristor firing in 8 steps that drives with varying speed the induction motor.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Auto power supply control from 4 different sources: </b>Solar, Mains, Generator & Inverter to ensure no break power: The main scope of the project is to consume the power from supply mains, generator, and wind power and solar optimally by using appropriate program through microcontroller in most cost effective way.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Control unit designed for a DC motor: </b>The speed of motor is directly proportional to the DC voltage applied across its terminals where the voltage is applied to control motor speed with Pulse Width Modulation wave. Here based on the pulse duty cycle provided by microcontroller the speed of motor is controlled.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>DISH POSITIONING CONTROL BY STEPPER MOTOR /GEARED MOTOR: </b>Programmed microcontroller to enable 180 degree 3D movement of the dish by using a motor for adjustment of the best signal to be received from the satellite.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>MAINS OPERATED LED LIGHT IN STRING: </b>A string of LED’s are made to operate at 230V AC by series capacitor drop and current limit resistor and then being rectified to DC for maintaining a safe operating voltage for the LEDs.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Automobile head light lamp intensity dimmer to control glare: </b>12 volt, 10 watt automobile lamp dimmer by varying pulse width signal.</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Auto selection of Fan available from multiple supply sources: </b>Un-interrupted supply to critical cooling fans from any available supply source<b>.</b></span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Random on/off of lamps to deter burglars for locked houses: </b>Automatic switching On/Off of lamps at random intervals in locked house to deter burglar attempt</span></li><li><span style="font-family: Arial, Helvetica, sans-serif;"><b>Display turn table speed control for shops: </b>Low speed synchronous AC motor with programmed speed control in four steps using microcontroller and thyristor.</span></li><li><b style="font-family: Arial, Helvetica, sans-serif;">Automatic surveillance camera panning system from PC: </b><span style="font-family: Arial, Helvetica, sans-serif;">Using pulse width varying technology so generated by the PC with RS 232 interface through a Micro controller enables the speed control of motor from the PC by a motor driver IC controlled from the microcontroller.</span></li></ol><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-9071432514566456512011-12-30T02:49:00.001+05:302012-02-20T02:05:50.976+05:30Communication based projects<div style="text-align: center;"><b><span style="font-family: Arial, Helvetica, sans-serif;">Communication based projects</span></b></div><div style="text-align: center;"><b><span style="font-family: Arial, Helvetica, sans-serif;">GSM/GPS/Bluetooth/RFID/DTMFMobile/Ethernet/</span></b></div><div style="text-align: center;"><b><span style="font-family: Arial, Helvetica, sans-serif;">RF/XBEE/Networking/Data Acquisition/Smart Card</span></b></div><div style="text-align: center;"><b><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></b></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>1) SCADA ( Supervisory Control and Data Acquisition for remote industrial plant operation: </b>Supervisor sitting on the PC terminal is able to control plant parameters remotely over RS 232 network while monitoring the data acquired through several sensors. The project uses a front end for the control and a backend with microcontroller interfaced to an ADC from temperature sensors for data collection and control.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>2) Synchronized traffic junction signaling (Get green signal all-through at any street junction)-A new concept to ease traffic congestion in metros: </b>All the traffic junctions in a main road are synchronized for signal lighting such that the vehicle gets green signal at all the junctions while moving at a normal speed.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>3) Modern home automation system using intelligent touch screen:</b> A touch screen based transmitting unit is used to manage home lighting system remotely with RF receiver to avoid complicated wiring in existing buildings.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>4) WIRELESS POWER TRANSFER: </b>The project is to develop a system of wireless power transfer for pace makers battery charging (A battery operated electronic device implanted in body that works in place of a defective heart valve) .Otherwise the patient is required to be operated every year to replace the battery.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>5) TOUCH SCREEN BASED INDUSTRIAL AUTOMATION: </b>Touch screen panel managed industrial automation system( or home ) for industrial load control in corrosive / inflammable environment that prohibits use of conventional switches.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>6) SPEED SYNCHRONIZATION OF MULTIPLE MOTORS IN TEXTILE MILLS: </b>Multiple motors used in textile industry, or any other for cloth drawing needs to be synchronized for same speed which is achieved by independent micro controllers for each motor with speed sensing and keypad speed entry for 3 motors supplied to run at same speed .</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>7) MODERN OFFICE MANAGEMENT TOOL FOR SELECTIVE DATA TRANSMISSION TO MULTIPLE USERS: </b>Extremely useful PC based RF communication system in a office from the boss to the subordinates having small LCD display terminals duly interfaced from independent micro controllers to receive message on selective / common to all basis with message receive tone alert.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>8) PC CONTROLLED SCROLLING MESSAGE DISPLAY FOR COLLEGE NOTICE BOARD: </b>Message sent from the PC is transmitted to the notice board over cable ,goes on scrolling in a LCD display in 2 lines until the next message is entered or cancelled.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>9) Wireless networking of dedicated computers: </b>A pair of 2.4Ghz transreceiver modules used for bidirectional communication of data from one PC to another wirelessly.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>10) MULTIPLE SENSOR DATA ACQUISITION: </b>Different type of data acquisition and display on a LCD ,such as voltage, current, temperature, light intensity etc are monitored by a PIC microcontroller having built in multi channel ADC.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>11) RAILWAY TRACK SECURITY SYSTEM: </b>The system detects for breakage /crack in railway tracks using line loop current break to sense the same to send interrupt to the controller to send an SMS to the station master through GSM.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>12) STAMP VALUE CALCULATOR FOR POST OFFICE: </b>Calculating the weight of the letters & value by a balancing arrangement is used to control a potentiometer the output of which is fed to an ADC interfaced to microcontroller having a display.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>13) CAN based security system: </b>Message based monitoring tool using the RS232 Rx Tx features of the MC to communicate between 3 Microcontrollers, one for input, one for display and the other for some load in semi CAN protocol.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>14) Flash Flood intimation over GSM network to the station master: </b>High water level detector interfaced to micro controller that outputs a signal to a GSM modem for sending a signal to the station master to direct the train driver to stop the train.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>15) WIRELESS ELECTRONIC NOTICE BOARD: </b>The microcontroller receives the message from transmitter through GSM interface to be displayed on the LCD at user end interfaced to the microcontroller.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>16) Theft intimation of the vehicle over SMS to owner who can stop the engine remotely: </b>Theft intimation of the vehicle over sms using GSM modem to the owner while unauthorized door entry is made. Owner can send command through his mobile to stop the engine by activating the relay interfaced to a microcontroller along with the GSM modem used for the purpose.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>17) RFID tag based attendance system: </b>RFID tag with details of the employee keep tracking of their attendance while swiped on the RFID reader interfaced to a microcontroller with LCD display for indication.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>18) RFID security access control system: </b>RFID tag reader to read the data present on the tag to compare the same to match the built in data for status display and indication with a lamp.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>19) Precise kilometer calculation by underground cable fault detector:</b> Feeding a voltage through a fixed set of resistors representing distance in kilometers and resulting varying current fed to a ADC interfaced to a micro controller outputs the display in kilometers based on current flow at specific fault created by a set of switches for testing purposes.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>20) A LOW COST LONG RANGE FM TRANSMITTER WITH AUDIO MODULATION: </b>A low cost FM transmitter with audio modulation consisting of 106 MHz oscillator circuit, VFO and RF power amplifier connected to a tuned Yagi antenna to cover about 5 km line of site distance or 1Km by GP antenna.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>21) GSM BASED ENERGY METER BILLING WITH LOAD CONTROL: </b>The project is to develop a wireless energy meter reading and load control. The reading of the energy meter is also sent by to any cell phone by a message through GSM modem which also receives commands from the cell phone to control the electrical loads.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>22) Automatic locking system in case of burglary with intimation to police station: </b>GSM modem interfaced microcontroller based automatic door locking incase of forced action with SMS to the designated police station number.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>23) SMS based intimation and calling over GSM network for emergency assistance: </b>GSM modem interfaced microcontroller based automatic message display incase of forced action with SMS to the designated emergency number.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>24) RFID guided automatic parking permission for vehicles in cellar at commercial complexes: </b>RFID tag swiped by the driver over the RFID reader, enables a motor interfaced through relay being driven by the microcontroller to open the gate for vehicle entry.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>25) GSM based supervisory control and status acquisition of industrial loads:</b> Mobile message sent to another sim loaded GSM modem interfaced to microcontroller to drive relays to control the home appliances with a confirmation upon the status of the load.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>26) RFID based passport details: </b>Identifying the passport holder through data stored in RFID tag by retrieving the same through a reader duly interfaced to the microcontroller by a LCD display.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>27) Password based secured area entry with wrong attempt alarm: </b>Password stored in dedicated EEPROM with I2C protocol by user entry keypad is used to lock or unlock the door, by a motor and an alarm is sounded in case of wrong password attempt.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>28) PC based wireless notice board: </b>Text message from a computer keyboard attached to a microcontroller is encrypted with LCD display to have decrypted message at receiver end all controlled by RF communication.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>29) SPEED CHECKER TO DETECT RASH DRIVING ON HIGHWAYS:</b>The time difference between 2 spots with ,one in advance to the other in the direction of the traffic flow, is fed to a programmed microcontroller to convert the same to the speed of a vehicle and warn if the same exceeds a specified limit by a buzzer sound.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>30) 2 PHASE BLDC MOTOR SPEED CONTROL USING FUZZY LOGIC CONTROL: </b>The Project consists of an input stage, a microcontroller processing stage, and an output stage. The input stage maps sensor to the appropriate membership functions and truth values, processing stage invokes them and the output stage results back into specific control output value.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>31) A PLD, (PROGRAMMABLE LOGIC DEVICE) BASED BLDC MOTOR </b></span><b style="font-family: Arial, Helvetica, sans-serif;">OPERATION: </b><span style="font-family: Arial, Helvetica, sans-serif;">The project uses a microcontroller and a EEPROM to store </span><span style="font-family: Arial, Helvetica, sans-serif;">the logic configuration for operation of the motor which is driven by a </span><span style="font-family: Arial, Helvetica, sans-serif;">motor driver IC. The input is set by a set of switches with display.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>32) Transformer temperature monitoring by wireless to control room: </b></span><span style="font-family: Arial, Helvetica, sans-serif;">Temperature rise of distribution transformer sent over RF on real time</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;">basis to the control room for appropriate action.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>33) Smart card based door security system: </b>Security area authenticated </span><span style="font-family: Arial, Helvetica, sans-serif;">entry system by individual smart card identification and reading system.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>34) Cell phone/landline operated alarm system for help in case of </b></span><b style="font-family: Arial, Helvetica, sans-serif;">emergency: </b><span style="font-family: Arial, Helvetica, sans-serif;">Cell phone controlled microcontroller based assistance </span><span style="font-family: Arial, Helvetica, sans-serif;">system for multiple needs.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>35) WIRELESS AUDIO TRANSMITTER FOR TV: </b>The audio output of the TV is </span><span style="font-family: Arial, Helvetica, sans-serif;">fed to an FM transmitter that transmits the audio to be received by any </span><span style="font-family: Arial, Helvetica, sans-serif;">FM receiver (or a cell phone having FM radio).It can be used to listen to </span><span style="font-family: Arial, Helvetica, sans-serif;">TV sound without disturbing any one else.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>36) HOME AUTOMATION USING DIGITAL CONTROL: </b>A circuit interfaced to </span><span style="font-family: Arial, Helvetica, sans-serif;">a land line telephone is used to control ON OFF of home / office load </span><span style="font-family: Arial, Helvetica, sans-serif;">remotely using DTMF technology but without using any microcontroller </span><span style="font-family: Arial, Helvetica, sans-serif;">or any program.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>37) RF based home Automation system:</b> Using RF technology several loads in home or office to be controlled for optimum use of energy remotely.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>38) Vehicle theft intimation to the owner on his cell phone by GSM(Using PIC Microcontroller): </b>Theft intimation of the vehicle over SMS using GSM modem to the owner while unauthorized door entry is made. Owner can send command through mobile to stop the engine whose ignition is disabled through a relay fed from the microcontroller which gets command from the GSM modem.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>39) RFID based device control & authentication(Using PIC Microcontroller): </b>RFID card swiped over the card reader by the vehicle driver enables the motor interfaced through the driver IC to the controller to open the gate for vehicle entry .</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>40) Password protected bank locker system with intimation to the owner through cell phone/landline: </b>User Programmable telephone number storing by keypad entry enabling auto dial to the person concerned in the event of robbery.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>41) PC based light intensity control: </b>Serial port controlled PWM based light intensity monitoring system from PC.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>42) Integrated energy management system based on GSM protocol and acknowledgement features: </b>An SMS sent through the cell phone to a distant location GSM modem for any load interfaced from a micro controller through relay and relay driver to switch ON and switch OFF the same with acknowledgement sent back to the sender on SMS upon the action taken and the status of the load.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>43) Smart phone based touch controlled garage door opening system: </b>Data so generated by any smart cell phone is received by a decoder IC interfaced to a microcontroller that outputs a relay for door open/lock operation.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>44) Large digit display of dialed telephone numbers for STD billing centers: </b>Dialed telephone numbers are picked up by a DTMF decoder to feed to a microcontroller to drive ten numbers seven segment LED displays for better visibility.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>45) Automatic Dialing to any telephone using I2C protocol on detecting burglary:</b> User Programmable telephone number storing by key pad entry enabling auto dial to the police station or the person concerned in the event of robbery.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>46) User programmable password based hotel room door lock: </b>The microcontroller based Door locker is an access control system that allows only authorized persons to access a restricted area. The password is stored in another dedicated EEPROM which can be changed at any time unlike a fixed one burnt permanently on to the microcontroller.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>47) Portable Programmable Medication Reminder: </b>The project takes care of reminder need of people who forget to take medicines in time. Key pad entry stores the relevant information in an EEPROM with several timings based on a RTC. At the programmed time the message for the medicine is displayed over a 16 digit LCD display together with a buzzer sound to alert the person for taking the appropriate medicine.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>48) Tampered energy meter monitoring conveyed to control room by wireless communication: </b>The main scope of this project is to send message from any tampered energy meter to be received by the control room by means of GSM communication. A message is sent to the number stored in microcontroller to alert the tampering of the meter.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>49) Military use coded communication system with LCD display:</b> The aim of the project is to send encrypted text message transmitted through RF by using Microcontroller and received at receiver which is decrypted by another Micro Controller where message is displayed over the LCD display. Transmitter gets data from a standard computer keyboard and encrypts with a private algorithm. At receiver end the Microcontroller decrypts it with the same algorithm and displays the data on LCD.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>50) PC managed, advanced home automation system: </b>External electrical load applications controlled with the help of PC. PC is connected to microcontroller through MAX 232 level shifter, ULN (Driver) is used to drive the relays for connecting to external devices. DB (RS-232) connector is used to connect to PC com port.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>51) Authorized operator to access the machine by Smart card: </b>The project is developed to identify authorized personnel with ID cards , where a module is provided to read the ID number from card. Whenever card ID number in the card is matched with the inbuilt ID number in the code then LCD display would indicate that the card being accepted with a relay used to actuate the load.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>52) Automatic Wireless health monitoring system in hospitals for patients: </b>Monitoring patient health remotely in hospitals over wireless from the patient bed to the doctor’s chamber by RF with LCD display at both ends and optionally an alarm on critical situation.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>53) Four telephones in parallel but still accessed by only one user at a time to maintain secrecy: </b>This Project can be used in houses and offices in which more than one telephone is connected in parallel from a single telephone line. The project is used to connect a maximum of four telephones in parallel. When any one of the phone is lifted, all the other lines are disconnected from the telephone line.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>54) MODERN VEHICLE SYSTEM MANAGEMENT in semi CAN, Control Area Network. Three microcontrollers communicating with each other over pair of wire: </b>As the number of microcontrollers embedded in a product increases the solution for communication among them is preferred serially. The paper describes a message based monitoring tool using the RS232 Rx Tx bus features of the MC to communicate between 3 MCs.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>55) Using TV remote as a cordless mouse for the Computer: </b>A typical TV remote sends coded infrared data that is read by a sensor which is then burnt to a microcontroller the output of which shall drive desired operation through serial port connection as conventionally performed by the PC Mouse.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>56) Human sensed automatic door opening system:</b> Automatic door opening by sensing any approaching human being by piro IR sensors interfaced to a programmed microcontroller that drives a motor through motor driver IC with locked rotor protection system for door operation.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>57) Railway level crossing gate control through SMS by the station master or the driver: </b>Railway level crossing gate motor ,controlled by the station master or the engine driver through GSM modem interfaced to microcontroller for deriving an output to dive a relay for the gate motor operation.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>58) GSM based monthly Electricity energy meter billing with SMS and display to the user: </b>Domestic electricity consumed is displayed in rupee terms on daily and monthly basics to the user and billing details sent over GSM network form the user to the department for generating the printed bill..</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>59) DTMF based remote industrial load and/or agricultural pump control: </b>The main scope of this project is to send digit commands from one cell phone to be received by another cell phone to receive the tone mode commands which are then DTMF (Dual Tone Multi Frequency) decoded. The receiving cell phone codes are then fed to a microcontroller which is programmed to recognize those codes for operating any kind of load duly interfaced through relay drivers and relays (or motor driver and motor) as per the sent command from sender’s mobile.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>60) Automatic surveillance camera panning system from PC: </b>Using pulse width varying technology so generated by the PC with RS 232 interface through a Microcontroller enables the speed control of motor from the PC by a motor driver IC controlled from the microcontroller.</span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b><br /></b></span></div><div style="text-align: left;"><span style="font-family: Arial, Helvetica, sans-serif;"><b>61) Cell phone /landline based circuit breaker: </b>Remote controlled, password based circuit breaker for industrial load protection.</span></div><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com1tag:blogger.com,1999:blog-38587382501777330.post-89304872891377043962011-12-30T02:17:00.002+05:302012-02-20T02:06:07.927+05:30Live Projects for Industrial Application<span style="font-family: Arial, Helvetica, sans-serif;"><b>1) Remote speed control by Thyristor trigger angle change with display of delayed firing angle: </b>Using a standard TV remote with IR sensors interfaced to a micro controller, reads the coded data from the remote to activate the corresponding output pin to change the time delay for the thyristor firing in 8 steps that drives with varying speed the induction motor.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>2) </b> <b>Ultra fast acting electronic circuit breaker: </b>The project is to shut down the power supply when it is overloaded. Conventional circuit breaker is based on thermal bimetal lever trip mechanism is very slow and the trip time is dependent upon the percentage of overload. Here the current sensed from a CT is compared against the preset voltage proportional to the current by a level comparator to generate an output for the contactor to the trip load.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>3) Automatic irrigation system on sensing soil moisture content: </b>The circuit comprises of sensor parts built using op-amp and are configured here as a comparator. two stiff copper wires are inserted in the soil to sense whether it is dry. The micro controller turns the motor ON and OFF based on sensors condition that is dry or wet respectively. Sensor signals are operated with the control of software that is stored in ROM of MC.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>4) Automatic Wireless health monitoring system in hospitals for patients: </b>Monitoring patient health remotely in hospitals over wireless from the patient bed to the doctor’s chamber by RF with LCD display at both ends and optionally an alarm on critical situation.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>5) Precise temperature control for incubators used in hospitals for the pre born child growth: </b>Micro controller observes temperature readings taken from display unit and compares with the keypad programmed temperature value to control the heater (ON/OFF). Here the controller continuously polls the temperature with certain regular time intervals and displays over the 7_segment display unit for the Micro controller to enable the whole operation by executing the program.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>6) Office automation system for optimum energy management:</b> This application keeps the database of the number of persons entering as well as exiting. LED's being interrupted on to the IR receiver to sense the person entering as well as exiting. This signal is fed to AT89C51 micro controller for load control purpose with LCD displays on the number of persons in and out with optimum energy use.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>7) Authorized operator to access the machine by Smart card:</b> The project is developed to identify authorized personnel with ID cards , where a module is provided to read the ID number from card. Whenever card ID number in the card is matched with the inbuilt ID number in the code then LCD display would indicate that the card being accepted with a relay used to actuate the load.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>8) PC managed, advanced home automation system:</b> External electrical load applications controlled with the help of PC. PC is connected to micro controller through MAX 232 level shifter, ULN (Driver) is used to drive the relays for connecting to external devices. DB (RS-232) connector is used to connect to PC com port.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>9) Military use coded communication system with LCD display: </b>The aim of the project is to send encrypted text message transmitted through RF by using Micro controller and received at receiver which is decrypted by another Micro Controller where message is displayed over the LCD display. Transmitter gets data from a standard computer keyboard and encrypts with a private algorithm. At receiver end the Micro controller decrypts it with the same algorithm and displays the data on LCD.</span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"><b>10) Bomb-diffusing Robot by RF controlled, laser beam managed hand held unit:</b> In this RF remote control is used to control a robot. A laser beam is actuated after the robot reaches the suspected site on to the object to diffuse the bomb, remotely.</span><br /><script>var _wau = _wau || []; _wau.push(["tab", "nwb36yrn8vlq", "gwh", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com0tag:blogger.com,1999:blog-38587382501777330.post-5343259111568679952011-12-24T01:28:00.003+05:302012-03-04T17:29:35.526+05:30Edge and Crack Detector<div style="text-align: center;"><span style="font-family: Arial, Helvetica, sans-serif; font-size: 16px; text-align: left; ">This is a Automated Robot, which senses the cracks and edges over the surface where it's</span><span style="font-family: Arial, Helvetica, sans-serif; text-align: left; font-size: large; "></span><span style="font-family: Arial, Helvetica, sans-serif; font-size: 16px; text-align: left; ">Running, for sensing such surfaces it requires a sensing device, which is provided by IR sensor (Transmitter as well as receiver) which is connected with LM324A which is a set of Operational Amplifier as four op-amp are connected in this IC, using 1 IC is more effective than using 2 IC, thus it prefers the most, the IC looks like as shown below: -</span></div><div style="font-variant: normal; line-height: normal; "><br /></div><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiz-E_KLk8zePRHY_tt9W583SKYzaTPGMg3bnJDIz6PRICXyBpOPh_prPT65Td9ADIpJ0wfCORFsAPpf7oWyzkO14x2SD5afHuwEmB35WXzu8ZNSy_jiECmLqA3yphLROMzwFcS5ZJVMuM/s1600/Photo0222.jpg" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; "><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 240px;" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiz-E_KLk8zePRHY_tt9W583SKYzaTPGMg3bnJDIz6PRICXyBpOPh_prPT65Td9ADIpJ0wfCORFsAPpf7oWyzkO14x2SD5afHuwEmB35WXzu8ZNSy_jiECmLqA3yphLROMzwFcS5ZJVMuM/s320/Photo0222.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5716008126523392930" /></a><br /><div style="font-variant: normal; line-height: normal; font-family: Georgia, serif; text-align: center; "><span style="font-family: Arial, Helvetica, sans-serif; font-size: 100%; text-align: left; ">and the output from sensors given to the IC LM324A where the signals have been Amplified, it is required because when weaker signals are identified then it gets amplified through LM324, then Output from LM324 is given to Micro-Controller which works as a Brain for Robot which is controlled through the Program.</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; text-align: left; "><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></div><div class="separator" style="font-variant: normal; line-height: normal; text-align: left; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif; font-size: 100%; ">Now whole Circuit has been connected as shown in figure below: -</span></div><br /><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXwct5yFAoDEAyqu5obEHgy_z4z59RS5xw8K_2qoxRfSJl1WtMpc-kAkaZSGJD2oFXdOpGO_X-rZxZ0z_KT8E2TfBa5UTJ3e9auITr9qTZnFTNwZ_pOPX5r6IU68BkCC1_3sMQ8sfvRTI/s1600/Photo0221.jpg"><img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXwct5yFAoDEAyqu5obEHgy_z4z59RS5xw8K_2qoxRfSJl1WtMpc-kAkaZSGJD2oFXdOpGO_X-rZxZ0z_KT8E2TfBa5UTJ3e9auITr9qTZnFTNwZ_pOPX5r6IU68BkCC1_3sMQ8sfvRTI/s320/Photo0221.jpg" border="0" alt="" id="BLOGGER_PHOTO_ID_5716009488220989266" style="display: block; margin-top: 0px; margin-right: auto; margin-bottom: 10px; margin-left: auto; text-align: center; cursor: pointer; width: 320px; height: 240px; " /></a><br class="Apple-interchange-newline"><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; text-align: center; "><br /></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; text-align: left; "><span style="font-family: Arial, Helvetica, sans-serif; font-size: large;"><b><i>C Program Code: -</i></b></span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; text-align: left; "><span style="font-family: Arial, Helvetica, sans-serif; font-size: 100%; "><br /></span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; text-align: left; "><span style="font-family: Arial, Helvetica, sans-serif; font-size: 100%; ">#include <stdio.h></span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">#include <8051.h> </span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">void delay (int time)</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">int i,j;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">for (i=0;i<=10;i++)</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">for (j=0;j<=10*time;j++)</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}}}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">void moveforward( )</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P1=0x06;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">delay(2);</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P1=0x00;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">delay(2);</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">void turnright( )</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P1=0x0A;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">delay(2);</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P1=0x00;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">delay(2);</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">void turnleft( )</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P1=0x05;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">delay(2);</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P1=0x00;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">delay(2);</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">void main()</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P1=0xff;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">P0=0xff;</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">delay(10);</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">while (1)</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">if ((P0_0==1) && (P0_1==1))</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">moveforward();</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">if ((P0_0==0) && (P0_1==1))</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">turnright();</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">if ((P0_0==1) && (P0_1==0))</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">turnleft();</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">if ((P0_0==0) && (P0_1==0))</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">{</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">turnright();</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; "><span style="font-family: Arial, Helvetica, sans-serif;">}</span></div><div><br /></div><div style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; text-align: left; "><span style="font-family: Arial, Helvetica, sans-serif;">Now the project under working condition look likes: -</span></div><div style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; text-align: left; "><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></div><div class="separator" style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; clear: both; text-align: center; "><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.blogger.com/video.g?token=AD6v5dwBMB2oj4bhk6fxxVML-RJopplpP1iwaKNGieenubu7wTZ9yn4KMMXBnIQKUM6fvY2rGNhX8NiHFASn0tLU' class='b-hbp-video b-uploaded' frameborder='0'></iframe></div><div style="font-variant: normal; line-height: normal; font-family: Georgia, serif; font-style: normal; font-weight: normal; font-size: 100%; text-align: left; "><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span></div><script>var _wau = _wau || []; _wau.push(["tab", "edetgr537ji0", "rcv", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com1tag:blogger.com,1999:blog-38587382501777330.post-51674565484897022992011-12-22T01:11:00.003+05:302012-02-20T01:55:08.247+05:30Micro-Controller Based Password Controller for Home Appliances<div dir="ltr" style="text-align: left;" trbidi="on"><div style="text-align: center;"><b><i><span style="color: red; font-size: large;">Micro-Controller Based Password Controller for Home Appliances</span></i></b></div><b><i><span style="color: red; font-size: large;"><br /></span></i></b><br /><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9ZfAZTrLspDf-K3511nC_A9CB7eUziWZmD44vCYOomrX4Y8a-zmk3I3qiIyX7cP3ybmhaJDckCcTwhNylNuqHMNuX4SpVaoRGRv0GZmEugVntT6_RRzHto_NgfbcwN7b-DpQEHtyL0ZI/s1600-h/project.JPG" style="background-color: white; clear: left; color: #861b8f; float: left; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; margin-bottom: 1em; margin-right: 1em; outline-color: initial; outline-style: none; outline-width: initial;"><img alt="" border="0" height="324" id="BLOGGER_PHOTO_ID_5380122841647374434" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9ZfAZTrLspDf-K3511nC_A9CB7eUziWZmD44vCYOomrX4Y8a-zmk3I3qiIyX7cP3ybmhaJDckCcTwhNylNuqHMNuX4SpVaoRGRv0GZmEugVntT6_RRzHto_NgfbcwN7b-DpQEHtyL0ZI/s400/project.JPG" style="float: left; margin-bottom: 10px; margin-left: 0px; margin-right: 10px; margin-top: 0px;" width="400" /></a><br /><div style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">Security is our Prime concern in our day-to-day life. Everyone wants to be as much</div><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">secure as possible. An access control for any appliances forms a vital link in a security chain. </span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">The microcontroller based light is an access control system that allows only</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">authorized persons to access restricted devices.</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">Present project deals with the activation of the power supply of an electric bulb.</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">The system is fully controlled by </span><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">the 8 bit microcontroller P89V51RD2 which has a</span><br /><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">flash for the program memory</span><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">.</span><br /><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></span><br /><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></span><br /><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></span><br /><br /><div style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></div><div style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></div><div style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;">The password is stored in the flash memory.</div><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">The system has a Keypad by which the password can be entered through it. The user</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">entered password is compared with the password in the flash memory. When the entered</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">password matches with the password stored in the memory then the relay gets activated,</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">LCD displays as “ACCESS GRANTED” and the bulb glows. If the password entered is</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">wrong then the LCD displays that “ACCESS DENIED”. The same password is then used to</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">off the bulb.</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">The system uses 16*2 alphanumeric LCD that displays the password in a secure way</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">entered using the keypad of 4*3 push button switches. The total circuit enhances the user toprovide a secured operation. </span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">The application can be used with various appliances like door lock system, alarm systems etc. The security provides an advance feature for the present home automation</span><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"> industry.</span><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><br style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><a href="http://www.mediafire.com/?zxozifgyzqa" style="background-color: white; color: #861b8f; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; outline-color: initial; outline-style: none; outline-width: initial; text-decoration: none;"><span style="font-family: Verdana; font-size: 20px;">DOWNLOAD</span></a> </div><script>var _wau = _wau || []; _wau.push(["tab", "edetgr537ji0", "rcv", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com2tag:blogger.com,1999:blog-38587382501777330.post-8656723359650299442011-12-22T00:29:00.002+05:302012-02-20T01:50:42.252+05:30LCD CLOCK USING 8051 (89s51) Microcontroller<div dir="ltr" style="text-align: left;" trbidi="on"><br /><h3 class="post-title entry-title" style="font-family: Verdana, Arial, Helvetica, sans-serif; line-height: 17px; text-align: justify;"><i><u><span style="background-color: #cccccc; color: blue; font-size: large;">LCD CLOCK USING 8051 (89S51) Microcontroller</span></u></i></h3><div><i><u><span style="background-color: #cccccc; color: blue; font-size: large;"><br /></span></u></i></div><div><span style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 14px; line-height: 19px;">This is a real time clock</span><span style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 14px; line-height: 19px;"> by using 89c51 micro-controller, clock's data format is hour:min:sec, and it is displayed on 16x2 LCD</span><span style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 14px; line-height: 19px;">, the code has been tested and compilled on Keil uVision compiler</span><span style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 14px; line-height: 19px;">, circuit diagram</span><span style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 14px; line-height: 19px;"> for the project is shown below.</span> </div><div><span style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 14px; line-height: 19px;"><br /></span></div><div><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgBAieCQVTuNWPcJmALrrmADFR5oFIuu5UINA5kdShThOt2I-qb76Zxim39e2nh0CjTGQ2JB0pVgPiXo6ifreTQPyeAh69cjz9UpMmiSnBUdfFs1P6dZJjIdJ5Ak2KPXg23KuBlxSxywGY/s1600/clock.JPG" imageanchor="1" style="background-color: white; color: #861b8f; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; margin-left: 1em; margin-right: 1em; outline-color: initial; outline-style: none; outline-width: initial; text-align: center; text-decoration: none;"><img border="0" height="305" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgBAieCQVTuNWPcJmALrrmADFR5oFIuu5UINA5kdShThOt2I-qb76Zxim39e2nh0CjTGQ2JB0pVgPiXo6ifreTQPyeAh69cjz9UpMmiSnBUdfFs1P6dZJjIdJ5Ak2KPXg23KuBlxSxywGY/s400/clock.JPG" style="-webkit-box-shadow: rgba(0, 0, 0, 0.199219) 0px 0px 0px; background-attachment: initial; background-clip: initial; background-color: #222222; background-image: initial; background-origin: initial; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-bottom-style: solid; border-color: initial; border-left-color: transparent; border-left-style: solid; border-right-color: transparent; border-right-style: solid; border-top-color: transparent; border-top-left-radius: 0px; border-top-right-radius: 0px; border-top-style: solid; border-width: initial; box-shadow: rgba(0, 0, 0, 0.199219) 0px 0px 0px; padding-bottom: 8px; padding-left: 8px; padding-right: 8px; padding-top: 8px; position: relative;" width="400" /></a> </div><div><br /></div><div><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">Lcd is connected with port 2 and some pins of port 3 of 89c51 uController.</span><br /><br /><b style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><u>C Code :</u></b><br /><br /><span style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;">#include </span><at89x52.h style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px;"><br />#define MAXCOUNT 20 <br />#define HOUR 3<br />#define MIN 6<br />#define SEC 9<br /><br />sbit RS=P3^3; //RS=0; command register RS=1; Data register<br />sbit RW=P3^4;<br />sbit E=P3^5;<br />sbit BF=P2^7;<br /><br />bit time_keeping;<br />bit setmode;<br /><br />bit packetok;<br />bit secflag;<br />bit minflag;<br />bit hourflag;<br /><br />unsigned char data count;<br />unsigned char data hour;<br />unsigned char data hourT;<br />unsigned char data hourU;<br />unsigned char data min;<br />unsigned char data minT;<br />unsigned char data minU;<br />unsigned char data sec;<br />unsigned char data secT;<br />unsigned char data secU;<br />unsigned char data curfield;<br /><br /><br />unsigned char data curstate;<br />unsigned char data Debounce;<br />unsigned char data decrease;<br /><br />//////////////////////////// DELAY/////////////////////////////<br /><br />void delay(unsigned char z) //For delay (Starts)<br /> {<br /> unsigned char x;<br /> unsigned int y;<br /> for(x=0;x<z;x++){ for="" br="" of="" start="" the=""> for(y=0;y<=1000;y++);<br /> }<br /> }<br /><br />///////////////////////////////// LCD CURSOR POSITION//////////////<br /><br />void setcurpos(unsigned char pos)<br /> {<br /> pos = pos + 0x80;<br /> E=1; //Start LCD command<br /> RS=0; //Its a command.<br /> RW=0;<br /> P2=pos; <br /> E=0; //Finish LCD command<br /> }<br /><br />////////////////////////////// LCD PULSE//////////////////////////<br /><br />void LCD_Pulse_E(unsigned char t)<br /> {<br /> unsigned char i;<br /> E = 1; for(i=0; i<t; e="" from="" high="" i="i;//For" br="" to=""> E = 0; for(i=0; i<t; i="i;<br"> }<br /><br />//////////////////////////// READY/////////////////////////////<br /><br />bit ready(void) //For checking that the LCD is ready or not?<br /> {<br /> BF=1;//Busy flag is one<br /> RS=0;// Command register is one<br /> RW=1;//Read the data from LCD<br /> while(BF==1)<br /> {<br /> E=0;<br /> E=1;<br /> }<br /> return 1;<br /> }<br /><br />///////////////////////////////// LCD SHOW///////////////////////<br /><br />void LCD_Show(unsigned char CHARACTER)<br /> {<br /> if(ready())<br /> {<br /> P2=CHARACTER;<br /> RS=1; delay(1);//Data register<br /> RW=0; delay(1);//Write on LCD<br /> LCD_Pulse_E(255);<br /> delay(1);<br /> }<br /> }<br /><br /><br /><br /><br /><br />/////////////////////////// LCD RUN/////////////////////////<br /><br />void LCD_Run_Command(unsigned char COMMAND)<br /> {<br /> if(ready())<br /> {<br /> P2=COMMAND;<br /> RS=0; delay(1);//command register<br /> RW=0; delay(1);//read from LCD<br /> LCD_Pulse_E(255);//call to LCD_PULSE_E() function<br /> }<br /> }<br /><br /><br />/////////////////////////////////// CMD ARRAY///////////////////<br /><br />bit Cmd_Array(unsigned char cmd)<br /> {<br /> if(cmd)<br /> {<br /> return 1;<br /> }<br /> else<br /> return 0;<br />}<br /><br />////////////////////////////////// TIMER 0 ISR/////////////////<br />void timer0ISR(void) interrupt 1 using 1<br />{<br /><br /> TR0=0;<br /> TH0 = 0x4B;<br /> TL0 = 0xFF;<br /> TR0 = 1; <br /><br /> count++;<br /> if(count == MAXCOUNT)<br /> {<br /> count = 0;<br /> sec++;<br /> time_keeping = 1;<br /> secflag = 1;<br /> if(sec == 60)<br /> {<br /> sec = 0;<br /> min++;<br /> minflag=1;<br /> if(min==60)<br /> {<br /> min=0;<br /> hour++;<br /> hourflag=1;<br /> if(hour==24)<br /> {<br /> hour=0;<br /> }<br /> }<br /> }<br /> }<br /> <br />}<br /><br /><br />///////////////////////////////////// THE MAIN ///////////////////////////////<br /><br />void main(void)<br />{ <br /> setmode=0;<br /> count=0; //initialization<br /> sec=0;<br /> min=0;<br /> hour=0;<br /><br /> curstate = 0;<br /><br /> setcurpos(5);<br /> LCD_Show(':');<br /> setcurpos(8);<br /> LCD_Show(':');<br /><br /> SCON=0x50;<br /> TH1=0xFD;<br /> ES = 1;<br /> TMOD = 0x21;<br /> TH0=0x4B; <br /> TL0=0xFF;<br /><br /> ET0=1;<br /> EA=1; <br /><br /> TR0=1;<br /> TR1=1;<br /><br />LCD_Run_Command(0x0C); // Display=ON, Curson=OFF, Cursor Blonking=ON<br /><br />while(1)<br />{<br /><br /> if(time_keeping)<br /> { <br /> setcurpos(SEC);<br /> LCD_Show(secT+0x30);<br /> LCD_Show(secU+0x30);<br /> setcurpos(HOUR);<br /> LCD_Show(hourT+0x30);<br /> LCD_Show(hourU+0x30);<br /> setcurpos(MIN);<br /> LCD_Show(minT+0x30);<br /> LCD_Show(minU+0x30);<br /> if(hourflag)<br /> {<br /> hourflag=0; <br /> hourT=hour/10;<br /> hourU=hour%10;<br /> <br /> }<br /> <br /> if(minflag)<br /> {<br /> minflag=0;<br /> minT=min/10;<br /> minU=min%10;<br /> <br /> }<br /> if(secflag)<br /> {<br /> secflag=0;<br /> secT=sec/10;<br /> secU=sec%10;<br /> <br /> }<br /><br /><br /> }<br />}<br />}</t;></t;></z;x++){></at89x52.h> </div></div><script>var _wau = _wau || []; _wau.push(["tab", "edetgr537ji0", "rcv", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com1tag:blogger.com,1999:blog-38587382501777330.post-18339817869676585592011-12-21T23:10:00.002+05:302012-02-20T01:49:55.470+05:30Simple Home Alarm Project<div dir="ltr" style="text-align: left;" trbidi="on"><br /><h3 class="post-title entry-title" style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; line-height: 17px; text-align: center;"><i><u><span style="color: blue; font-size: large;">Simple Home Alarm Project</span></u></i></h3><div><i><u><span style="color: blue; font-size: large;"><br /></span></u></i></div><div><div style="background-color: white; clear: right; float: right; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; margin-bottom: 1em; margin-left: 1em; text-align: justify;"><img alt="" border="0" height="157" src="http://www.electronics-project-design.com/images/smokealarm.jpg" width="201" /> </div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; text-align: justify;">This simple standalone home alarm project is a good project for those who are eager to know the concept of home security system. This circuit which consists of three 555 timers gets the input from a contact that could be connected to a <span style="color: #cc0000;">motion detector</span> or any momentary contact that monitors a certain process. Once the contact is momentarily closed, the first timer which is configured as a monostable output will output a high pulse with a duration up to a maximum of 220 seconds.</div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; text-align: justify;"><br /></div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; text-align: justify;">This output is fed into the second timer which is configured as an astable 1Hz square wave generator. The output of this second timer is then fed into the third timer to control its frequency modulation. This frequency modulation will then power a <span7830837><span style="color: magenta;">speaker</span></span7830837> and generate a siren tone similar to the police siren.</div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; text-align: justify;"><br /></div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; line-height: 17px; text-align: justify;"><b style="text-align: left;"><div style="text-align: center;"><span class="Apple-style-span" style="font-family: 'Times New Roman'; font-weight: normal;"><b style="font-family: Verdana, Geneva, sans-serif;"><i><u><span style="color: blue; font-size: large;">Home Alarm Schematic Diagram</span></u></i></b></span></div></b><br style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: left;"><div style="font-size: 13px;">The <span7830837><a href="http://serw.clicksor.com/newServing/go.php?nid=1&cpx=cpc&uid=20524074280174&pid=188100&sid=296249&spid=0&kw=schematic&af=0&rf=2&curl=http%3A%2F%2Fmeta.7search.com%2Fclick%2Fclick.aspx%3Fx%3DjBAP7NpFM4bzXp1Ldl1LOQ%253d%253d_UmWvw7Wsyz8rs4YlilCZnbE2%252b6hyQQajtM5p3k7oUhYxgaDxuoP6TIvdy6W9Y5hxiaDpnerJ%252bV8NuUXuHnMR7rIWiQPnk%252fZjRSoIZYA0pZ14g64PinJTS2%252fulpl9%252b9vA%252bYmYVdz0YUK%252fHV8KEml9iFapdCAR%252bfv0z0CqdaegjS5lm%252f4B0Su8RW3q9nEiqPzt" id="Y7830837S2" style="color: #f200d0; outline-color: initial; outline-style: none; outline-width: initial;" target="_blank">schematic</a></span7830837> of the project is as shown below.</div></div></div><div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; text-align: center;"><img alt="" border="0" height="395" src="http://www.electronics-project-design.com/images/homealarmschematic.gif" width="405" /></div><div style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></div><div style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></div><div style="background-color: white; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 17px; text-align: justify;"><br /></div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; text-align: center;"><img alt="" border="0" height="353" src="http://www.electronics-project-design.com/images/alarmschematic.gif" width="484" /></div></div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; font-size: 13px; line-height: 17px; text-align: center;"><br /></div><div style="background-color: white; font-family: Verdana, Geneva, sans-serif; line-height: 17px; text-align: center;"><div style="font-size: 13px; text-align: justify;">The first timer U1 is configured as a monostable timer with a variable timing of up to a maximum of 220 seconds. The timing can be changed by adjusting the VR1 1M ohm potentiometer. If you need to further increase the timing, the electrolytic capacitor E1 can be changed to a larger value. Once the contact CT is momentarily closed, a pulse will be generated at the output pin 3 of U1.</div><div style="font-size: 13px; text-align: justify;">U1 is then feed into pin 4 RESET of both U2 and U3 timers causing both timers to start their astable mode operations. U2 is configured as a square wave close to 1 Hz astable oscillator by fixing the values of E3, R2 and R3.</div><div style="font-size: 13px; text-align: justify;"><br /></div><div style="font-size: 13px; text-align: left;"></div><div style="font-size: 13px; text-align: justify;">f = 1.44/[(R2 + 2R3)(E3)]</div><div style="font-size: 13px; text-align: justify;">= 1.44/[(10 + 2*82)(10)] Hz</div><br style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: left;"><div style="font-size: 13px; text-align: justify;">= 0.8 Hz</div><div style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: justify;"><span class="Apple-style-span" style="font-family: Verdana, Geneva, sans-serif; font-size: 13px;"><br /></span></div><br style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: left;"><div style="font-size: 13px; text-align: left;"></div><div style="font-size: 13px; text-align: justify;">The output of U2 timer is used to feed the control voltage of the U3 timer through resistor R6 where it is subjected to frequency modulation. This frequency modulation will generate a tone similar to the police siren. The frequency of this tone generator can be varied by changing the value of potentiometer VR2. When set to its maximum value of 220k ohm, it will have a tone frequency of approximately 320 Hz. The output of U2 is used to drive a power transistor which in turn drive an 8 ohm speaker. Diode D2 is used to prevent the damage of transistor Q1 due to the back emf generated by the speaker during the ON/OFF driving of the speaker.</div><div style="font-size: 13px; text-align: left;"></div><br style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: left;"><div style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: justify;"><span class="Apple-style-span" style="font-family: Verdana, Geneva, sans-serif; font-size: 13px;"><br /></span></div><div style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: justify;"><br /></div><b style="text-align: left;"><div style="text-align: center;"><span class="Apple-style-span" style="font-family: 'Times New Roman'; font-weight: normal;"><b style="font-family: Verdana, Geneva, sans-serif;"><i><u><span style="color: blue; font-size: large;">HOME ALARM SYSTEM List</span></u></i></b></span></div></b><div style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: justify;"><br /></div><br style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align: left;"><div style="font-size: 13px;"><img alt="" border="0" height="348" src="http://www.electronics-project-design.com/images/homealarmpartslist.gif" width="374" /></div></div></div><script>var _wau = _wau || []; _wau.push(["tab", "edetgr537ji0", "rcv", "right-middle"]);(function() { var s=document.createElement("script"); s.async=true; s.src="http://widgets.amung.us/tab.js";document.getElementsByTagName("head")[0].appendChild(s);})();</script>Anonymousnoreply@blogger.com2