<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-7139318771131456504</id><updated>2024-11-05T22:59:58.622-04:00</updated><title type='text'>Robótica Educacional</title><subtitle type='html'>Estudos e pesquisas sobre robôtica educacional, utilizando a placa Arduino.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>15</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-634404037683912819</id><published>2012-02-24T21:35:00.000-03:00</published><updated>2012-02-24T21:37:54.237-03:00</updated><title type='text'>Protótipo de automação predial - Projeto SARP</title><content type='html'>Segue um pequeno&amp;nbsp;vídeo&amp;nbsp;feito de um&amp;nbsp;protótipo&amp;nbsp;do projeto projeto SARP (Sistema de automação residencial e predial). Uma pequena demonstração de uma sala que sera controlada automaticamente e&amp;nbsp;através&amp;nbsp;de internet.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;iframe allowfullscreen=&#39;allowfullscreen&#39; webkitallowfullscreen=&#39;webkitallowfullscreen&#39; mozallowfullscreen=&#39;mozallowfullscreen&#39; width=&#39;520&#39; height=&#39;440&#39; src=&#39;https://www.youtube.com/embed/GBHjT6TfAtw?feature=player_embedded&#39; frameborder=&#39;0&#39;&gt;&lt;/iframe&gt;&lt;/div&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/634404037683912819/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2012/02/prototipo-de-automacao-predial-projeto.html#comment-form' title='1 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/634404037683912819'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/634404037683912819'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2012/02/prototipo-de-automacao-predial-projeto.html' title='Protótipo de automação predial - Projeto SARP'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-6989577141596046976</id><published>2011-10-21T08:48:00.001-03:00</published><updated>2012-02-24T21:35:09.238-03:00</updated><title type='text'>Documentário sobre o Arduino</title><content type='html'>Segue abaixo um&amp;nbsp;vídeo&amp;nbsp;documentário&amp;nbsp;sobre a plataforma Arduino.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;iframe allowfullscreen=&#39;allowfullscreen&#39; webkitallowfullscreen=&#39;webkitallowfullscreen&#39; mozallowfullscreen=&#39;mozallowfullscreen&#39; width=&#39;320&#39; height=&#39;266&#39; src=&#39;https://www.youtube.com/embed/Bo2WJ5C6xKo?feature=player_embedded&#39; frameborder=&#39;0&#39;&gt;&lt;/iframe&gt;&lt;/div&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/6989577141596046976/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/10/documentario-sobre-o-arduino.html#comment-form' title='1 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/6989577141596046976'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/6989577141596046976'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/10/documentario-sobre-o-arduino.html' title='Documentário sobre o Arduino'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-3643879548952847748</id><published>2011-08-17T09:39:00.001-04:00</published><updated>2011-08-17T09:40:54.212-04:00</updated><title type='text'>Produtos Sparkfun</title><content type='html'>&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Produtos Sparkfun&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;Como no tópico anterior este também trata da chagada de componentes comprados no exterior. Dessa vez chegaram um Arduíno e um Ethernet Shield, comprados na &lt;a href=&quot;http://www.sparkfun.com/&quot;&gt;SparkFun&lt;/a&gt;, com isso fica a recomendação para essa loja, não é a toa que é a&amp;nbsp;líder&amp;nbsp;neste mercado.&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;Os produtos chegaram lacradinhos, tudo original sem problemas, claro agora o&amp;nbsp;vídeo&amp;nbsp;da abertura da embalagem:&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;iframe allowfullscreen=&#39;allowfullscreen&#39; webkitallowfullscreen=&#39;webkitallowfullscreen&#39; mozallowfullscreen=&#39;mozallowfullscreen&#39; width=&#39;320&#39; height=&#39;266&#39; src=&#39;https://www.youtube.com/embed/yMPUy1epZmA?feature=player_embedded&#39; frameborder=&#39;0&#39;&gt;&lt;/iframe&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/3643879548952847748/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/08/produtos-sparkfun.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/3643879548952847748'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/3643879548952847748'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/08/produtos-sparkfun.html' title='Produtos Sparkfun'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-3495959851645058404</id><published>2011-08-06T00:20:00.004-04:00</published><updated>2011-08-06T00:23:07.944-04:00</updated><title type='text'>Componentes da NKCElectronics</title><content type='html'>&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Chegaram os componentes da NKCElectronics&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;Depois de uma agoniante espera, chegaram os produtos comprados na&amp;nbsp;&lt;a href=&quot;http://www.nkcelectronics.com/&quot;&gt;NKCElectronics&lt;/a&gt;, bom como foi a primeira vez que faço uma copra o exterior pela internet, deu aquele frio na barriga, e sempre a gente pensa, será que vai chegar? será que vai vir tudo certo? será que vai demorar muito?&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Neste post de hoje não estarei ensinando nada, apenas recomendando a loja&amp;nbsp;&lt;a href=&quot;http://www.nkcelectronics.com/&quot;&gt;NKCElectronics&lt;/a&gt;, é uma loja seria,&amp;nbsp;ágil, os produtos vieram todos certinhos chegaram&amp;nbsp;rápido, cerca de 30 dias, por eles terem vindo dos EUA é um tempo bom.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Para quem quiser trabalhar, brincar, estudar, ou apenas por esporte, e queira comprar um&amp;nbsp;Arduíno&amp;nbsp;ou qualquer outro componente, eu recomendo a&amp;nbsp;&lt;a href=&quot;http://www.nkcelectronics.com/&quot;&gt;NKCElectronics&lt;/a&gt;, além da seriedade os preços&amp;nbsp;também&amp;nbsp;são muito bons.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Abaixo um&amp;nbsp;vídeo&amp;nbsp;do momento da abertura da embalagem, que&amp;nbsp;veio lacrada, tudo certinho e bem seguro.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;object class=&quot;BLOGGER-youtube-video&quot; classid=&quot;clsid:D27CDB6E-AE6D-11cf-96B8-444553540000&quot; codebase=&quot;http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0&quot; data-thumbnail-src=&quot;http://i.ytimg.com/vi/rpN697_bbrs/0.jpg&quot; height=&quot;266&quot; width=&quot;320&quot;&gt;&lt;param name=&quot;movie&quot; value=&quot;http://www.youtube.com/v/rpN697_bbrs?f=user_uploads&amp;c=google-webdrive-0&amp;app=youtube_gdata&quot; /&gt;&lt;param name=&quot;bgcolor&quot; value=&quot;#FFFFFF&quot; /&gt;&lt;embed width=&quot;540&quot; height=&quot;420&quot;  src=&quot;http://www.youtube.com/v/rpN697_bbrs?f=user_uploads&amp;c=google-webdrive-0&amp;app=youtube_gdata&quot; type=&quot;application/x-shockwave-flash&quot;&gt;&lt;/embed&gt;&lt;/object&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/3495959851645058404/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/08/componentes-da-nkcelectronics.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/3495959851645058404'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/3495959851645058404'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/08/componentes-da-nkcelectronics.html' title='Componentes da NKCElectronics'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-5792717817016937252</id><published>2011-07-20T17:49:00.005-04:00</published><updated>2011-07-20T17:52:26.841-04:00</updated><title type='text'>Código Arduíno para Sensor ultrassônico</title><content type='html'>&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 13px; line-height: 16px;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange; font-family: inherit;&quot;&gt;Código Arduíno para Sensor ultrassônico&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;Segue abaixo o código que foi utilizado nos testes realizados com o sensor, o mesmo usa a biblioteca&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&lt;a href=&quot;http://iteadstudio.com/store/images/produce/Sensor/HCSR04/Ultrasonic.rar&quot;&gt;&quot;Ultrasonic.h&quot;&lt;/a&gt;, o mesmo código faz um tratamento dos dados recebidos, pegando 4 valores e fazendo uma media dos mesmos.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; font-size: 13px; line-height: 16px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 13px; line-height: 16px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange; font-family: inherit;&quot;&gt;&lt;b&gt;Code:&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;#include &quot;Ultrasonic.h&quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;Ultrasonic ultrasonic(12,13); // TRIG = pino 12 &amp;nbsp; &amp;nbsp; ECHO = pino 13&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;void setup() {&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; Serial.begin(9600);&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; pinMode(8,OUTPUT);&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;}&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;void loop()&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;{&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; font-size: x-small; line-height: 16px;&quot;&gt;tratamento();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; font-size: x-small; line-height: 16px;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;void tratamento(){&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; int distemporaria=0;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; int med[4],i,j,sum;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; delay(5);&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; for(i=0;i&amp;lt;4;i++){&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; &amp;nbsp; med[i]= ultrasonic.Ranging(CM);&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; &amp;nbsp; sum+=med[i];&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; }&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; distemporaria = sum/4 ;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; distancia = distemporaria;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; if (distemporaria &amp;lt; 500){&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; &amp;nbsp; distancia = distemporaria;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&amp;nbsp; }&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&amp;nbsp; else{&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small; line-height: 16px;&quot;&gt;&amp;nbsp;}&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; font-size: x-small;&quot;&gt;Serial.print(&quot;CM: &quot;);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; font-size: x-small;&quot;&gt;Serial.println(distancia);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;}&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Lucida Grande&#39;, &#39;Lucida Sans Unicode&#39;, sans-serif; font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/5792717817016937252/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/07/codigo-arduino-para-sensor-ultrassonico.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/5792717817016937252'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/5792717817016937252'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/07/codigo-arduino-para-sensor-ultrassonico.html' title='Código Arduíno para Sensor ultrassônico'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-8814695871467801408</id><published>2011-07-20T17:27:00.008-04:00</published><updated>2011-07-20T17:54:11.263-04:00</updated><title type='text'>Sensor ultrassônico de distância HC-SR04 - Ultrasonic distance sensor HC-SR04</title><content type='html'>&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 16px;&quot;&gt;&lt;b&gt;Sensor ultrassônico de distância HC-SR04&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange; font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;O HC-SR04 é um sensor ultrassônico, composto por um emissor e um receptor, com capacidade de medir distâncias de 2cm até 5m, com uma precisão de aproximadamente 3mm.&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;Estes sensores emitem um sinal&amp;nbsp;ultrassônico&amp;nbsp;que reflete num objeto e retorna ao sensor. O sinal de retorno é captado, permitindo-se calcular a distância do objeto ao sensor tomando o tempo de trânsito do sinal.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 20px;&quot;&gt;O velocidade do sinal ultrasônico é de aproximadamente 240 m/s, assim, se o sensor estiver a uma distância&amp;nbsp;&lt;i&gt;d&lt;/i&gt;&amp;nbsp;do objeto, o sinal percorrerá uma distância equivalente a&amp;nbsp;&lt;i&gt;2d&lt;/i&gt;&amp;nbsp;para sair e retornar ao sensor.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Dessa forma, o tempo que o sinal leva para sair e retornar ao sensor permite calcular a distância&amp;nbsp;&lt;i&gt;d&lt;/i&gt;&amp;nbsp;pela equação: &lt;/span&gt;&lt;br /&gt;
&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 15px; line-height: 20px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://3.bp.blogspot.com/-PYYge0U4IME/TidKFs15UzI/AAAAAAAAALk/2bOENPp5bIc/s1600/equa%25C3%25A7%25C3%25A3o+do+calculo+de+distancia+com+sensor+ultrassonico.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://3.bp.blogspot.com/-PYYge0U4IME/TidKFs15UzI/AAAAAAAAALk/2bOENPp5bIc/s1600/equa%25C3%25A7%25C3%25A3o+do+calculo+de+distancia+com+sensor+ultrassonico.png&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 20px;&quot;&gt;Fonte: Fristec Tecnologia&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 20px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 20px;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 20px;&quot;&gt;Na figura abaixo é visualizado o sensor HC-SR04. Nele são encontrados 4 pinos de conexão:&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 21px;&quot;&gt;VCC : alimentação de 5V&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 21px;&quot;&gt;TRIG : pino de gatilho&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 21px;&quot;&gt;ECHO : pino de eco&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 21px;&quot;&gt;GND : terra&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 15px; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-H7xkS4Q5LVQ/TidF6nDSp8I/AAAAAAAAALU/Jm65wEABtHg/s1600/Sensor_ObjDec_Ultra_HC_SR04_7.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;231&quot; src=&quot;http://4.bp.blogspot.com/-H7xkS4Q5LVQ/TidF6nDSp8I/AAAAAAAAALU/Jm65wEABtHg/s320/Sensor_ObjDec_Ultra_HC_SR04_7.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 20px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Sua utilização com a placa Arduino é extremamente fácil. Possui quatro pinos sendo que o primeiro (primeiro pino à esquerda na imagem ao lado) deve ser conectado no pino 5V da Arduino, o segundo (Trig) em um pino digital da Arduino configurado para OUTPUT, o terceiro (Echo) em um pino digital da Arduino configurado para INPUT e, finalmente, o quarto pino deve ser conectado no GND, como pode ser visto na figura seguinte&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj-pb4sBbxWjyJloAQMw8NbmRXLJszqDIaTJSOntKc8GJoN5flQ7trEVpqWcaU6UbqzpNQugzrWiyLZidN812F2pcL2lrZcf1jXpEjdGQyJ_lTZ1wGVDIDpsDdWxLwGdU-bsRReF1zqrhI/s1600/HC-SR04.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;285&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj-pb4sBbxWjyJloAQMw8NbmRXLJszqDIaTJSOntKc8GJoN5flQ7trEVpqWcaU6UbqzpNQugzrWiyLZidN812F2pcL2lrZcf1jXpEjdGQyJ_lTZ1wGVDIDpsDdWxLwGdU-bsRReF1zqrhI/s400/HC-SR04.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Lucida Grande&#39;, &#39;Lucida Sans Unicode&#39;, sans-serif; font-size: 13px; line-height: 16px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Clique&amp;nbsp;&lt;a href=&quot;http://iteadstudio.com/store/images/produce/Sensor/HCSR04/HC-SR04.pdf&quot; rel=&quot;nofollow&quot; style=&quot;text-decoration: underline;&quot; target=&quot;_blank&quot;&gt;AQUI&lt;/a&gt;&amp;nbsp;para baixar o datasheet fornecido pelo fabricante.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange; font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange; font-family: inherit;&quot;&gt;Bibliografia&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;&lt;a href=&quot;http://fristec.blogspot.com/2011/01/14-aplicacao-sensor-de-distancia-hc.html&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Frstec Tecnologia&lt;/span&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 16px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Times, &#39;Times New Roman&#39;, serif;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/8814695871467801408/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/07/sensor-ultrassonico-de-distancia-hc.html#comment-form' title='1 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/8814695871467801408'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/8814695871467801408'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/07/sensor-ultrassonico-de-distancia-hc.html' title='Sensor ultrassônico de distância HC-SR04 - Ultrasonic distance sensor HC-SR04'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-PYYge0U4IME/TidKFs15UzI/AAAAAAAAALk/2bOENPp5bIc/s72-c/equa%25C3%25A7%25C3%25A3o+do+calculo+de+distancia+com+sensor+ultrassonico.png" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-5024845715080950167</id><published>2011-06-20T16:45:00.008-04:00</published><updated>2011-06-20T16:56:37.675-04:00</updated><title type='text'>Sensor ultrassônico - ultrasonic sensor</title><content type='html'>&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange; font-family: inherit;&quot;&gt;Funcionamento&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit; line-height: 18px;&quot;&gt;O princípio de funcionamento dos &lt;a href=&quot;http://literature.rockwellautomation.com/idc/groups/literature/documents/ca/c115-ca529_-pt-p.pdf&quot;&gt;sensores ultra-sônicos&lt;/a&gt; está baseado na emissão de uma onda sonora de alta freqüência, e na medição do tempo levado para a recepção do eco produzido quando esta onda se choca com um objeto capaz de refletir o som.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit; line-height: 18px;&quot;&gt;Eles emitem pulsos ultra-sônicos ciclicamente. Quando um objeto reflete estes pulsos, o eco resultante é recebido e convertido em um sinal elétrico.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #222222; font-family: Verdana, sans-serif; font-size: x-small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://3.bp.blogspot.com/-19wP60yDG4g/Tf-vvUwEvPI/AAAAAAAAAKM/FQ20trVJZEw/s1600/funcionamento_sensor_ultrasonico.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;123&quot; src=&quot;http://3.bp.blogspot.com/-19wP60yDG4g/Tf-vvUwEvPI/AAAAAAAAAKM/FQ20trVJZEw/s400/funcionamento_sensor_ultrasonico.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit;&quot;&gt;Figura 01: Principio de funcionamento dos sensores&amp;nbsp;ultrassônicos. Fonte:&amp;nbsp;AUTOMATIZE, 2011.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit; line-height: 18px;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit;&quot;&gt;A detecção do eco incidente, depende de sua intensidade e esta da distância entre o objeto e o sensor ultra-sônico. Os sensores ultra-sônicos funcionam medindo o tempo de propagação do eco. Isto é, o intervalo de tempo medido entre o impulso sonoro emitido e o eco do mesmo.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit;&quot;&gt;A construção do sensor faz com que o feixe ultra-sônico seja emitido em forma de um cone (AUTOMATIZE, 2011).&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;b&gt;Referencias&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange; font-family: Verdana, sans-serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #999999; font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;AUTOMATIZE, Automatize - soluções em sensores.&amp;nbsp;Disponível&amp;nbsp;em:&amp;lt;&lt;/span&gt;&lt;a href=&quot;http://www.automatizesensores.com.br/ultrasonicos.html&quot;&gt;http://www.automatizesensores.com.br/ultrasonicos.html&lt;/a&gt;&amp;gt; Acessado em Junho de 2011.&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/5024845715080950167/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/06/sensor-ultrassonico-ultrasonic-sensor.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/5024845715080950167'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/5024845715080950167'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/06/sensor-ultrassonico-ultrasonic-sensor.html' title='Sensor ultrassônico - ultrasonic sensor'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-19wP60yDG4g/Tf-vvUwEvPI/AAAAAAAAAKM/FQ20trVJZEw/s72-c/funcionamento_sensor_ultrasonico.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-6279611567045477340</id><published>2011-05-20T19:09:00.003-04:00</published><updated>2011-05-20T19:11:42.877-04:00</updated><title type='text'>Conceito de sensores e atuadores</title><content type='html'>&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;b&gt;Sensores&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Sensores são dispositivos que trabalham com medidas de grandezas&amp;nbsp;físicas, como: temperatura, pressão, presença, umidade, intensidade luminosa, entre&amp;nbsp;outros. As grandezas medidas pelos sensores são combinadas a fim de obter&amp;nbsp;informações sobre o meio físico, onde estão presentes. Em geral os sensores atuam&amp;nbsp;transformando partes de uma grandeza física normalmente em um sinal elétrico, que&amp;nbsp;por sua vez pode ser interpretado por certos equipamentos eletrônicos (BORGES &amp;amp;&amp;nbsp;DORES, 2010). Em outras palavras, sensores são componentes eletrônicos que&amp;nbsp;permitem que um equipamento eletrônico possa interagir com o mundo.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Segundo Borges &amp;amp; Dores (2010), os sensores quando operam de forma&amp;nbsp;direta, transformando uma forma de energia em outra são chamados de&amp;nbsp;transdutores. Os sensores onde as operações ocorrem de forma indireta alteram&amp;nbsp;suas propriedades, como a resistência, capacitância ou indutância, sob a ação da&amp;nbsp;grandeza de forma que essa alteração ocorre mais ou menos proporcional.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Podemos citar como exemplo os sensores de luz, mais especificamente o&amp;nbsp;resistor dependente de luz, mais conhecido pela sigla do seu nome em inglês LDR&amp;nbsp;(Light-dependent resistors), segundo Oxer &amp;amp; Blemings (2009), esses sensores&amp;nbsp;variam sua resistência inversamente a quantidade de luz que incide sobre o mesmo,&amp;nbsp;em outras palavras, quando há uma grade quantidade de luz incidindo sobre o&amp;nbsp;sensor, eles têm uma resistência muito baixa o que permitir o fluxo da corrente&amp;nbsp;elétrica, enquanto que quando a pouca luz, apresentam uma resistência elevada,&amp;nbsp;podendo atingir alguns megaohms, evitando assim a passagem corrente.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://2.bp.blogspot.com/-wrhSpoBkVi4/Tdbyruvs2mI/AAAAAAAAAKE/st57rniX_4Q/s1600/167-232-large.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://2.bp.blogspot.com/-wrhSpoBkVi4/Tdbyruvs2mI/AAAAAAAAAKE/st57rniX_4Q/s1600/167-232-large.jpg&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;Figura 01: Sensor LDR.&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Atuadores&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Um atuador assim como um sensor é um transdutor que transforma uma&amp;nbsp;forma de energia em outra, porem este faz o caminho inverso, ao invés de&amp;nbsp;transformar partes de uma grandeza física em um sinal elétrico, ele transforma um&amp;nbsp;sinal elétrico em uma grandeza física, movimento, magnetismo, calor entre outros.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Além do mais Brugnari &amp;amp; Maestrelli (2010) dizem que atuadores:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;div style=&quot;text-align: right;&quot;&gt;&lt;i&gt;[...] atendem a comandos que podem ser manuais ou automáticos, ou&lt;/i&gt;&lt;/div&gt;&lt;div style=&quot;text-align: right;&quot;&gt;&lt;i&gt;seja, qualquer elemento que realize um comando recebido de outro&lt;/i&gt;&lt;/div&gt;&lt;div style=&quot;text-align: right;&quot;&gt;&lt;i&gt;dispositivo, com base em uma entrada ou critério a ser seguido [...].&lt;/i&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div&gt;Como exemplo de atuadores temos os relés que segundo Souto (2004), é&amp;nbsp;um dispositivo eletromecânico que funciona com pequenas correntes, mas é capaz&amp;nbsp;de controlar circuitos externos que envolvem correntes elevadas, e é formado&amp;nbsp;basicamente por uma bobina e um conjunto de contatos, como pode ser visto na&amp;nbsp;figura 02.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-iv5FcSZIRMk/TdbzQTaEpBI/AAAAAAAAAKI/Ed39QjLUAJg/s1600/Esquema+do+rel%25C3%25A9.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;175&quot; src=&quot;http://4.bp.blogspot.com/-iv5FcSZIRMk/TdbzQTaEpBI/AAAAAAAAAKI/Ed39QjLUAJg/s400/Esquema+do+rel%25C3%25A9.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;div style=&quot;text-align: center;&quot;&gt;Figura 08: Esquema de funcionamento dos relés. Fonte: (SOUTO, 2004).&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Quando uma corrente circula pela bobina cria um campo magnético que&amp;nbsp;atrai, abrindo ou fechando os contatos, permanecendo assim enquanto houver&amp;nbsp;alimentação de energia na bobina, permitindo assim a passagem ou não, de energia&amp;nbsp;através do relé (SOUTO, 2004).&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;b&gt;Referencias&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;BORGES, L. P.; DORES, R. C., Automação predial sem fio utilizando&amp;nbsp;bacnet/zigbee com foco em economia de energia. 2010, 76f. Trabalho de&amp;nbsp;conclusão de curso - Curso de Graduação em Engenharia de Controle e Automação&amp;nbsp;– UNB, Brasília, 2010.&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;BRUGNARI, A.; MAESTRELLI, L. H. M., AUTOMAÇÃO RESIDENCIAL via WEB.&amp;nbsp;2010, 36f. Trabalho de conclusão de curso - Curso de Graduação em Engenharia de&amp;nbsp;Computação - PUC-PR, Curitiba, 2010.&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;OXER, J.; BLEMINGS, H. , Practical Arduino - Cool Projects for Open Source&amp;nbsp;Hardware, 1a Edição, Apress , New York, 2009.&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;SOUTO, W. A., APOSTILA DE COMANDOS ELÉTRICOS, CURSO TÉCNICO DE&amp;nbsp;ELETROMECÂNICA, CEFET-BA. Disponível em:&amp;nbsp;&amp;lt;http://www.eletrodomesticosforum.com/cursos/eletricidade_eletronica/automacao/curso_tecnico_eletromecanica.pdf&amp;gt;. Acesso em Maio de 2011.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/6279611567045477340/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/conceito-e-sensores-e-atuadores.html#comment-form' title='1 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/6279611567045477340'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/6279611567045477340'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/conceito-e-sensores-e-atuadores.html' title='Conceito de sensores e atuadores'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-wrhSpoBkVi4/Tdbyruvs2mI/AAAAAAAAAKE/st57rniX_4Q/s72-c/167-232-large.jpg" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-2552617469621822895</id><published>2011-05-02T22:52:00.002-04:00</published><updated>2011-05-02T22:57:05.072-04:00</updated><title type='text'>Hardware Arduino (parte III)</title><content type='html'>&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Comunicação&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O Arduino Uno tem uma série de facilidades para se comunicar com um computador, outro Arduino, ou outros microcontroladores. O ATmega328 fornece comunicação serial, UART TTL (5V), que está disponível nos pinos digitais 0 (RX) e 1 (TX). Um ATmega8U2 na placa canaliza as comunicação serial através da USB e aparece como uma porta COM virtual para o software no computador. O software Arduino inclui um monitor serial que permite que dados simples de texto possam ser enviado a e da placa Arduino.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;A biblioteca SoftwareSerial permite a comunicação serial em qualquer um dos pinos de digital do Arduino Uno.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O ATmega328 também suporta&amp;nbsp;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #aeaeae; font-weight: bold; line-height: 24px;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;I&lt;/span&gt;&lt;strong&gt;&lt;sup&gt;&lt;span style=&quot;font-style: normal;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;2&lt;/span&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #aeaeae; font-weight: bold; line-height: 24px;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;C&amp;nbsp;&lt;/span&gt;&lt;/span&gt;(&lt;/span&gt;TWI) e comunicação SPI. O software Arduino inclui a biblioteca Wire para simplificar a utilização do bus&amp;nbsp;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #aeaeae; font-weight: bold; line-height: 24px;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;I&lt;/span&gt;&lt;strong&gt;&lt;sup&gt;&lt;span style=&quot;font-style: normal;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;2&lt;/span&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #aeaeae; font-weight: bold; line-height: 24px;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;C&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;. Para a comunicação SPI, usa-se a biblioteca de SPI, (Herrador, 2009; Arduino, 2011).&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;b&gt;Programação&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;De acordo com (Arduino, 2011) o Arduino Uno pode ser programado com o software do Arduino. Para programadores que estão aprendendo a usar a placar Arduino existem uma seria de tutoriais disponíveis no site dos desenvolvedores.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O ATmega328 no Arduino Uno vem pré programado com um bootloader3, que permite que você envie novos códigos a placa sem a utilização de um programador de hardware externo. Ele se comunica o protocolo original STK500.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O usuário também pode ignorar o bootloader e programar o microcontrolador através do ICSP (In-Circuit Serial Programming).&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;b&gt;Reset Automático (Software)&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;De acordo com (Arduino, 2011) ao invés de requerer uma pulsação física do botão reset antes de um upload (enviar um novo programa a placa), o Arduino Uno é projetado de uma maneira que permite que ele seja resetado pelo software rodando em um computador conectado. Uma das linhas de hardware de controle de fluxo (DTR) da ATmega8U2 está ligado à linha de reset do ATmega328 através de um capacitor de 100 nF. Quando esta linha tem o valor (LOW), a linha de reset cai o tempo suficiente para resetar o chip. O software Arduino usa esse recurso para permitir que o usuário envie o código, apenas pressionando o botão de upload no software Arduino.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O Arduino Uno tem um poli fusível reajustável que protege as portas USB do seu computador de cortes e sobrecorrentes. Embora a maioria dos computadores fornecem sua própria proteção interna, o fusível fornece uma camada de proteção extra. Se mais de 500 mA é aplicado à porta USB, o fusível irá quebrar automaticamente a conexão até que a sobrecarga ou curto sejam eliminados &amp;nbsp;(Herrador, 2009; Arduino, 2011).&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Características físicas&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O comprimento e a largura máxima do Uno PCB são 2,7 e 2,1 polegadas, respectivamente, com o conector USB e conector de alimentação que ultrapasse a dimensão anterior. Quatro furos permitem que a placa seja conectada a uma superfície ou em um estojo (Herrador, 2009; Arduino, 2011).&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #aeaeae; font-weight: bold; line-height: 18px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;REFERÊNCIAS&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Arduíno – Homepage. Disponível em: &amp;lt;&lt;a href=&quot;http://www.arduino.cc/&quot; style=&quot;color: #990000; text-decoration: none;&quot;&gt;http://www.arduino.cc/&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;HERRADOR, R. E., Guía de Usuario de Arduíno, 2009. Disponível em: &amp;lt;&lt;a href=&quot;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&quot; style=&quot;color: #990000; text-decoration: none;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #990000;&quot;&gt;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&lt;/span&gt;&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/2552617469621822895/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/hardware-arduino-parte-iii.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/2552617469621822895'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/2552617469621822895'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/hardware-arduino-parte-iii.html' title='Hardware Arduino (parte III)'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-2960367358807680936</id><published>2011-05-02T22:41:00.007-04:00</published><updated>2011-05-03T08:06:18.311-04:00</updated><title type='text'>Hardware Arduino (parte II)</title><content type='html'>&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;b&gt;Memória&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O ATmega328 tem 32 KB (com 0,5 KB utilizado para o gerenciador de boot). Também possui 2 KB de SRAM e 1 KB de EEPROM (que pode ser lido e escrito com a biblioteca EEPROM1), (Herrador, 2009; Arduino, 2011).&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Entrada e Saída&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;De acordo com (Arduino, 2011) cada um dos 14 pinos digitais do Arduino Uno pode ser usado como &amp;nbsp;entrada ou saída, usando funções pinMode(), digitalWrite() e digitalRead()2. Eles operam com 5 volts. Cada pino pode fornecer ou receber um máximo de 40 mA e tem um resistor de “pull-up” (desligado por padrão) de 20-50 kOhms. Além disso, alguns pinos têm funções específicas:&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→&amp;nbsp;Serial: 0 (RX) e 1 (TX). &lt;/span&gt;&lt;/b&gt;Usados para receber (RX) e transmitir (TX) dados seriais TTL. Esses pinos são conectados aos pinos correspondentes do chip ATmega8U2 &amp;nbsp;USB-para-TTL serial.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ Interrupções Externas: 2 e 3.&lt;/span&gt;&lt;/b&gt; Esses pinos podem ser configurados para disparar uma interrupção por um valor baixo, uma margem crescente ou decrescente, ou uma alteração no valor. Veja a função attachInterrupt()1 para obter mais detalhes.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ PWM: 3, 5, 6, 9, 10 e 11. &lt;/span&gt;&lt;/b&gt;Proporcionar saída PWM de 8 bits com a função analogWrite()1.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ SPI: (SS), 11 (MOSI), 12 (MISO), 13 (SCK) 10.&lt;/span&gt;&lt;/b&gt; Estes pinos suportam comunicação SPI, usando a biblioteca SPI.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ LED: 13. &lt;/span&gt;&lt;/b&gt;Há um LED embutido conectado ao pino digital 13. Quando o pino está em HIGH, o LED está ligado, quando o pino é LOW, o LED é desligado.&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://1.bp.blogspot.com/-n7SnXk0Lc94/Tb_vrTqkgvI/AAAAAAAAAIE/wHuQlQteopw/s1600/ArduinoUnoFront_commented.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;253&quot; src=&quot;http://1.bp.blogspot.com/-n7SnXk0Lc94/Tb_vrTqkgvI/AAAAAAAAAIE/wHuQlQteopw/s400/ArduinoUnoFront_commented.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Courier New&#39;, Courier, FreeMono, monospace; font-size: 13px; font-weight: bold; line-height: 18px;&quot;&gt;Figura 01: Arduino Uno. Fonte: (Arduino, 2011).&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Courier New&#39;, Courier, FreeMono, monospace; font-size: 13px; font-weight: bold; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;De acordo com (Arduino, 2011) o Arduino Uno tem 6 entradas analógicas, rotulados A0 a A5, cada qual com 10 bits de resolução (ou seja, diferentes valores de 1024). Por padrão, eles medem do negativo ou terra até 5 volts, embora seja possível alterar o valor superior de sua faixa de uso com o pino AREF e a função analogReference()1. Além disso, alguns pinos têm funções especializadas:&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ I2C : A4 (SDA) e A5 (SCL).&lt;/span&gt;&lt;/b&gt; Suporte a comunicação&amp;nbsp;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 24px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;I&lt;/span&gt;&lt;strong&gt;&lt;sup&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-style: normal;&quot;&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;2&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/strong&gt;&lt;span style=&quot;font-weight: normal;&quot;&gt;C&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&amp;nbsp;(TWI) &amp;nbsp;usando a biblioteca Wire2.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;Existe outro par de pinos na placa:&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;&lt;b&gt;→ AREF.&lt;/b&gt;&lt;/span&gt; Voltagem de referencia para as entradas analógicas ( apenas de 0 a 5V). Usado com analogReference().&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ Reset. &lt;/span&gt;&lt;/b&gt;Coloque esta linha em LOW para resetar o microcontrolador. Tipicamente usado para adicionar um botão de reset para os dispositivos que bloqueiam a placa principal.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; font-weight: bold;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #aeaeae; line-height: 18px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;REFERÊNCIAS&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Arduíno – Homepage. Disponível em: &amp;lt;&lt;a href=&quot;http://www.arduino.cc/&quot; style=&quot;color: #990000; text-decoration: none;&quot;&gt;http://www.arduino.cc/&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;HERRADOR, R. E., Guía de Usuario de Arduíno, 2009. Disponível em: &amp;lt;&lt;a href=&quot;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&quot; style=&quot;color: #990000; text-decoration: none;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #990000;&quot;&gt;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&lt;/span&gt;&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/2960367358807680936/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/hardware-arduino-parte-ii.html#comment-form' title='1 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/2960367358807680936'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/2960367358807680936'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/hardware-arduino-parte-ii.html' title='Hardware Arduino (parte II)'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/-n7SnXk0Lc94/Tb_vrTqkgvI/AAAAAAAAAIE/wHuQlQteopw/s72-c/ArduinoUnoFront_commented.jpg" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-8492209040823609367</id><published>2011-05-02T17:01:00.008-04:00</published><updated>2011-05-03T08:18:50.235-04:00</updated><title type='text'>Hardware Arduino (parte I)</title><content type='html'>&lt;div style=&quot;text-align: center;&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Hardware&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Existem muitas versões do Arduino, pelo fato de ser open source e ter a licença Creative Comons, muitos desenvolvedores criaram suas próprias versões do Arduino. Entre as versões mais conhecidas estão: Diecimila, Nano, Bluetooth, LilyPad, Mini, Serial, Serial Single Sided, Uno que atualmente é a versão mais recente é também a versão padrão do Arduino, alem destes existem muitos outros menos conhecidos.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Arduino Uno - Visão Geral&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O Arduino Uno é uma placa microcontroladora baseada no microcontrolador Atmega328. Possui 14 pinos de entrada e saída digitais (dos quais 06 podem ser usados como saídas PWM), 06 entradas analógicas, um oscilador de cristal de 16 Mhz, uma conexão USB, um conector para alimentação, um conector ISCP, e um botão de reset. Ele contem todo o necessário para apoiar o microcontrolador, basta ligá-lo a um computador através de um cabo USB ou conectá-lo a um adaptador AC/DC, ou &amp;nbsp;em uma bateria para começar (Herrador, 2009; Arduino, 2011).&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-OBJ1aGfCZjA/Tb8ayAAstXI/AAAAAAAAAH4/tmNbQqqXNnc/s1600/figura+05.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;297&quot; src=&quot;http://4.bp.blogspot.com/-OBJ1aGfCZjA/Tb8ayAAstXI/AAAAAAAAAH4/tmNbQqqXNnc/s400/figura+05.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;Figura 01: Arduino Uno. Fonte: (Arduino, 2011).&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O Uno é diferente de todas as versões anteriores já que ele não usa o FTDI para o chip de comunicação serial USB. Em vez disso, ele apresenta o Atmega8U2 programado, como um conversor USB para serial (Arduino, 2011).&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Características&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Resumo das características técnicas da placa Arduino.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://1.bp.blogspot.com/-jJQU0HRUy2c/Tb_ymlDpB1I/AAAAAAAAAIM/XNe0Ie5_o7U/s1600/Caracteristicas+da+placa++Arduino.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;240&quot; src=&quot;http://1.bp.blogspot.com/-jJQU0HRUy2c/Tb_ymlDpB1I/AAAAAAAAAIM/XNe0Ie5_o7U/s400/Caracteristicas+da+placa++Arduino.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;Figura 02: Características técnicas da placa Arduino. Fonte: (Arduino, 2011).&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;Alimentação&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Segundo (Arduino, 2011) o Arduino Uno pode ser alimentado através da entrada USB ou com uma fonte de alimentação externa. A fonte de energia é selecionada automaticamente.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;A alimentação externa (não USB) pode vir de um adaptador AC-DC ou de uma bateria. O adaptador pode ser conectado através de um plug de 2,1 milímetros de centro positivo, no conector de energia da placa. A alimentação feita através de uma bateria pode ser feita através dos pinos GND e VIN do conector de alimentação.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;A placa pode operar com uma fonte externa de 6 a 20 volts. Se a fonte externa tiver voltagem menor que 7V, no entanto, o pino de 5V pode fornecer menos de cinco volts e a placa poderá ficar instável. Se usar mais do que 12V, o regulador de voltagem pode superaquecer e danificar a placa. A faixa recomendada para alimentação externa é de 7 a 12 volts (Herrador, 2009; Arduino, 2011).&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Os pinos de alimentação da placa Arduino são os seguintes:&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ VIN:&lt;/span&gt;&lt;/b&gt; A entrada de tensão da placa Arduino, quando ela está usando uma fonte externa de energia (ao contrário de 5 volts a partir da conexão USB ou fonte de alimentação regulada). Você pode fornecer a tensão através desse pino, ou, se o fornecimento de tensão for realizado através do conector de alimentação, pode-se acessá-lo através deste pino.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;&lt;b&gt;→ 5V: &lt;/b&gt;&lt;/span&gt;A fonte de alimentação regulada usada para alimentar o microcontrolador e outros componentes na placa. Este pode vir do pino VIN através de um regulador na placa, ou ser fornecido pelo USB ou outra fonte de regulada de 5V.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;&lt;b&gt;→ 3V3: &lt;/b&gt;&lt;/span&gt;Uma fonte de 3,3 volts gerado pelo regulador da placa. A corrente máxima é 50 mA.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;&lt;b&gt;→ GND:&lt;/b&gt;&lt;/span&gt; Pinos terra.&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #aeaeae; font-family: &#39;Courier New&#39;, Courier, FreeMono, monospace; font-size: 13px; font-weight: bold; line-height: 18px;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;REFERÊNCIAS&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Arduíno – Homepage. Disponível em: &amp;lt;&lt;a href=&quot;http://www.arduino.cc/&quot; style=&quot;color: #990000; text-decoration: none;&quot;&gt;http://www.arduino.cc/&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;HERRADOR, R. E., Guía de Usuario de Arduíno, 2009. Disponível em: &amp;lt;&lt;a href=&quot;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #990000;&quot;&gt;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&lt;/span&gt;&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/8492209040823609367/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/hardware-arduino-parte-i.html#comment-form' title='4 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/8492209040823609367'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/8492209040823609367'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/05/hardware-arduino-parte-i.html' title='Hardware Arduino (parte I)'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/-OBJ1aGfCZjA/Tb8ayAAstXI/AAAAAAAAAH4/tmNbQqqXNnc/s72-c/figura+05.jpg" height="72" width="72"/><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-7380553695150387237</id><published>2011-04-27T14:58:00.005-04:00</published><updated>2011-05-02T22:58:56.988-04:00</updated><title type='text'>A plataforma Arduino</title><content type='html'>&lt;div style=&quot;text-align: justify;&quot;&gt;Atualmente a plataforma Arduíno esta difundida por todo o mundo, sendo que esta é utilizada por vários tipos de pessoas e segundo a Homepage dos desenvolvedores o Arduíno é uma plataforma de protótipos eletrônicos de código aberto (open source) baseada em hardware a software flexíveis e fácil de usar. É destinado a artistas, designers, hobbyists, e qualquer pessoa interessada em criar objetos ou ambientes interativos.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O Arduíno pode “sentir” o ambiente através de sensores e também afetá-lo com o uso de atuadores, como motores, luzes entre outros. O microcontrolador &amp;nbsp;da&amp;nbsp;placa é programado em “Arduino Programming Language”(baseado em Wiring) e o “Arduino Development Environment” (baseado em Processing). Os projetos do Arduíno podem ser autônomos ou podem se comunicar com um software em execução em computador. As placas podem ser construídas a mão ou compradas prontas e o software pode ser baixado gratuitamente (Arduíno, 2011).&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O sucesso que a plataforma Arduíno eve foi em grande parte determino &amp;nbsp;por algumas características:&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ &lt;/span&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;Preço:&lt;/span&gt;&lt;/b&gt; As placas Arduíno são relativamente baratas se comparadas a outras plataformas de microcontroladores, a versão mais barata do Arduíno custa cerca de 85 reais.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;&lt;b&gt;→&lt;/b&gt;&lt;/span&gt;&amp;nbsp;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;Multi plataforma: &lt;/span&gt;&lt;/b&gt;O software Arduíno é executado no Linux, no Macintosh OS ou no Windows, basta ter instalado a maquina virtal java.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→ Ambiente de programação simples e claro:&lt;/span&gt;&lt;/b&gt; Conforme, (Herrador, 2009) o ambiente de programação do Arduíno é simples de ser usado por principiantes, porem, é suficientemente flexível para ser usado por usuários mais experientes.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→&lt;/span&gt; &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;Código abeto e software expansível:&lt;/span&gt;&lt;/b&gt; O Software Arduíno é baseado na linguagem AVR C, Herrador (2009). É uma ferramenta de código aberto, disponível para a utilização por todos os interessados, também pode ser expandida por programadores experientes que construam &amp;nbsp;bibliotecas em linguagem C++.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;→&lt;/span&gt; &amp;nbsp;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;Código abeto e hardware expansível:&lt;/span&gt;&lt;/b&gt; Atualmente o Arduíno possui varias versões, porem ainda é baseado nos microcontroladores Atmega8, Atmega168, Atmega328, Atmega1280, Atmega2560 da Atmel. O projeto do Arduíno esta publicado com a licença Creative Comons, qualquer pessoa é livre para usar e modificar os circuitos de acordo com suas necessidades.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: orange;&quot;&gt;REFERÊNCIAS&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Arduíno – Homepage. Disponível em: &amp;lt;&lt;a href=&quot;http://www.arduino.cc/&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #990000;&quot;&gt;http://www.arduino.cc/&lt;/span&gt;&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;HERRADOR, R. E., Guía de Usuario de Arduíno, 2009. Disponível em: &amp;lt;&lt;a href=&quot;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #990000;&quot;&gt;http://www.uco.es/aulasoftwarelibre/wp-content/uploads/2010/05/Arduino_user_manual_es.pdf&lt;/span&gt;&lt;/a&gt;&amp;gt; Acesso em março de 2011.&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/7380553695150387237/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/04/plataforma-arduino.html#comment-form' title='2 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/7380553695150387237'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/7380553695150387237'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/04/plataforma-arduino.html' title='A plataforma Arduino'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-6333723007126484477</id><published>2011-02-21T22:46:00.007-04:00</published><updated>2011-02-22T15:30:54.864-04:00</updated><title type='text'>Arduíno e Speaker</title><content type='html'>&lt;div style=&quot;text-align: justify;&quot;&gt;Brincando com a placa Arduíno e um auto falante ou em inglês “speaker”, utilizando a placa Arduíno com um circuito e um código muito simples pode-se fazer alguns sons muito interessantes e divertidos.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;O circuito segue aqui em baixo:&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-NsUGcFFCdUA/TWMjXIxH7OI/AAAAAAAAAHA/cFweCe4xucI/s1600/speaker_bb.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;http://4.bp.blogspot.com/-NsUGcFFCdUA/TWMjXIxH7OI/AAAAAAAAAHA/cFweCe4xucI/s320/speaker_bb.jpg&quot; width=&quot;268&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;O código também muito simples pode ser este para fazer um som com os tons indo de de 200 a 3000 tonalidades. Mas esse código pode ser modificas de acordo com a vontade para produzir sons diferentes. Segue o código:&lt;/div&gt;&lt;br /&gt;
&amp;nbsp;void setup() {&lt;br /&gt;
Serial.begin(9600);&lt;br /&gt;
&amp;nbsp;}&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;void loop() {&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp; int i=200;&lt;br /&gt;
&amp;nbsp;&amp;nbsp; while(i&amp;lt;100){&lt;br /&gt;
&amp;nbsp;&amp;nbsp; tone(8, i, 10);&lt;br /&gt;
&amp;nbsp;&amp;nbsp; i++;&lt;br /&gt;
&amp;nbsp;&amp;nbsp; delay(10);&lt;br /&gt;
&amp;nbsp;&amp;nbsp; Serial.println(i);&lt;br /&gt;
&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;}&lt;br /&gt;
&lt;br /&gt;
Segue um vídeo do sistema funcionando:&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;iframe allowfullscreen=&#39;allowfullscreen&#39; webkitallowfullscreen=&#39;webkitallowfullscreen&#39; mozallowfullscreen=&#39;mozallowfullscreen&#39; width=&#39;540&#39; height=&#39;420&#39; src=&#39;https://www.youtube.com/embed/eZ0FuPRavgg?feature=player_embedded&#39; frameborder=&#39;0&#39;&gt;&lt;/iframe&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/6333723007126484477/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/02/brincando-com-placa-arduino-e-um-auto.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/6333723007126484477'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/6333723007126484477'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/02/brincando-com-placa-arduino-e-um-auto.html' title='Arduíno e Speaker'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/-NsUGcFFCdUA/TWMjXIxH7OI/AAAAAAAAAHA/cFweCe4xucI/s72-c/speaker_bb.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-3817517622721688891</id><published>2011-02-11T20:43:00.029-03:00</published><updated>2011-02-12T13:04:00.894-03:00</updated><title type='text'>Fotosensor</title><content type='html'>&lt;style type=&quot;text/css&quot;&gt;
p { margin-bottom: 0.21cm; }
&lt;/style&gt;  &lt;br /&gt;
&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm; text-indent: 1.24cm;&quot;&gt;Programa para controlar um fotosensor com a placa Arduíno, este controla o sensor que emite informações sobre a quantidade de luz no ambiente.&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm; text-indent: 1.22cm;&quot;&gt;Neste caso foi programado para que o LED vermelho fique acesso quando tenha luz no ambiente e o LED verde quando esteja com pouca luz sendo emitida para o sensor. Outro LED aumenta e diminui seu brilho conforme a intensidade da luz emitida para o sensor, como pode ser visto na figura 1.&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm; text-indent: 1.22cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;http://1.bp.blogspot.com/-qxNWO7y_QR0/TVXNXU6j-BI/AAAAAAAAAGc/Meabcb6F3oA/s1600/fotosensorcorte.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;243&quot; src=&quot;http://1.bp.blogspot.com/-qxNWO7y_QR0/TVXNXU6j-BI/AAAAAAAAAGc/Meabcb6F3oA/s320/fotosensorcorte.JPG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm; text-indent: 1.22cm;&quot;&gt;&amp;nbsp;          &lt;style type=&quot;text/css&quot;&gt;
p { margin-bottom: 0.21cm; }
&lt;/style&gt;  &lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm; text-indent: 1.27cm;&quot;&gt;Na utilização de sensores é interessante utilizar o modo de leitura analógica que lê valores de 0 a 1023, o que é mais interessante para alguns tipos de sensores, como é o nosso caso.&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;Pra fazer a leitura do sensor foi utilizado o seguinte código:&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;“int leitor;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;leitor = analogRead(pinr);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;leitor = map(leitor, 0,1023,0,255);”&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Criou-se uma variável do tipo int chamada leitor, os valores são lidos na segunda linha do código com o comendo “leitor = analogRead(pinr);”, onde “pinr” é o nome do pino de leitura, os valores recebidos foram atribuídos para a variável leitor. Na linha três os valores são mapeados de 0 a 1023 para 0 255, ou seja, os valores são redimensionados. Redimensionamos os valores para emiti-los em uma porta PWM que usa apenas valores de 0 a 255, essa porta é utilizada  quando se deseja mandar algum tipo de intensidade ou velocidade para algum objeto neste caso o LED de intensidade. Nas outras portas da placa Arduíno se mandarmos sinal ele apenas liga ou desliga o sinal, porem nas portas PWM podemos controlar o tamanho do sinal que varia de 0 a 255.&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Normalmente os sensores são utilizados para fazer alguma coisa, bom no nosso caso vamos ligar a apagar LEDs dependendo da intensidade da luz, parece ser algo simples mas para quem tem criatividade pode ter varias utilidades. O código abaixo mostra como é feito para ligar a desligar os LEDs:&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;“  if(leitor&amp;gt;127){&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMaior, HIGH);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMenor, LOW);}&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;else{&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMenor, HIGH);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMaior, LOW);}”&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Muito simples, foi utilizado um “if”, se os valores do leitor forem maiores que 127 então ligue o pino “digitalWrite(pinMaior, HIGH);” e desligue o pino digitalWrite(pinMenor, LOW);, HIGH é utilizado no Arduíno para ligar os pinos e LOW para deligar ou mandar um valor zero. Senão “ else” ligue o pino digitalWrite(pinMenor, HIGH); e desligue o pino digitalWrite(pinMaior, LOW);  &lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Para uma melhor compreensão o esquema de montagem e o código completo estão abaixo: &lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/-GspIx1nn8IU/TVXcLm9RoLI/AAAAAAAAAGo/RIOfkkXPrgs/s1600/fotosensor_bb.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;280&quot; src=&quot;http://4.bp.blogspot.com/-GspIx1nn8IU/TVXcLm9RoLI/AAAAAAAAAGo/RIOfkkXPrgs/s400/fotosensor_bb.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;“int pinMaior = 7;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;int pinMenor = 6;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;int pinIntensidade = 9;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;int pinr = 0;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;void setup(){&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;pinMode(pinMaior, OUTPUT);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;pinMode(pinMenor, OUTPUT);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;pinMode(pinIntensidade, OUTPUT);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;Serial.begin(9600);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;}&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;void loop(){   &lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;int leitor;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;leitor = analogRead(pinr);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;leitor = map(leitor, 0,1023,0,255);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;analogWrite(pinIntensidade, leitor);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;if(leitor&amp;gt;127){&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMaior, HIGH);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMenor, LOW);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;}&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;else{&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMenor, HIGH);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;digitalWrite(pinMaior, LOW);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;}&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;Serial.print(&quot;Valor Lido: &quot;);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;Serial.print(leitor);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;delay (10);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;Serial.println(&quot;&quot;);&lt;/div&gt;&lt;div align=&quot;JUSTIFY&quot; class=&quot;western&quot; style=&quot;color: red; margin-bottom: 0cm;&quot;&gt;}”&lt;br /&gt;
&lt;div style=&quot;color: black;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;span style=&quot;color: black;&quot;&gt;Vídeo que mostra o sistema funcionando.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;&lt;/span&gt; &lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;iframe allowfullscreen=&#39;allowfullscreen&#39; webkitallowfullscreen=&#39;webkitallowfullscreen&#39; mozallowfullscreen=&#39;mozallowfullscreen&#39; width=&#39;540&#39; height=&#39;420&#39; src=&#39;https://www.youtube.com/embed/PWODUmMCQJw?feature=player_embedded&#39; frameborder=&#39;0&#39;&gt;&lt;/iframe&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/3817517622721688891/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2011/02/fotosensor.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/3817517622721688891'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/3817517622721688891'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2011/02/fotosensor.html' title='Fotosensor'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/-qxNWO7y_QR0/TVXNXU6j-BI/AAAAAAAAAGc/Meabcb6F3oA/s72-c/fotosensorcorte.JPG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7139318771131456504.post-1534962829979371220</id><published>2010-06-25T14:04:00.001-04:00</published><updated>2010-09-29T10:42:09.250-04:00</updated><title type='text'>Primeiro teste com placa arduino</title><content type='html'>&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;a href=&quot;http://4.bp.blogspot.com/_zdjXm2HhBPM/TCTuOYPEwVI/AAAAAAAAAEU/21L9Gt7L3gw/s1600/seeeduino3281.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; float: right; margin-bottom: 1em; margin-left: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;240&quot; src=&quot;http://4.bp.blogspot.com/_zdjXm2HhBPM/TCTuOYPEwVI/AAAAAAAAAEU/21L9Gt7L3gw/s320/seeeduino3281.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;O primeiro programa feito para a placa arduino - compilação seeeduino v2.12 como visto na figura ao lado, foi um programa bem básico que apenas faz com que um led acenda e apague.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;a href=&quot;http://2.bp.blogspot.com/_zdjXm2HhBPM/TCTu-r9lYxI/AAAAAAAAAEc/6ti19wjFjCU/s1600/Captura_de_tela-1.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;http://2.bp.blogspot.com/_zdjXm2HhBPM/TCTu-r9lYxI/AAAAAAAAAEc/6ti19wjFjCU/s320/Captura_de_tela-1.png&quot; /&gt;&lt;/a&gt;Foi utilizado o software da empreza fabricande do arduino para se fazer o envio do codigo para a placa arduino.&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Código usado para fazer o LED piscar:&lt;br /&gt;
Esse foi o primeiro programa feito para o arduino.&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;color: red;&quot;&gt;int ledPin =&amp;nbsp; 13;&amp;nbsp;&amp;nbsp;&amp;nbsp; // conector digitala para o LED&amp;nbsp; no pino 13&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;void setup()&amp;nbsp;&amp;nbsp; {&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&amp;nbsp; // inicia a saida digital para o pino:&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&amp;nbsp; pinMode(ledPin, OUTPUT);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;}&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;//&amp;nbsp; o metodo loop() é o metodo onde são colocados os outros metodos ou o programa em si, esse metodo fica dando voltas, ou seja, ele fica repetindo codigo que esta dentro dele, neste caso faz com que o acenda e apague o LED&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;void loop()&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;{&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&amp;nbsp; digitalWrite(ledPin, HIGH);&amp;nbsp;&amp;nbsp; // liga o LED&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&amp;nbsp; delay(500);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // tempo em milisegundos que o LED permanecera aceso ( delay em uma tradução livre significa atrazo)&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&amp;nbsp; digitalWrite(ledPin, LOW);&amp;nbsp;&amp;nbsp;&amp;nbsp; // desliga o LED&lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;&amp;nbsp; delay(1000);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/div&gt;&lt;div style=&quot;color: red;&quot;&gt;}&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Esse foi o primeiro programa, muito basico, mas interesante para ter uma noção de como funciona.&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://leandro-robotica.blogspot.com/feeds/1534962829979371220/comments/default' title='Postar comentários'/><link rel='replies' type='text/html' href='http://leandro-robotica.blogspot.com/2010/06/primeiro-teste-com-placa-arduino.html#comment-form' title='0 Comentários'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/1534962829979371220'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7139318771131456504/posts/default/1534962829979371220'/><link rel='alternate' type='text/html' href='http://leandro-robotica.blogspot.com/2010/06/primeiro-teste-com-placa-arduino.html' title='Primeiro teste com placa arduino'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/12283119063430851656</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/_zdjXm2HhBPM/TCTuOYPEwVI/AAAAAAAAAEU/21L9Gt7L3gw/s72-c/seeeduino3281.jpg" height="72" width="72"/><thr:total>0</thr:total></entry></feed>