tag:blogger.com,1999:blog-15667446936402215062024-03-27T11:40:08.266-07:00ZenElectroDhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.comBlogger47125tag:blogger.com,1999:blog-1566744693640221506.post-34608826005910247132022-03-20T23:26:00.003-07:002022-03-20T23:26:28.177-07:00<h2>Python Mediapipe hand tracking with Augmented Reality. Load OBJ model python. #mediapipepython</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/14Axu-ki8ZU" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-90550423470772443792022-03-05T22:02:00.003-08:002022-03-05T22:02:18.847-08:00<h2>
Tarot t810 DSLR 1300D survey drone. Survey report with DEM info. #T810</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/E_DpyWkbPzU" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-12618285594205748582022-03-05T22:01:00.001-08:002022-03-05T22:01:10.836-08:00<h2>
Raspberry pi openGL setup and Hello world program</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/NBGMeGEDVY4" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-50555116300842265092022-03-05T21:59:00.002-08:002022-03-05T21:59:41.159-08:00<h2>
Arduino OBD Simulator #arduino obd2 #arduino obd2 shield #arduino obd ii #arduino obd reader</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/6bu9Dwti1tU" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-2691024617455454322022-03-05T21:58:00.006-08:002022-03-05T21:58:51.677-08:00<h2>
SPI communication between two STM32 microcontrollers / SPL library SPI master slave #stm32f103c8t6</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/wzOjVhEkk3c" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-84295582201874496102022-03-05T21:58:00.001-08:002022-03-05T21:58:04.340-08:00<h2>
STM32 with FreeRTOS - Multiple task and Software Timer in 17min #freertos #STM32 #multitasking</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/hTnne5Pkraw" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-25505858641583718942022-03-05T21:56:00.004-08:002022-03-05T21:56:42.445-08:00<h2>
Sipeed Lichee Nano Linux Development Board | Build root lichee pi | Linux development board</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/bpim-m2GKF0" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-4553072640793322472022-03-05T21:55:00.002-08:002022-03-05T21:55:17.559-08:00<h2>
ESP32 FTP Client, download files in SDCARD #FTP #ESP32 #SERVER #W5100 #LAN8720 #ENC28j60</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/ofRWScWrm0E" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-63465358506513014182020-06-18T23:49:00.001-07:002020-06-18T23:49:16.505-07:00nRF51822 - Get started - nordicsemi.com, Stlink v2 and Keil<iframe allowfullscreen="" frameborder="0" height="270" src="https://www.youtube.com/embed/NnOZml3nKvk" width="480"></iframe>Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-44143576975854654142017-06-06T23:48:00.003-07:002017-06-06T23:48:28.031-07:00ESP3212 BLE+WiFi : GATT Server + TCP Server<h2>
ESP3212 BLE GATT server and WiFi TCP server :</h2>
<br />
<div style="text-align: center;">
<iframe allowfullscreen="" frameborder="0" height="270" src="https://www.youtube.com/embed/vsePGjtwN0U" width="480"></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-55810529830780045782017-05-24T23:34:00.001-07:002022-03-05T21:53:17.067-08:00ATTiny85 with OLED Display interfacing and upload custom image in Displa...<h2>
ATTiny85 with OLED Display interfacing and upload custom image in Display:</h2>
<div>
<br /></div>
<div style="text-align: center;">
<iframe allowfullscreen="" frameborder="0" height="270" src="https://www.youtube.com/embed/z0WKXSjfcac" width="480"></iframe></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com1tag:blogger.com,1999:blog-1566744693640221506.post-38793348269735559712017-05-22T11:53:00.001-07:002017-05-22T11:53:03.076-07:00Nokia 5110 LCD Display Interface with Arduino<h2>
<span style="font-size: x-large;">Nokia 5110 LCD Display Interface with Arduino
:</span></h2>
<h2>
<span style="font-size: x-large;"> </span><iframe allowfullscreen="" frameborder="0" height="270" src="https://www.youtube.com/embed/HdE7lTA0D04" width="480"></iframe></h2>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-26042397642067328622017-05-13T05:15:00.001-07:002017-05-13T05:15:55.658-07:00Assemble Your First Quad copter #1<h2 style="text-align: center;">
Start collecting part for Your first Drone</h2>
<div>
<br /></div>
<iframe allowfullscreen="" frameborder="0" height="270" src="https://www.youtube.com/embed/ZXVy2-OPfh4" width="480"></iframe><br />
<br />
<br />Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-75811998150434537702017-04-27T03:25:00.001-07:002017-05-22T11:58:30.712-07:00External 2.5" Inch IDE / PATA HDD Casing USB 2.0 for LAPTOP , Notebook H...<div dir="ltr" style="text-align: left;" trbidi="on">
<h2 style="text-align: left;">
<span style="font-size: large;">External 2.5" Inch IDE / PATA HDD Casing USB 2.0 for LAPTOP , Notebook HARD DISK Unboxing :</span></h2>
<br />
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
<br /><iframe allowfullscreen="" frameborder="0" height="344" src="https://www.youtube.com/embed/_c_GEfM-y-w" width="459"></iframe></div>
</div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-1510745934269498182017-04-01T13:46:00.000-07:002017-04-01T13:46:12.035-07:00<div dir="ltr" style="text-align: left;" trbidi="on">
<h2 style="text-align: left;">
<b><u>Start making IoT based product:</u></b></h2>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://3.bp.blogspot.com/-isgm4yoUViM/WOARiasvQwI/AAAAAAAAIk0/Cb4T4IdnCvkjs-dzqnjsVPGEaLZcLKSMgCLcB/s1600/IOT.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="234" src="https://3.bp.blogspot.com/-isgm4yoUViM/WOARiasvQwI/AAAAAAAAIk0/Cb4T4IdnCvkjs-dzqnjsVPGEaLZcLKSMgCLcB/s640/IOT.jpg" width="640" /></a></div>
<div>
<b><u><br /></u></b></div>
<div>
<b><u><br /></u></b></div>
<div>
<b><u><br /></u></b></div>
Internet is the virtual world where users are interested in accessing,editing and controlling data.Everyone is eyeing the next big thing in the internet.Now days market booming with the IoT. Internet of Things is the extended form of internet. Real world is connected through virtual world. In an era of electronics based civilization there is always a demand for more better,cheaper and faster electronics devices. These are the key points for the IoT based products development. Main feature of IoT based product is to give remote access of device to the user. Even device which is controllable from Bluetooth is also a IoT device. The end to end form of IoT make that device controllable from any corner of the world.<br />
<div style="text-align: left;">
<br />
<h3 style="text-align: left;">
<b>How to step in IoT market ?</b></h3>
<b><u>Product design Flow:</u></b><br />
<u>Design and Specification finalization:</u><br />
The very first step in product development is to define aspects and specification of product which can not be change through the end of production. If their is any changes in product it can only reflect in phase 2 or version 2 of product.<br />
<span style="color: #a64d79;"> Ex. I am thinking of designing box which having WiFi connectivity and control home equipment from any where in world. </span><br />
<br />
<span style="color: #a64d79;"><u>Specifications: </u></span><br />
<span style="color: #a64d79;">*device for consumer application</span><br />
<span style="color: #a64d79;">*costing of product manufacturing and selling</span><br />
<span style="color: #a64d79;">*small box,nice color,LED indications,proper terminals for external connections, having 5v power supply</span><br />
<span style="color: #a64d79;">*WiFi connectivity</span><br />
<span style="color: #a64d79;">*controls 3 equipment. you can make variant of same device based of capacity of handling equipment.</span><br />
<br />
<b><span style="color: #a64d79;"><span style="color: black;"><u>Prototyping and Development phase:</u></span></span></b><br />
<br />
<b><span style="color: #a64d79;"><span style="color: black;">*Hardware : </span></span></b><br />
<span style="color: #a64d79;"><span style="color: black;">Hardware is directly related with costing of product. Its very necessary to choose proper hardware that can satisfy device working needs. Its wast of money to choose higher end processors and Industrial grade hard ware because we are developing </span></span><span style="color: #a64d79;"><span style="color: black;">Consumer Electronics device.</span></span><br />
<br />
<b><span style="color: #a64d79;"><span style="color: black;">*Software :</span></span></b><br />
<span style="color: #a64d79;"><span style="color: black;">For reducing development cost here we have to choose mostly free ware development tools and compilers mostly GCC considering GNU licenses or IDE like Arduino is ok.</span></span><br />
<span style="color: #a64d79;"><span style="color: black;">need to read some of the license documents like if you use Arduino in product development. </span></span><br />
<span style="color: #a64d79;"><span style="color: black;"> http://www.postscapes.com/forum/arduino/47-if-arduino-is-for-prototyping-how/when-do-you-make-the-actual-product/</span></span><br />
<br />
<span style="color: #c27ba0;"><span style="color: #a64d79;"><span style="color: black;">Selection:</span></span></span><br />
<span style="color: #c27ba0;"><span style="color: #a64d79;"><span style="color: black;">doing some market survey I choose cheap WiFi module ESP8266 which can work with Node MCU. It reduce my need of any other micro controller to be used. And ESP8266 can program easily with free tool provided my manufacturer. </span></span></span><br />
<br />
<b><span style="color: #a64d79;"><span style="color: black;"><u>Validation Phase:</u></span></span></b><br />
<span style="color: #a64d79;"><span style="color: black;">This is step after product design cycle. Design that was finalized in the lab for testing, to ensure that all products specifications are met. Required certification should be obtained for product, depending on where it is going to be launch.</span></span><br />
<br />
<span style="color: #c27ba0;"><span style="color: #a64d79;"><span style="color: black;">Validation :</span></span></span><br />
<span style="color: #c27ba0;"><span style="color: #a64d79;"><span style="color: black;">depends on your region like here in India we have to certify our products with ISI mark. </span></span></span><br />
<br /><span style="color: #c27ba0;"></span>
<span style="color: #c27ba0;"></span><br />
<span style="color: #c27ba0;"></span><br />
<span style="color: #c27ba0;"></span><br />
<u>
<span style="color: #a64d79;"><span style="color: black;"><b>Production phase:</b></span></span></u><br />
Its time to turn your prototype into product. In this phase we have to introduce some third party suppliers for manufacturing PCB,Component soldering,device housing and packing. following points should be considering while allocating third part suppliers.<br />
*go with reliable vendors.<br />
*make proper agreements and legal documents.<br />
*consider Time to Market then negotiate with vendors.<br />
*before giving direct order demand for samples.<br />
*consider cost of manufacturing.<br />
<br />
<span style="color: #a64d79;"><span style="color: black;"><b><u>Sales and marketing:</u></b></span></span><br />
Without knowing you no one is going to buy your product here marketing helps you. reach to your customer and market your product.<br />
*Online marketing is easy way to reach customers.<br />
*Make proper website with product descriptions.<br />
*Sell on online websites like amezon and ebay.</div>
</div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-54913119492436603682017-03-25T01:15:00.000-07:002017-04-03T13:16:55.214-07:00<div dir="ltr" style="text-align: left;" trbidi="on">
<h2 style="text-align: left;">
<u>Bluetooth Controlled Home Equipments:</u></h2>
<div class="separator" style="clear: both; text-align: center;">
<iframe width="320" height="266" class="YOUTUBE-iframe-video" data-thumbnail-src="https://i.ytimg.com/vi/AqjR0zFukeQ/0.jpg" src="https://www.youtube.com/embed/AqjR0zFukeQ?feature=player_embedded" frameborder="0" allowfullscreen></iframe></div>
<br />
<b>Basic about bluetooth:</b><br />
<br />
Bluetooth is a wireless technology standard for exchanging data over short distances (using short-wavelength UHF radio waves in the ISM band from 2.4 to 2.485 GHz) from fixed and mobile devices, and building personal area networks (PANs). Invented by telecom vendor Ericsson in 1994<br />
<iframe frameborder="0" marginheight="0" marginwidth="0" scrolling="no" src="//ws-in.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=IN&source=ss&ref=as_ss_li_til&ad_type=product_link&tracking_id=tisl0c-21&marketplace=amazon&region=IN&placement=B00R95Y0AK&asins=B00R95Y0AK&linkId=b9d1d6774c9c46d01e18c985f1a7a209&show_border=true&link_opens_in_new_window=true" style="height: 240px; width: 240px;"></iframe><br />
<b>Radio frequency communication (RFCOMM)</b><br />
<br />
The Bluetooth protocol RFCOMM is a simple set of transport protocols, made on top of the L2CAP protocol, providing emulated RS-232 serial ports (up to sixty simultaneous connections to a Bluetooth device at a time). The protocol is based on the ETSI standard TS 07.10.<br />
<br />
RFCOMM is sometimes called serial port emulation. The Bluetooth serial port profile is based on this protocol.<br />
<br />
RFCOMM provides a simple reliable data stream to the user, similar to TCP. It is used directly by many telephony related profiles as a carrier for AT commands, as well as being a transport layer for OBEX over Bluetooth.<br />
<br />
Many Bluetooth applications use RFCOMM because of its widespread support and publicly available API on most operating systems. Additionally, applications that used a serial port to communicate can be quickly ported to use RFCOMM<br />
<br />
In the protocol stack, RFCOMM is bound to L2CAP.<br />
In our project we are going to use RFCOM socket.<br />
<br />
<br />
<b>Requrments :</b><br />
<a href="http://amzn.to/2n3vCFu" target="_blank">1) Arduino</a><br />
<a href="http://amzn.to/2nh2eMD" target="_blank">2) Bluetooth module HC-05</a><br />
<a href="http://amzn.to/2n3QEDM" target="_blank">3) Relay circuit </a><br />
<a href="http://amzn.to/2nmJHjT" target="_blank">4) Connecting wires</a><br />
<br />
<b>Aim : </b>Controll Device from bluetooth<br />
<br />
<h3 style="text-align: left;">
<b>Software Design:</b></h3>
<b>Arduino code:</b><br />
Here we design simple protocol between mobile device and microcontroller to agree on some data code like.<br />
if mobile sends string 'START1' means turn on Device, if mobile sends string 'STOP1' then turn off device.<br />
And 'GETSEN' for sensor readings<br />
following code is design for do that<br />
<span style="color: #674ea7;"><br />
</span> <span style="color: #674ea7;">/*</span><br />
<span style="color: #674ea7;">Arduino Turn LED On/Off using Bluetooth </span><br />
<span style="color: #674ea7;">Created feb 6 2017</span><br />
<span style="color: #674ea7;">by Dhananjay</span><br />
<span style="color: #674ea7;">It's a simple sketch which waits for a character on serial</span><br />
<span style="color: #674ea7;">and in case of a desirable character, it turns an LED on/off.</span><br />
<span style="color: #674ea7;"><br />
</span> <span style="color: #674ea7;">Possible string values:</span><br />
<span style="color: #674ea7;">a (to turn the LED on)</span><br />
<span style="color: #674ea7;">b (tor turn the LED off)</span><br />
<span style="color: #674ea7;">*/</span><br />
<span style="color: #674ea7;">#include < softwareserial.h ></span><br />
<span style="color: #674ea7;">SoftwareSerial mySerial(10, 11); // RX, TX</span><br />
<span style="color: #674ea7;">char junk;</span><br />
<span style="color: #674ea7;">String str;</span><br />
<span style="color: #674ea7;"><br />
</span> <span style="color: #674ea7;">void setup() // run once, when the sketch starts</span><br />
<span style="color: #674ea7;">{</span><br />
<span style="color: #674ea7;"> Serial.begin(9600); // set the baud rate to 9600, same should be of your Serial Monitor</span><br />
<span style="color: #674ea7;"> mySerial.begin(9600);</span><br />
<span style="color: #674ea7;"> mySerial.setTimeout(200);</span><br />
<span style="color: #674ea7;"> pinMode(13, OUTPUT);</span><br />
<span style="color: #674ea7;"> pinMode(A0, INPUT);</span><br />
<span style="color: #674ea7;">}</span><br />
<span style="color: #674ea7;"><br />
</span> <span style="color: #674ea7;">void loop()</span><br />
<span style="color: #674ea7;">{</span><br />
<span style="color: #674ea7;"><br />
</span> <span style="color: #674ea7;"> if(mySerial.available()){</span><br />
<span style="color: #674ea7;"> while(mySerial.available())</span><br />
<span style="color: #674ea7;"> {</span><br />
<span style="color: #674ea7;"> str = mySerial.readString();</span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;"> Serial.print(str);</span><br />
<span style="color: #674ea7;"> if(str == "START1\r\n"){ //in case of 'a' turn the LED on</span><br />
<span style="color: #674ea7;"> digitalWrite(13, HIGH); </span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;"> else if(str == "STOP1\r\n"){ //in case of 'b' turn the LED off</span><br />
<span style="color: #674ea7;"> digitalWrite(13, LOW);</span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;"> else if(str == "GETSEN\r\n")// Send analogue sensor value</span><br />
<span style="color: #674ea7;"> {</span><br />
<span style="color: #674ea7;"> int anlgval = analogRead(A0)%100;</span><br />
<span style="color: #674ea7;"> mySerial.println(anlgval);</span><br />
<span style="color: #674ea7;"> Serial.println(anlgval);</span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;"><br />
</span> <span style="color: #674ea7;"><br />
</span> <span style="color: #674ea7;"> str = "";</span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;">}</span><br />
<br />
In above code we are controlling one equipment which are connected to relay from <span style="color: #0000ee;"><u>A</u></span>rduino pin 13.<br />
You can increase count of equipment by adding extra if conditions .<br />
<br />
<b>Android code:</b><br />
Now its some hard part of this project as electronics guys dont know android coding but dont worry is not so hard if you know some basics of OOPS and how to deal with Java. You need to install Arduino IDE with along proper Android SDK. If you SDK is latest and not supported by following code then you need to mange Android studio to compile following code.<br />
<b><br />
</b> <b>Sreen shot given as:</b><br />
<br />
<b>Code in Android studio:</b><br />
Download the rar file it contains source code of simple android app written by me. You can customize it. Open Android Studio and open project.<br />
Structure of project:<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-3B7QGoj7ao0/WJiFivlso-I/AAAAAAAAIZ4/gtKUISUj-SMrezCO6_KeKQ58eWmIAt8LQCK4B/s1600/Untitled.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://1.bp.blogspot.com/-3B7QGoj7ao0/WJiFivlso-I/AAAAAAAAIZ4/gtKUISUj-SMrezCO6_KeKQ58eWmIAt8LQCK4B/s1600/Untitled.jpg" /></a></div>
<br />
method for write data to HC05:<br />
<div class="separator" style="clear: both; text-align: center;">
<img border="0" src="https://1.bp.blogspot.com/-mQjVnoBvjR0/WJiFibyFtlI/AAAAAAAAIZw/D0J1XCag69koiVPwgUjYCKiOUfqXZamuQCK4B/s1600/3.jpg" /></div>
<div class="" style="clear: both; text-align: left;">
<br /></div>
<div class="" style="clear: both; text-align: left;">
Method for receive String from HC05</div>
<div class="separator" style="clear: both; text-align: center;">
<img border="0" src="https://1.bp.blogspot.com/-N6fNhcyyfg0/WJiFiUutSEI/AAAAAAAAIZs/dUNoJypehigHLeGfunm9ieY_MW8rP77ygCK4B/s1600/4.jpg" /></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<div class="separator" style="clear: both; text-align: left;">
Gradal build settings:</div>
<div class="separator" style="clear: both; text-align: center;">
<img border="0" src="https://1.bp.blogspot.com/-s2piK66VW48/WJiFibSNykI/AAAAAAAAIZo/fXBY_acwVzQ2dDwts84hgFN48gGJAhaQwCK4B/s1600/2.jpg" /></div>
<div class="separator" style="clear: both; text-align: center;">
<br /></div>
<div class="separator" style="clear: both; text-align: left;">
<br /></div>
<h3 style="text-align: left;">
<b>Hardware Design:</b></h3>
<b>HC-05 :</b><br />
<h4 style="text-align: left;">
HC-05 PinOut (Right) :</h4>
<div id="toc2" style="text-align: center;">
<a href="http://4.bp.blogspot.com/-SvRP5nVmp9c/WJd2pElCNFI/AAAAAAAAIZM/DqUvllCFyKcpE9UXwmBt8HzzgfIh5RJvACK4B/s1600/BT-HC-05-Back-400.jpg" imageanchor="1"><img border="0" height="170" src="https://4.bp.blogspot.com/-SvRP5nVmp9c/WJd2pElCNFI/AAAAAAAAIZM/DqUvllCFyKcpE9UXwmBt8HzzgfIh5RJvACK4B/s400/BT-HC-05-Back-400.jpg" width="400" /></a></div>
<ul>
<li>KEY: If brought HIGH <b>before</b> power is applied, forces AT Command Setup Mode. LED blinks slowly (2 seconds)</li>
<li>VCC: +5 Power</li>
<li>GND: System / Arduino Ground</li>
<li>TXD: Transmit Serial Data from HC-05 to Arduino Serial Receive. NOTE: 3.3V HIGH level: OK for Arduino</li>
<li>RXD: Receive Serial Data from Arduino Serial Transmit</li>
<li>STATE: Tells if connected or not</li>
</ul>
<br />
<h3 id="toc5">
COMMAND and DATA TRANSFER MODE:</h3>
<div>
The module has two modes of operation, Command Mode where we can send AT commands to it and Data Mode where it transmits and receives data to another bluetooth module.<br />
The default mode is DATA Mode, and this is the default configuration, that may work fine for many applications:<br />
<br /></div>
<div>
<div style="text-align: left;">
<b>COMMAND :</b></div>
</div>
<div>
In some cases you may want to change some of the configuration setup values. There are two ways to get into Command Mode.<br />
<span style="line-height: 1.5;">Connect the KEY/WAKEUP pin high <b>before</b> applying power to the module. This will put the module into command mode at 38400 baud. This is commonly used, and needed if you don't know the baud rate the module is set to<span style="background-color: white;">.</span></span><br />
<span style="line-height: 1.5;"><span style="background-color: white;">AT+ROLE=0 : </span></span><span style="font-family: "lucida grande" , "lucida sans unicode" , "verdana" , "arial" , "helvetica" , sans-serif; font-size: 12.8px;">You can change role by</span><span style="font-family: "lucida grande" , "lucida sans unicode" , "verdana" , "arial" , "helvetica" , sans-serif; font-size: 12.8px;"><span style="font-size: small;"> </span></span><span style="font-family: "lucida grande" , "lucida sans unicode" , "verdana" , "arial" , "helvetica" , sans-serif; font-size: 12.8px;">0 for SLAVE & 1 for Master. Leave it as 0 as we want this module to be SLAVE.</span><br />
<span style="font-family: "lucida grande" , "lucida sans unicode" , "verdana" , "arial" , "helvetica" , sans-serif; font-size: 12.8px;">AT+NAME=DKS_BLUE : change name of device which is brodcast</span><br />
<span style="line-height: 1.5;"><br />
</span></div>
<div>
<div style="text-align: left;">
<b>DATA TRANSFER MODE:</b></div>
<div style="text-align: left;">
Open KEY?WAKEUP pin dont connect it anywhere then power up module it is in now Data Transfer mode. Whatever data you send to the module from serial terminal that get transfer to the connected device via RFCOM.</div>
</div>
<ul>
<li><span style="line-height: 1.5;">Baud Rate: 9600 bps, Data : 8 bits, Stop Bits: 1 bit, Parity : None, Handshake: None</span></li>
<li><span style="line-height: 1.5;">Passkey: 1234</span></li>
<li><span style="line-height: 1.5;">Device Name: HC-05</span></li>
</ul>
<b>Connection Diagram:</b><br />
<br />
<a href="http://3.bp.blogspot.com/-3i1KkqoobIw/WJm0M6CIlqI/AAAAAAAAIaw/QZzleTHBIIcSHv7PpwpVqOinKW2oUSFpwCK4B/s1600/hc-05-LED%2Bblink%2BCircuit.png" imageanchor="1"><img border="0" height="232" src="https://3.bp.blogspot.com/-3i1KkqoobIw/WJm0M6CIlqI/AAAAAAAAIaw/QZzleTHBIIcSHv7PpwpVqOinKW2oUSFpwCK4B/s640/hc-05-LED%2Bblink%2BCircuit.png" width="640" /></a><br />
<br />
<br />
<span style="line-height: 1.5;">make this connection to operate bulb from bluetooth.<br />
</span> <br />
<span style="line-height: 1.5;"><br />
</span> <span style="line-height: 1.5;"><br />
</span> <br />
<span style="line-height: 1.5;"></span></div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com1tag:blogger.com,1999:blog-1566744693640221506.post-56827978218410387542017-03-25T01:07:00.001-07:002017-03-25T01:07:29.759-07:00<div dir="ltr" style="text-align: left;" trbidi="on">
<div>
<h2 style="text-align: left;">
<u>Line follower car :</u></h2>
<b>Aim:</b><br />
Create Arduino based Line follower robot from scratch.<br />
<br />
It is a machine that follows a line, either a black line on white surface or vise-versa. For Beginners it is usually their first robot to play with. In this tutorial, we will teach you to make the line follower robot move on the line with a type of feedback mechanism. It’s the most basic example of adding small intelligence to a robot, but it’s actually the designer’s intelligence!!<br />
<br />
<b>Requirement:</b><br />
1) Arduino Uno <complete id="goog_1250410736">+ Arduino IDE</complete><br />
2) DC geared motors x 2<br />
3) Power bank or 9v or 12v Battery<br />
4) IR sensors (ready made or You can make it by your own)<br />
5) Connecting wires<br />
6) Motor driver ready made or Your own.<br />
Working of sensors:<br />
<br />
IR light is invisible to human eyes it can be detected using IR sensore. As shown in picture below IR LED which is act as Transmitter and Photo Diode act as receiver. When Infrared Light strike on white surface its get reflect back and received by photo diode, while in other case IR Light is absorb by black surface so Photo diode is ideal stat.<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-IzibMy5pR2Q/WJMv53qiAXI/AAAAAAAAIT8/j-CYRTBkcY4o3Oe2JKTLoN1BlqKldpqBACK4B/s1600/IRsensor.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="190" src="https://3.bp.blogspot.com/-IzibMy5pR2Q/WJMv53qiAXI/AAAAAAAAIT8/j-CYRTBkcY4o3Oe2JKTLoN1BlqKldpqBACK4B/s320/IRsensor.jpg" width="320" /></a></div>
<div class="" style="clear: both; text-align: left;">
We need to convert these signals to 0-5v so we use OPAM IC lm358 or ready made sensor.</div>
Software Design:<br />
We are designing algorithm for following conditions detected by IR sensors.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<img border="0" height="123" src="https://2.bp.blogspot.com/-C6ls1jewWMo/WJMv6D8wHvI/AAAAAAAAIUE/T9UavftTHM8fmbd2bjcKjPulyzhqFglhQCK4B/s320/turn%2Balgorithm.jpg" width="320" /> </div>
<div class="separator" style="clear: both; text-align: left;">
In first condition left sensor detect black line so we need to turn lef so both IR sensors should be on white colour. same in other case if right sensor detect black line turn right to come back both sensor to white surface.</div>
<div class="separator" style="clear: both; text-align: left;">
now decide the turn mechanism for robot. </div>
<br />
<div class="separator" style="clear: both; text-align: center;">
<img border="0" height="462" src="https://4.bp.blogspot.com/-fwfEfh5OBUk/WJMv6XbBNAI/AAAAAAAAIUM/_hdBBBlspsM5HYWN4Admeho6Ky2qe9HaACK4B/s640/turn.jpg" width="640" /></div>
<b>Truth Table:</b><br />
<br />
For Half Turn: <br />
<span style="color: #e06666;">Sensor Left | Sensor Right | Motor Left | Motor Right</span><br />
<span style="color: #e06666;">black black off off</span><br />
<span style="color: #e06666;">black white off on</span><br />
<span style="color: #e06666;">white black on off</span><br />
<span style="color: #e06666;">white white on on</span><br />
<br />
<b>For Full Turn:</b><br />
<span style="color: #e06666;">Sensor Left | Sensor Right | Motor Left | Motor Right</span><br />
<span style="color: #e06666;">black black off off</span><br />
<span style="color: #e06666;">black white reverse forward</span><br />
<span style="color: #e06666;">white black forward reverse</span><br />
<span style="color: #e06666;">white white forward forward</span><br />
<br />
In above cases<br />
<ul style="text-align: left;">
<li>half turn: it is stable and less fluctuate robot while running</li>
</ul>
<ul style="text-align: left;">
<li>full turn : suitable for hard and narrow turns.</li>
</ul>
</div>
<div style="text-align: left;">
Here we write code for half turn mechanism you can modify code for full turn.</div>
<div style="text-align: left;">
//motor A<br />
<span style="color: #674ea7;">#define M11 5</span><br />
<span style="color: #674ea7;">#define M12 6</span><br />
<span style="color: #674ea7;"><br /></span>
<span style="color: #674ea7;">//motor b</span><br />
<span style="color: #674ea7;">#define M23 7</span><br />
<span style="color: #674ea7;">#define M24 8</span><br />
<span style="color: #674ea7;"><br /></span>
<span style="color: #674ea7;">//Sensore</span><br />
<span style="color: #674ea7;">#define lSen 3 </span><br />
<span style="color: #674ea7;">#define rSen 4</span><br />
<span style="color: #674ea7;"><br /></span>
<span style="color: #674ea7;">void setup()</span><br />
<span style="color: #674ea7;">{ </span><br />
<span style="color: #674ea7;"> pinMode(M11, OUTPUT);</span><br />
<span style="color: #674ea7;"> pinMode(M12, OUTPUT);</span><br />
<span style="color: #674ea7;"> pinMode(M21, OUTPUT);</span><br />
<span style="color: #674ea7;"> pinMode(M22, OUTPUT);</span><br />
<span style="color: #674ea7;"> pinMode(lSen,INPUT);</span><br />
<span style="color: #674ea7;"> pinMode(rSen,INPUT);</span><br />
<span style="color: #674ea7;"> </span><br />
<span style="color: #674ea7;"> digitalWrite(M11,LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M12,LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M21,LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M21,LOW);</span><br />
<span style="color: #674ea7;"><br /></span>
<span style="color: #674ea7;"> delay(1000);</span><br />
<span style="color: #674ea7;">}</span><br />
<span style="color: #674ea7;"><br /></span>
<span style="color: #674ea7;">void loop()</span><br />
<span style="color: #674ea7;">{</span><br />
<span style="color: #674ea7;"> readLsen = digitalRead(lSen);</span><br />
<span style="color: #674ea7;"> readRsen = digitalRead(rSen);</span><br />
<span style="color: #674ea7;"><br /></span>
<span style="color: #674ea7;"> if((readLsen == 0) && (readRsen == 0))//if both sensors on black colour then stop both motors</span><br />
<span style="color: #674ea7;"> {</span><br />
<span style="color: #674ea7;"> stop();</span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;"> else if((readLsen == 1) && (readRsen == 0))//if left sensor on white and right sensor on black turn right</span><br />
<span style="color: #674ea7;"> {</span><br />
<span style="color: #674ea7;"> turnRight();</span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;"> else if((readLsen == 0) && (readRsen == 1))//if left sensor on black and right sensor on white turn left</span><br />
<span style="color: #674ea7;"> {</span><br />
<span style="color: #674ea7;"> turnLeft(); </span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;"> else if((readLsen == 1) && (readRsen == 1))//if both sensor on white move forward</span><br />
<span style="color: #674ea7;"> {</span><br />
<span style="color: #674ea7;"> moveForward();</span><br />
<span style="color: #674ea7;"> }</span><br />
<span style="color: #674ea7;">}</span><br />
<span style="color: #674ea7;"><br /></span>
<span style="color: #674ea7;">void turnRight() {</span><br />
<span style="color: #674ea7;"> digitalWrite(M11, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M12, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M21, HIGH);</span><br />
<span style="color: #674ea7;"> digitalWrite(M22, LOW);</span><br />
<span style="color: #674ea7;">}</span><br />
<span style="color: #674ea7;">void stop () {</span><br />
<span style="color: #674ea7;"> digitalWrite(M11, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M12, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M21, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M22, LOW);</span><br />
<span style="color: #674ea7;">}</span><br />
<span style="color: #674ea7;">void turnLeft() {</span><br />
<span style="color: #674ea7;"> digitalWrite(M11, HIGH);</span><br />
<span style="color: #674ea7;"> digitalWrite(M12, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M21, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M22, LOW);</span><br />
<span style="color: #674ea7;">}</span><br />
<span style="color: #674ea7;">void moveForward() {</span><br />
<span style="color: #674ea7;"> digitalWrite(M11, HIGH);</span><br />
<span style="color: #674ea7;"> digitalWrite(M12, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M21, HIGH);</span><br />
<span style="color: #674ea7;"> digitalWrite(M22, LOW);</span><br />
<span style="color: #674ea7;">}</span><br />
<span style="color: #674ea7;">void reverse(){</span><br />
<span style="color: #674ea7;"> digitalWrite(M11, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M12,HIGH);</span><br />
<span style="color: #674ea7;"> digitalWrite(M21, LOW);</span><br />
<span style="color: #674ea7;"> digitalWrite(M22, HIGH);</span><br />
<span style="color: #674ea7;">}</span></div>
<div style="text-align: left;">
<br /></div>
<div>
Upload this sketch in Arduino and go through hardware design.<br />
<h3 style="text-align: left;">
Hardware Design:</h3>
<br />
<h3>
Components and Their use:</h3>
<ul>
<li><b><i>12V DC motor:</i></b> If a DC power is passed on a DC motor, it will produce torque. The torque created will lead to the rotation of the wheels. It will only operate on the direct current. Here, two 12V DC motors are used. -><u> 300rpm,12v,DC motor </u></li>
</ul>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://2.bp.blogspot.com/-aY_j6DyPo2k/WJS3dvtOaMI/AAAAAAAAIWU/PGIm64Lp8BAwZClzfNoj-Oqg6Eh8A6I4QCLcB/s1600/DC_Motor_300rpm.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="236" src="https://2.bp.blogspot.com/-aY_j6DyPo2k/WJS3dvtOaMI/AAAAAAAAIWU/PGIm64Lp8BAwZClzfNoj-Oqg6Eh8A6I4QCLcB/s320/DC_Motor_300rpm.jpg" width="320" /></a><iframe frameborder="0" marginheight="0" marginwidth="0" scrolling="no" src="//ws-in.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=IN&source=ss&ref=as_ss_li_til&ad_type=product_link&tracking_id=tisl0c-21&marketplace=amazon&region=IN&placement=B00RXTVIHA&asins=B00RXTVIHA&linkId=1ee990873d213190902c43dc1da475d6&show_border=true&link_opens_in_new_window=true" style="height: 240px; width: 120px;"></iframe></div>
</div>
<br />
<ul></ul>
<div>
<ul>
<li><b><i>Zero PCB : </i></b>it is very rasy to beginners for creating their circuits on Zero PCB.->10x10cm</li>
</ul>
</div>
<div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://2.bp.blogspot.com/-JG8Yhs1KjyU/WJS37O1V7zI/AAAAAAAAIWY/XHI0N6tVEjwf64UKfDbGmwhwnx8DZ961wCLcB/s1600/images.jpeg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="269" src="https://2.bp.blogspot.com/-JG8Yhs1KjyU/WJS37O1V7zI/AAAAAAAAIWY/XHI0N6tVEjwf64UKfDbGmwhwnx8DZ961wCLcB/s400/images.jpeg" width="400" /></a><iframe frameborder="0" marginheight="0" marginwidth="0" scrolling="no" src="//ws-in.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=IN&source=ss&ref=as_ss_li_til&ad_type=product_link&tracking_id=tisl0c-21&marketplace=amazon&region=IN&placement=B01A6ZU4PO&asins=B01A6ZU4PO&linkId=5b794cddf2e604569bccf80b6d0ef353&show_border=true&link_opens_in_new_window=true" style="height: 240px; width: 120px;"></iframe></div>
</div>
<ul>
<li><b><i>Battery:</i></b> This robot is powered by a battery. One 9V battery is enough to perform this process. For more usages, four 9V batteries may be required.-> 9v or powerbank</li>
</ul>
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-aHCH1g7Mk_g/WJS4rQckuzI/AAAAAAAAIWk/8rHTwdBMJ7o7V7qk6pSNleLLUXPWWssSwCK4B/s1600/51SvbeosnUL._SL1000_.jpg" imageanchor="1"><img border="0" height="320" src="https://4.bp.blogspot.com/-aHCH1g7Mk_g/WJS4rQckuzI/AAAAAAAAIWk/8rHTwdBMJ7o7V7qk6pSNleLLUXPWWssSwCK4B/s320/51SvbeosnUL._SL1000_.jpg" width="320" /></a> </div>
<ul>
<li><b><i>IR sensor circuit</i>:</b> This process requires two IR sensor circuits. An IR sensor circuit will include an IC LM358N, potentiometer, IR receiver, and IR transmitter for sensing the black lines or go for Ready made sensor here I used one ready made and one is made by me on zero pcb .</li>
</ul>
<img border="0" height="156" src="https://1.bp.blogspot.com/-spKIRxiKgeg/WJMv8G9jnaI/AAAAAAAAIUk/_3AZP8tTRY8MO8cZCe0j5IDTvm63Nb_HQCK4B/s320/IMG_20170202_130749_HDR.jpg" width="320" /><img border="0" height="179" src="https://3.bp.blogspot.com/-vznAX0HVCJs/WJMv8vU7gsI/AAAAAAAAIUs/NZVC1nVI4x8ftxH1xRWmyqnG691wiO6rACK4B/s320/IMG_20170202_130632_HDR.jpg" width="320" /><iframe frameborder="0" marginheight="0" marginwidth="0" scrolling="no" src="//ws-in.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=IN&source=ss&ref=as_ss_li_til&ad_type=product_link&tracking_id=tisl0c-21&marketplace=amazon&region=IN&placement=B019DULG1E&asins=B019DULG1E&linkId=1a8c1816ff1b7829d657c255b3d7e876&show_border=true&link_opens_in_new_window=true" style="height: 240px; width: 120px;"></iframe><br />
<ul>
<li><b><i>Battery connector</i>:</b> It is used to connect the battery with the circuit.</li>
</ul>
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-bFVFSupIQVs/WJS5nb34zCI/AAAAAAAAIXA/LfhUFRUYslUMdhbKU4aSW4Shp-dCl6P4ACK4B/s1600/%2524_35.JPG" imageanchor="1"><img border="0" src="https://4.bp.blogspot.com/-bFVFSupIQVs/WJS5nb34zCI/AAAAAAAAIXA/LfhUFRUYslUMdhbKU4aSW4Shp-dCl6P4ACK4B/s400/%2524_35.JPG" /></a></div>
<ul>
<li><b><i>IC LM358N:</i></b> It is an operational amplifier or comparator used to evaluate the voltage current. The high amount of voltage gained will be considered as the output. It is one of the main components of an IR sensor circuit. </li>
</ul>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-zwwTWrTG01Y/WJMv7BoTHzI/AAAAAAAAIUc/y_3EUgc2E8IBgwoo0b_4WbKG6rX033aOwCK4B/s1600/IR-Circuit-Diagram.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="298" src="https://1.bp.blogspot.com/-zwwTWrTG01Y/WJMv7BoTHzI/AAAAAAAAIUc/y_3EUgc2E8IBgwoo0b_4WbKG6rX033aOwCK4B/s640/IR-Circuit-Diagram.jpg" width="640" /></a></div>
<div>
<ul>
<li><b><i>IC L293D:</i></b> It allows the DC motor to run in both front and back directions. It consists of up to 16 pins.</li>
</ul>
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-5yCVzwIukOU/WJS6VymuzxI/AAAAAAAAIXM/lxJXoAwC8Ss-xyOLHcVJVRQ43XNDVNbvACK4B/s1600/l293d-based-motor-driver.png" imageanchor="1"><img border="0" height="327" src="https://4.bp.blogspot.com/-5yCVzwIukOU/WJS6VymuzxI/AAAAAAAAIXM/lxJXoAwC8Ss-xyOLHcVJVRQ43XNDVNbvACK4B/s400/l293d-based-motor-driver.png" width="400" /></a> </div>
<div style="text-align: center;">
</div>
<div style="text-align: center;">
</div>
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-lvg_t1UL5Lo/WJMv-OxieWI/AAAAAAAAIVE/p2vUmAUOeaAfHzEhmASn8LkmIKQgOX6WgCK4B/s1600/IMG_20170202_123023_HDR.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="248" src="https://4.bp.blogspot.com/-lvg_t1UL5Lo/WJMv-OxieWI/AAAAAAAAIVE/p2vUmAUOeaAfHzEhmASn8LkmIKQgOX6WgCK4B/s320/IMG_20170202_123023_HDR.jpg" width="320" /></a></div>
</div>
here mine is four motor driver but I am using only two motor driver.<br />
<ul>
<li><b><i>Two plastic wheels:</i></b> The plastic wheels will be connected to the DC motors. As soon as they create the torque, these wheels will help the robot to move.</li>
</ul>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-9cuwECWzpbI/WJMv-ww6DRI/AAAAAAAAIVM/T89cFjbGsO8e5hFOA1mEdSYlXh8Ch4_DQCK4B/s1600/IMG_20170202_123208_HDR.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="240" src="https://3.bp.blogspot.com/-9cuwECWzpbI/WJMv-ww6DRI/AAAAAAAAIVM/T89cFjbGsO8e5hFOA1mEdSYlXh8Ch4_DQCK4B/s320/IMG_20170202_123208_HDR.jpg" width="320" /></a><iframe frameborder="0" marginheight="0" marginwidth="0" scrolling="no" src="//ws-in.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=IN&source=ss&ref=as_ss_li_til&ad_type=product_link&tracking_id=tisl0c-21&marketplace=amazon&region=IN&placement=B0126IQ3D6&asins=B0126IQ3D6&linkId=339e92b5451399dff5b97ef604d0bf2e&show_border=true&link_opens_in_new_window=true" style="height: 240px; width: 120px;"></iframe></div>
<ul>
<li><b><i>Ball wheel:</i></b> The castor wheel or ball wheel is used to make the movements easy and quick even it has large components on its top. In this process, a small stainless steel castor could be the best one to use. </li>
</ul>
<div style="text-align: center;">
<a href="http://2.bp.blogspot.com/-LBbZ329iyxo/WJS6u_5QSOI/AAAAAAAAIXU/v84AcP01ar0FV-NooAZcgzdSKJsWgqZXgCK4B/s1600/round-large-caster-wheel-ball-round-caster-bull-s-eye-wheel-robots-model-making-load-10KG.jpg" imageanchor="1"><img border="0" src="https://2.bp.blogspot.com/-LBbZ329iyxo/WJS6u_5QSOI/AAAAAAAAIXU/v84AcP01ar0FV-NooAZcgzdSKJsWgqZXgCK4B/s400/round-large-caster-wheel-ball-round-caster52ab4fea2a6a3d0&show_border=true&link_opens_in_new_window=true" style="height: 240px; width: 120px;" /></a><iframe frameborder="0" marginheight="0" marginwidth="0" scrolling="no" src="//ws-in.amazon-adsystem.com/widgets/q?ServiceVersion=20070822&OneJS=1&Operation=GetAdHtml&MarketPlace=IN&source=ss&ref=as_ss_li_til&ad_type=product_link&tracking_id=tisl0c-21&marketplace=amazon&region=IN&placement=B00S153B5C&asins=B00S153B5C&linkId=d6668adbac5518e8ad07dd3dadd95a61&show_border=true&link_opens_in_new_window=true" style="height: 240px; width: 120px;"></iframe></div>
<ul>
<li><b><i>Wires (single-core-multi stand & single-core-single stand):</i></b> single core multi stand wires are implemented for connecting the motor drives, and the single core single stand wires are used to connect on the zero PCB. Two meters of each wire will be required<b><i>.</i></b></li>
</ul>
<b><i></i></b><br />
<ul>
<li><b><i>Chasee mounting :</i></b></li>
</ul>
<b><i> </i></b>Chasee can be made with Metal,Hard Plastic, Plywood or Acrylic sheet. In image I made This chasee with acrylic sheet and drill it to fit L shape motor holding clips.<br />
<div>
<a href="http://4.bp.blogspot.com/-DREdXs3sXys/WJMv9IKiucI/AAAAAAAAIU0/Rkalcohs5-kKz6u-sySWCEVXJ6HX1bf0gCK4B/s1600/IMG_20170202_123103_HDR.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="300" src="https://4.bp.blogspot.com/-DREdXs3sXys/WJMv9IKiucI/AAAAAAAAIU0/Rkalcohs5-kKz6u-sySWCEVXJ6HX1bf0gCK4B/s400/IMG_20170202_123103_HDR.jpg" width="400" /></a></div>
<div style="text-align: left;">
<b><i><br />
</i></b></div>
<div>
<ul></ul>
Final Connection diagram with Arduino.<br />
Here I mount L293d motor driver on Arduino but you can use Arduino motor shield instead.<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-h4yRdBpMBPo/WJWLSl5Y4HI/AAAAAAAAIX4/xWPEdt_SPPYLGH50ETIhr1kOVsqMAOIbwCK4B/s1600/Untitled.jpg" imageanchor="1"><img border="0" height="358" src="https://2.bp.blogspot.com/-h4yRdBpMBPo/WJWLSl5Y4HI/AAAAAAAAIX4/xWPEdt_SPPYLGH50ETIhr1kOVsqMAOIbwCK4B/s640/Untitled.jpg" width="640" /></a></div>
<br />
<br />
<br />
Make all connections shown in figure and assemble it on chasee use double side tape for attach sensors and battery to chasee or use spacer and screw to tight all parts.<br />
<br />
<a href="http://4.bp.blogspot.com/-OppE89IjOHQ/WJWMuUijXFI/AAAAAAAAIYE/4dC8NbfALLIH1YsdaGoEpY_gOOdWVZIkwCK4B/s1600/img_0504.jpg" imageanchor="1"><img border="0" height="240" src="https://4.bp.blogspot.com/-OppE89IjOHQ/WJWMuUijXFI/AAAAAAAAIYE/4dC8NbfALLIH1YsdaGoEpY_gOOdWVZIkwCK4B/s320/img_0504.jpg" width="320" /></a><br />
<br />
Thank you. if you like post please like it<br />
<br />
<div style="text-align: center;">
</div>
</div>
</div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-84774246862815857062017-02-01T04:27:00.000-08:002017-08-29T21:29:55.265-07:00<div dir="ltr" style="text-align: left;" trbidi="on"><h1 class="post-title entry-title">ESP 8266 OTA(Over The Air) Update Firmware Demo :</h1><div dir="ltr" style="text-align: left;" trbidi="on"><div dir="ltr" style="text-align: left;" trbidi="on"><b><a href="http://1.bp.blogspot.com/-ric2vMgkW7E/WJHTKksfbYI/AAAAAAAAIS4/zeXFV8e59ogW8EnDuolyyQB3W63uC_-cQCK4B/s1600/maxresdefault.jpg" imageanchor="1"><img border="0" height="274" src="https://1.bp.blogspot.com/-ric2vMgkW7E/WJHTKksfbYI/AAAAAAAAIS4/zeXFV8e59ogW8EnDuolyyQB3W63uC_-cQCK4B/s640/maxresdefault.jpg" width="640" /></a> </b><br />
<br />
<br />
My friend <b>Sanket </b>encourage me to do some stuff on <a href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327" target="_blank">ESP8266</a><img alt="" border="0" height="1" src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" style="border: none !important; margin: 0px !important;" width="1" />OTA.<br />
No need of wire to upload Arduino sketch in <a href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327" target="_blank">ESP8266</a><img alt="" border="0" height="1" src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" style="border: none !important; margin: 0px !important;" width="1" />. OTA give you advantage of uploading sketch or upgrade firmware over the WiFi without any wired connection.<br />
*Program uploading is Faster than regular arduino upload.<br />
<br />
<b>Requirement:</b><br />
1) Go through previous tutorials of <a href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327" target="_blank">ESP8266</a><img alt="" border="0" height="1" src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" style="border: none !important; margin: 0px !important;" width="1" />on my blog<br />
2) <a href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327" target="_blank">ESP8266</a><img alt="" border="0" height="1" src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" style="border: none !important; margin: 0px !important;" width="1" /><br />
<a href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=348c107cbd68fb0ea7b134cfa3ad3cab" target="_blank"><img border="0" src="//ws-in.amazon-adsystem.com/widgets/q?_encoding=UTF8&MarketPlace=IN&ASIN=B00RJJHWLA&ServiceVersion=20070822&ID=AsinImage&WS=1&Format=_SL160_&tag=tisl0c-21" /></a><img alt="" border="0" height="1" src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" style="border: none !important; margin: 0px !important;" width="1" /><br />
3) <a href="https://www.python.org/downloads/">python27</a> installed on System from where your going to upload firmware.\<br />
<br />
<b>Step 1:</b><br />
Download The library and tools required for OTA <a href="https://drive.google.com/file/d/0B4tww7CJlZPyVVp4MWYwaTQ2Nzg/view?usp=sharing">click here</a><br />
<br />
<b>Step 2:</b><br />
Extract downloaded file and install arduino OTA library in Arduino IDE.<br />
<br />
<b>Step 3:</b><br />
Complile and Upload following sketch in ESP by our <a href="https://zenelectro.blogspot.in/2016/09/program-esp8266-wifi-modulewith-arduino.html">regular method through serial terminal</a>. Its necessary to upload first time sketch with OTA suppot. <br />
<span style="color: blue;"> #include < esp8266wifi.h ><br />
#include < esp8266mdns .h ><br />
#include < wifiudp .h ><br />
#include < arduinoota .h ><br />
<br />
const char* ssid = "WIFI ROUTER NAME";<br />
const char* password = "WIFI ROUTER PASSWORD";<br />
<br />
void setup() {<br />
Serial.begin(115200);<br />
Serial.println("Booting");<br />
WiFi.mode(WIFI_STA);<br />
WiFi.begin(ssid, password);<br />
while (WiFi.waitForConnectResult() != WL_CONNECTED) {<br />
Serial.println("Connection Failed! Rebooting...");<br />
delay(5000);<br />
ESP.restart();<br />
}<br />
ArduinoOTA.onStart([]() {<br />
String type;<br />
if (ArduinoOTA.getCommand() == U_FLASH)<br />
type = "sketch";<br />
else // U_SPIFFS<br />
type = "filesystem";<br />
<br />
// NOTE: if updating SPIFFS this would be the place to unmount SPIFFS using SPIFFS.end()<br />
Serial.println("Start updating " + type);<br />
});<br />
ArduinoOTA.onEnd([]() {<br />
Serial.println("\nEnd");<br />
});<br />
ArduinoOTA.onProgress([](unsigned int progress, unsigned int total) {<br />
Serial.printf("Progress: %u%%\r", (progress / (total / 100)));<br />
});<br />
ArduinoOTA.onError([](ota_error_t error) {<br />
Serial.printf("Error[%u]: ", error);<br />
if (error == OTA_AUTH_ERROR) Serial.println("Auth Failed");<br />
else if (error == OTA_BEGIN_ERROR) Serial.println("Begin Failed");<br />
else if (error == OTA_CONNECT_ERROR) Serial.println("Connect Failed");<br />
else if (error == OTA_RECEIVE_ERROR) Serial.println("Receive Failed");<br />
else if (error == OTA_END_ERROR) Serial.println("End Failed");<br />
});<br />
ArduinoOTA.begin();<br />
Serial.println("Ready v1.0"); //Change version for every new modification in firmaware<br />
Serial.print("IP address: ");<br />
Serial.println(WiFi.localIP());<br />
<br />
pinMode(2,OUTPUT);<br />
}<br />
<br />
void loop() {<br />
ArduinoOTA.handle();<br />
digitalWrite(2,HIGH);<br />
delay(500);<br />
digitalWrite(2,LOW);<br />
delay(500);<br />
}</span><br />
<br />
<br />
<b>Step 4 : </b><br />
Now your <a href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327" target="_blank">ESP8266</a><img alt="" border="0" height="1" src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" style="border: none !important; margin: 0px !important;" width="1" />is ready for OTA support.<br />
How to test OTA is working ?<br />
first you need new firm ware file OTA support two types of file i.e 1) .bin, 2 ) SPIFF<br />
Here we are dealing with only .bin file.<br />
<br />
modify above sketch withc some changes like<br />
<span style="color: blue;"> Serial.println("Ready v2.0"); //Change version for every new modification in firmaware</span><br />
<span style="color: blue;">.</span><br />
<br />
<span style="color: blue;">void loop() {<br />
ArduinoOTA.handle();<br />
digitalWrite(2,HIGH);<br />
delay(2000);<br />
digitalWrite(2,LOW);<br />
delay(2000);<br />
}</span><br />
<span style="color: blue;"><span style="color: black;">here we change version of firmware and make some changes in program. That can be reflect after OTA update.</span> </span><br />
<br />
<span style="color: blue;"></span><br />
Now only <b>Verify/Compile</b> program in Arduino IDE do not<b> Upload.</b><br />
<br />
goto run > %temp% in temp folder find out your arduino build folder<br />
<div style="text-align: center;"><a href="http://3.bp.blogspot.com/-6vIgZCNIwQ8/WJHL-BkbJcI/AAAAAAAAIR8/_maHyIa31EwZ-rJwIh0nUq7QxyZf06f8QCK4B/s1600/asd.jpg" imageanchor="1"><img border="0" height="164" src="https://3.bp.blogspot.com/-6vIgZCNIwQ8/WJHL-BkbJcI/AAAAAAAAIR8/_maHyIa31EwZ-rJwIh0nUq7QxyZf06f8QCK4B/s320/asd.jpg" width="320" /></a> </div><br />
Locate build folder <br />
<div style="text-align: center;"> <a href="http://4.bp.blogspot.com/-jsvTotgRO4M/WJHNmHB0qKI/AAAAAAAAISU/4MXIf9XVmaYw08B8tXvacGx7PiL7lWx_wCK4B/s1600/asd.jpg" imageanchor="1"><img border="0" height="476" src="https://4.bp.blogspot.com/-jsvTotgRO4M/WJHNmHB0qKI/AAAAAAAAISU/4MXIf9XVmaYw08B8tXvacGx7PiL7lWx_wCK4B/s640/asd.jpg" width="640" /> </a></div><div style="text-align: left;">Locate .bin file </div><div style="text-align: left;"><br />
</div><div style="text-align: center;"><a href="http://3.bp.blogspot.com/-BvJfFuW-A28/WJHN5UZa06I/AAAAAAAAISc/u-3tEmoWgb4Zhp2CO6hXkMZv5ALcvOpSQCK4B/s1600/asd.jpg" imageanchor="1"><img border="0" height="270" src="https://3.bp.blogspot.com/-BvJfFuW-A28/WJHN5UZa06I/AAAAAAAAISc/u-3tEmoWgb4Zhp2CO6hXkMZv5ALcvOpSQCK4B/s640/asd.jpg" width="640" /></a> </div><div style="text-align: left;"><br />
</div><div style="text-align: left;">copy .bin file path which is use in espota tool. </div><br />
<b>Step 5:</b><br />
Now prepare system which can access <a href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327" target="_blank">ESP8266</a><img alt="" border="0" height="1" src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" style="border: none !important; margin: 0px !important;" width="1" />in network.<br />
In <a href="https://drive.google.com/file/d/0B4tww7CJlZPyVVp4MWYwaTQ2Nzg/view?usp=sharing">download rar file</a> you will find espota.py script that can upload firmware in esp.<br />
<br />
Open command prompt in espota.py file location by pressing shift key and right click > open command window here.<br />
<br />
give this command<br />
<span style="color: #a64d79;">python espota.py -i 10.19.30.40 -p 8266 -f "C:\User\INDIA\AppData\Local\\Temp\builda0eb11f6003a2bd55895c96acd777afe.tmp\BasicOTA.ino.bin" -d -r</span><br />
<br />
firmware upgradation will start<br />
<br />
<div style="text-align: center;"><a href="http://4.bp.blogspot.com/-AO7WRbZiX4I/WJHRZ3_VytI/AAAAAAAAISs/32fYAsQBjFIyZJaI05LgFY4xoXcsGuSEwCK4B/s1600/asd.jpg" imageanchor="1"></a><a href="http://4.bp.blogspot.com/-8dLhYcjCDMQ/WJHUABTolBI/AAAAAAAAITE/qZrDxC7Zu2wkJf6nG3qdEbsgHrOS7gKPgCK4B/s1600/asd.jpg" imageanchor="1"><img border="0" height="340" src="https://4.bp.blogspot.com/-8dLhYcjCDMQ/WJHUABTolBI/AAAAAAAAITE/qZrDxC7Zu2wkJf6nG3qdEbsgHrOS7gKPgCK4B/s640/asd.jpg" width="640" /></a> </div><div style="text-align: center;"><br />
</div><div style="text-align: left;">You can observe blinking speed of LED get changed.</div><div style="text-align: left;"><br />
</div><div style="text-align: left;">If you have any questions please comment below.</div><div style="text-align: left;">Thank You. </div></div></div></div>Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com3tag:blogger.com,1999:blog-1566744693640221506.post-32899470582194953762016-12-26T07:15:00.000-08:002017-02-04T13:04:49.518-08:00<div dir="ltr" style="text-align: left;" trbidi="on"><h2 style="text-align: left;"><u>ESP8266(Arduino) interface with Firebase:</u></h2><div style="text-align: center;"> <a href="http://4.bp.blogspot.com/-PzqoUc-uD8o/WGEmVCHEBXI/AAAAAAAAIJQ/jUvqCSN-W2IM7rwk8OXrTzJAVbdPKNRqQCK4B/s1600/logo-firebase.png" imageanchor="1"><img border="0" height="192" src="https://4.bp.blogspot.com/-PzqoUc-uD8o/WGEmVCHEBXI/AAAAAAAAIJQ/jUvqCSN-W2IM7rwk8OXrTzJAVbdPKNRqQCK4B/s640/logo-firebase.png" width="640" /> </a></div><div style="text-align: center;"><br />
</div><div style="text-align: left;"><b>Aim:</b></div><div style="text-align: left;"> Make such application in which LED can be control from mobile or website from any remote location where internet connectivity is available.</div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><b>Requirement:</b></div><div style="text-align: left;">1 ) <a target="_blank" href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327">ESP8266</a><img src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" />-E12 WiFi module as shown in picture. <a href="https://zenelectro.blogspot.in/2016/09/program-esp8266-wifi-modulewith-arduino.html">You can get start and setup it <b> </b>with help of this post.</a></div><div style="text-align: left;">2) Download and install <a href="https://drive.google.com/file/d/0B4tww7CJlZPyUTd1enFxNklKOE0/view?usp=sharing">firebase-arduino-master</a> library in Arduino IDE.</div><div style="text-align: left;">3) Need gmail account for create Firebase project.</div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><b>Step 1:</b></div><div style="text-align: left;">Go to <a href="https://console.firebase.google.com/">https://console.firebase.google.com</a> and create new project.</div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><b>Step 2:</b></div><div style="text-align: left;">Click on Database now you will see the host name show in image</div><div style="text-align: center;"><a href="http://2.bp.blogspot.com/-JM8oz63hCPo/WGEqVnRoP_I/AAAAAAAAIJc/B4w05R7gJLw6mJjfghh7XeoZLXoHEIaPgCK4B/s1600/0.jpg" imageanchor="1"><img border="0" height="290" src="https://2.bp.blogspot.com/-JM8oz63hCPo/WGEqVnRoP_I/AAAAAAAAIJc/B4w05R7gJLw6mJjfghh7XeoZLXoHEIaPgCK4B/s640/0.jpg" width="640" /></a> </div><div style="text-align: center;"><br />
</div><div style="text-align: left;">Copy that host name and past in Arduino code given below at line</div><div style="text-align: left;"> <span style="color: blue;">#define FIREBASE_HOST "fir-app-example.firebaseio.com"</span></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><b><span style="color: blue;"><span style="color: black;">Step 3:</span></span></b></div><div style="text-align: left;"><span style="color: blue;"><span style="color: black;">Go to Setting>Project Setting>SERVICE ACCOUNTS>DATABASE Secretes.</span></span></div><div style="text-align: left;"><span style="color: blue;"><span style="color: black;">Copy "Database Secrets" Shown in below image</span></span></div><div style="text-align: left;"><br />
</div><div style="text-align: center;"><span style="color: blue;"><span style="color: black;"><a href="http://2.bp.blogspot.com/-gxT6u5_YP1M/WGErGxGHBkI/AAAAAAAAIJo/AXQCUUGkNEk0nsgtq8KmxBjzjHczyIyywCK4B/s1600/1.jpg" imageanchor="1"><img border="0" height="232" src="https://2.bp.blogspot.com/-gxT6u5_YP1M/WGErGxGHBkI/AAAAAAAAIJo/AXQCUUGkNEk0nsgtq8KmxBjzjHczyIyywCK4B/s640/1.jpg" width="640" /></a> </span></span></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><span style="color: blue;"><span style="color: black;">Copy and paste Database Secrets at the line in code </span></span></div><div style="text-align: left;"><span style="color: blue;">#define FIREBASE_AUTH "</span><span style="color: blue;"><span style="color: blue;">example</span>sd2asdasdasdasd2asd3asd2asd2as32das3d2as2da3" </span></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><span style="color: blue;"><span style="color: black;">Step 6 :</span></span></div><div style="text-align: left;"><span style="color: blue;"><span style="color: black;">Change line with your WiFi router name and password</span></span><br />
<span style="color: blue;">#define WIFI_SSID "Wifi Router Name"<br />
#define WIFI_PASSWORD "Router Password"</span></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><span style="color: blue;"><span style="color: black;">Step 5:</span></span></div><div style="text-align: left;"><span style="color: blue;"><span style="color: black;">Download following code in arduino</span></span></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><span style="color: blue;">#include <esp8266wifi .h=""><br />
#include <firebasearduino .h=""><br />
<br />
// Set these to run example.<br />
#define FIREBASE_HOST "</firebasearduino></esp8266wifi></span><span style="color: blue;"><span style="color: blue;">fir-app-example.firebaseio.com</span>"<br />
#define FIREBASE_AUTH "</span><span style="color: blue;"><span style="color: blue;"></span><span style="color: blue;"><span style="color: blue;">example</span>sd2asdasdasdasd2asd3asd2asd2as32das3d2as2da3</span>"<br />
#define WIFI_SSID "Wifi Router Name"<br />
#define WIFI_PASSWORD "Router Password"<br />
<br />
#define LED 2<br />
<br />
void setup() {<br />
<br />
pinMode(LED,OUTPUT);<br />
digitalWrite(LED,0);<br />
<br />
Serial.begin(9600);<br />
<br />
WiFi.begin(WIFI_SSID, WIFI_PASSWORD);<br />
Serial.print("connecting");<br />
while (WiFi.status() != WL_CONNECTED) {<br />
Serial.print(".");<br />
delay(500);<br />
}<br />
Serial.println();<br />
Serial.print("connected: ");<br />
Serial.println(WiFi.localIP());<br />
<br />
Firebase.begin(FIREBASE_HOST, FIREBASE_AUTH);<br />
<br />
Firebase.setInt("LEDStatus",0);<br />
}<br />
<br />
void loop() {<br />
if(Firebase.getInt("LEDStatus"))<br />
{ <br />
digitalWrite(LED,HIGH);<br />
}<br />
else<br />
{<br />
digitalWrite(LED,LOW);<br />
}<br />
if (Firebase.failed()) // Check for errors</span></div><div style="text-align: left;"><span style="color: blue;"> {<br />
Serial.print("setting /number failed:");<br />
Serial.println(Firebase.error()); <br />
return;<br />
} <br />
delay(1000);<br />
}</span></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><b>Step 6:</b></div><div style="text-align: left;">After reseting <a target="_blank" href="https://www.amazon.in/gp/product/B00RJJHWLA/ref=as_li_tl?ie=UTF8&camp=3638&creative=24630&creativeASIN=B00RJJHWLA&linkCode=as2&tag=tisl0c-21&linkId=77023d9aa7ddb4ed5c2ae99427670327">ESP8266</a><img src="//ir-in.amazon-adsystem.com/e/ir?t=tisl0c-21&l=am2&o=31&a=B00RJJHWLA" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" />check serial terminal whether the ESP is get connected with your router and got IP adress. </div><div style="text-align: left;">Goto <a href="https://console.firebase.google.com/project/fir-app-9adb8/database/data">https://console.firebase.google.com/project/fir-app-9adb8/database/data</a> </div><div style="text-align: left;">you can now see the new variable created in database. </div><div style="text-align: center;"><a href="http://1.bp.blogspot.com/-A3bPE7PNSdM/WGEuWwGSZbI/AAAAAAAAIJ0/s-qDShdipLoeW15U6Du_63a9PQZCfZ3PQCK4B/s1600/2.jpg" imageanchor="1"><img border="0" height="390" src="https://1.bp.blogspot.com/-A3bPE7PNSdM/WGEuWwGSZbI/AAAAAAAAIJ0/s-qDShdipLoeW15U6Du_63a9PQZCfZ3PQCK4B/s640/2.jpg" width="640" /> </a></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><br />
</div><div style="text-align: left;">Step 7: </div><div style="text-align: left;">Double click "LEDStatus" and edit it to 1. instantly (its depends on your internet connection) LED on ESP 8266 module get Turn off.</div><div style="text-align: center;"><a href="http://2.bp.blogspot.com/-CiidrIKKc2c/WGEv5a_lgwI/AAAAAAAAIKA/lydoDZl2vo0AhlcBLSCfcD9yPpuXJcXuACK4B/s1600/3.jpg" imageanchor="1"><img border="0" height="416" src="https://2.bp.blogspot.com/-CiidrIKKc2c/WGEv5a_lgwI/AAAAAAAAIKA/lydoDZl2vo0AhlcBLSCfcD9yPpuXJcXuACK4B/s640/3.jpg" width="640" /> </a></div><div style="text-align: left;"><br />
</div><div style="text-align: left;"><b>Step 8: </b></div><div style="text-align: left;">If you have knowledge of Android you can create App for control LED from mobile. You need to read Firebase documentation and integration methods.</div><div style="text-align: left;"><br />
</div>I created my android app for controlling LED from mobile. As Firebase can be assess from world wide so you have end to end IoT application.<br />
<br />
For any question comment below. Thank You.</div>Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com1tag:blogger.com,1999:blog-1566744693640221506.post-52347400531428529212016-12-14T06:21:00.004-08:002021-11-01T12:12:35.955-07:00<div dir="ltr" style="text-align: left;" trbidi="on">
<h2 style="text-align: left;">
JHD12864E interfacing with Arduino Uno( 128x64 Bit MAp Graphics LCD) :</h2>
<div style="text-align: center;">
<a href="http://2.bp.blogspot.com/-b2b3ZyIJg1E/WFFU-qpo22I/AAAAAAAAIIM/TewNHtFQ25oeixlsscgsuFmUS_oTWTdAgCK4B/s1600/IMG_20161213_215909.jpg" imageanchor="1"><img border="0" height="348" src="https://2.bp.blogspot.com/-b2b3ZyIJg1E/WFFU-qpo22I/AAAAAAAAIIM/TewNHtFQ25oeixlsscgsuFmUS_oTWTdAgCK4B/s640/IMG_20161213_215909.jpg" width="640" /></a> </div>
<div style="text-align: left;">
<b>Requirement :</b></div>
<div style="text-align: left;">
1 ) JHD12864E LCD</div>
<div style="text-align: left;">
2 ) Arduino</div>
<div style="text-align: left;">
3 ) Connecting wires</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Aim:</b> Convert and display JPEG image on Graphics LCD as Bitmap image<br />
<br />
<b>Step 1 : </b><br />
Download and put Glcd library in <b>Documents/Arduino/library</b> folder<br />
<b><a href="https://drive.google.com/open?id=0B4tww7CJlZPyWjNfdGhnWC1LZVU">GLCD library</a></b><br />
<br />
<b>Step 2 :</b><br />
Download BMP-To-LCD software to convert JPEG image to BMP array<br />
<b><a href="https://drive.google.com/open?id=0B4tww7CJlZPybDE1WUJaSXdHNEE">BMP-TO-LCD</a></b><br />
<br />
<b>Step 3: </b><br />
Make connection of LCD to Arduino UNO as shown in figure.<br />
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-bt8nIE-6B7g/WFEIUsrmgvI/AAAAAAAAIF8/OMYdTBv3xrgdof2Q-MYxedsDm7mLsk94gCK4B/s1600/Pl0lbK1395164598.jpg" imageanchor="1"><img border="0" height="640" src="https://4.bp.blogspot.com/-bt8nIE-6B7g/WFEIUsrmgvI/AAAAAAAAIF8/OMYdTBv3xrgdof2Q-MYxedsDm7mLsk94gCK4B/s640/Pl0lbK1395164598.jpg" width="464" /> </a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Step 4:</b></div>
<div style="text-align: left;">
Download any image from internet.</div>
<div style="text-align: center;">
<a href="http://3.bp.blogspot.com/-RH8x9-yJxrQ/WFEIt5MMA3I/AAAAAAAAIGE/OugOkz_L0oYcsENGv3FOayFJWFq106PiACK4B/s1600/sunny-leone.jpg" imageanchor="1"><img border="0" height="266" src="https://3.bp.blogspot.com/-RH8x9-yJxrQ/WFEIt5MMA3I/AAAAAAAAIGE/OugOkz_L0oYcsENGv3FOayFJWFq106PiACK4B/s400/sunny-leone.jpg" width="400" /> </a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Step 5: </b>Open image in Paint</div>
<div style="text-align: center;">
<a href="http://1.bp.blogspot.com/-zu0R4ActOww/WFEJJUSsbSI/AAAAAAAAIGM/p__mp-I4ObwBYs6mHx8o6Pdf_hEFnG8PgCK4B/s1600/1.jpg" imageanchor="1"><img border="0" height="556" src="https://1.bp.blogspot.com/-zu0R4ActOww/WFEJJUSsbSI/AAAAAAAAIGM/p__mp-I4ObwBYs6mHx8o6Pdf_hEFnG8PgCK4B/s640/1.jpg" width="640" /></a> </div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Step 6:</b></div>
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-NmXmYMUL0Ww/WFFCvDpE5-I/AAAAAAAAIGg/9TLvFB_GXfYnw7MyNbEzxtg3bIyCV90FwCK4B/s1600/2.jpg" imageanchor="1"><img border="0" height="640" src="https://4.bp.blogspot.com/-NmXmYMUL0Ww/WFFCvDpE5-I/AAAAAAAAIGg/9TLvFB_GXfYnw7MyNbEzxtg3bIyCV90FwCK4B/s640/2.jpg" width="478" /></a> </div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Step7 :</b></div>
<div style="text-align: center;">
<a href="http://3.bp.blogspot.com/-ABIZMTMjh1k/WFFC53fUgeI/AAAAAAAAIGo/OI4mSVSvfuYcSvMdo4YcuVCRUTV_oEZ_wCK4B/s1600/33.jpg" imageanchor="1"><img border="0" height="440" src="https://3.bp.blogspot.com/-ABIZMTMjh1k/WFFC53fUgeI/AAAAAAAAIGo/OI4mSVSvfuYcSvMdo4YcuVCRUTV_oEZ_wCK4B/s640/33.jpg" width="640" /> </a></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
<a href="http://3.bp.blogspot.com/-0mO5IUNkplU/WFFDH9OYvdI/AAAAAAAAIGw/aUso8kJk-fMDgBUHjkDhTA5C0QDdjg8fACK4B/s1600/3.JPG" imageanchor="1"><img border="0" height="640" src="https://3.bp.blogspot.com/-0mO5IUNkplU/WFFDH9OYvdI/AAAAAAAAIGw/aUso8kJk-fMDgBUHjkDhTA5C0QDdjg8fACK4B/s640/3.JPG" width="536" /></a> </div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
<b>Step 8:</b></div>
<div style="text-align: center;">
<a href="http://3.bp.blogspot.com/-hVsgEYSmjd4/WFFDYJPPmXI/AAAAAAAAIG4/EAUaLEXLj5gHLV8Q7HUI-BjW7nTH9h29ACK4B/s1600/4.jpg" imageanchor="1"><img border="0" height="640" src="https://3.bp.blogspot.com/-hVsgEYSmjd4/WFFDYJPPmXI/AAAAAAAAIG4/EAUaLEXLj5gHLV8Q7HUI-BjW7nTH9h29ACK4B/s640/4.jpg" width="526" /> </a></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
<b>Step 9: </b></div>
<div style="text-align: left;">
Click on resize without selecting area</div>
<div style="text-align: center;">
<a href="http://1.bp.blogspot.com/-dmqv3czUhP8/WFFDxfC0A0I/AAAAAAAAIHM/Nyi1luiZHAQ0FZK3W7d2czrKQ0g-QTNWQCK4B/s1600/7.jpg" imageanchor="1"><img border="0" height="456" src="https://1.bp.blogspot.com/-dmqv3czUhP8/WFFDxfC0A0I/AAAAAAAAIHM/Nyi1luiZHAQ0FZK3W7d2czrKQ0g-QTNWQCK4B/s640/7.jpg" width="640" /></a> </div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Step 10: </b></div>
<div style="text-align: left;">
Save image as <b>1.bmp</b> </div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Step 11 : </b>open Image in BMP-LCD software</div>
<div style="text-align: center;">
<a href="http://3.bp.blogspot.com/-MDFYQffjyLo/WFFEbUuWabI/AAAAAAAAIHY/LELug934HhklcdC-PI29ZFZdo5Hnj2SfACK4B/s1600/8.jpg" imageanchor="1"><img border="0" height="392" src="https://3.bp.blogspot.com/-MDFYQffjyLo/WFFEbUuWabI/AAAAAAAAIHY/LELug934HhklcdC-PI29ZFZdo5Hnj2SfACK4B/s640/8.jpg" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
And click on Genarate code</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: center;">
<a href="http://2.bp.blogspot.com/-zfC17w_XhiE/WFFElXL5J_I/AAAAAAAAIHg/1xwyPOTe9EYgq4poHdib2zn9Z67JHrLNgCK4B/s1600/9.jpg" imageanchor="1"><img border="0" height="462" src="https://2.bp.blogspot.com/-zfC17w_XhiE/WFFElXL5J_I/AAAAAAAAIHg/1xwyPOTe9EYgq4poHdib2zn9Z67JHrLNgCK4B/s640/9.jpg" width="640" /></a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Copy that genarated code in Arduino sketch</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: center;">
<a href="http://3.bp.blogspot.com/-oHiTyxQu0Lk/WFFExpjhBzI/AAAAAAAAIHo/C0cBWgGg2gkdxkR3nydlYsDZlJcC5AFxACK4B/s1600/10.jpg" imageanchor="1"><img border="0" height="330" src="https://3.bp.blogspot.com/-oHiTyxQu0Lk/WFFExpjhBzI/AAAAAAAAIHo/C0cBWgGg2gkdxkR3nydlYsDZlJcC5AFxACK4B/s640/10.jpg" width="640" /> </a></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
<b>Step 12:</b> Copy Paste code in <b>bitmaps.h </b>with some modification as shown in below image </div>
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-O8wDUYK5NLg/WFFE4DdYHGI/AAAAAAAAIHw/zTVYs7hO2zML1KVHpEGrbzr3-YteuCGjACK4B/s1600/11.JPG" imageanchor="1"><img border="0" height="640" src="https://4.bp.blogspot.com/-O8wDUYK5NLg/WFFE4DdYHGI/AAAAAAAAIHw/zTVYs7hO2zML1KVHpEGrbzr3-YteuCGjACK4B/s640/11.JPG" width="576" /></a> </div>
<div style="text-align: left;">
<br />
Main sketch is as shown below image </div>
<div style="text-align: center;">
<a href="http://3.bp.blogspot.com/-Q-KNnoSuGuY/WFFFb03INDI/AAAAAAAAIH4/kK-GtG58i2QzkcJUjCErZbXTVzu8QRoFACK4B/s1600/12.JPG" imageanchor="1"><img border="0" height="640" src="https://3.bp.blogspot.com/-Q-KNnoSuGuY/WFFFb03INDI/AAAAAAAAIH4/kK-GtG58i2QzkcJUjCErZbXTVzu8QRoFACK4B/s640/12.JPG" width="416" /> </a></div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
You can download it from here <a href="https://github.com/8-DK/GLCD_ARDUINO_BMP_IMAGE">Arduino_GLCD_Sketch</a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
If You have any question comment below. </div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
</div>
</div>
</div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com3tag:blogger.com,1999:blog-1566744693640221506.post-34457062241226124902016-11-29T04:03:00.000-08:002016-11-29T04:04:39.574-08:00<div dir="ltr" style="text-align: left;" trbidi="on"><h2 style="line-height: 100%; margin-bottom: 0in; text-align: left;"><span style="font-size: large;"><u><span style="font-weight: normal;">Download English Dictionary words for Microcontroller based Text to Speech (TTS) convertor:</span></u></span></h2><br />
<u style="font-size: medium; text-align: center;"><span style="font-weight: normal;"><a href="http://4.bp.blogspot.com/-omjNyT25Qb0/WD1pSKfk1_I/AAAAAAAAIEU/d0k1eF6X88gOL-_xiNRneleITrDTCgwzgCK4B/s1600/text-to-speech-670x335.jpg" imageanchor="1"><img border="0" height="240" src="https://4.bp.blogspot.com/-omjNyT25Qb0/WD1pSKfk1_I/AAAAAAAAIEU/d0k1eF6X88gOL-_xiNRneleITrDTCgwzgCK4B/s640/text-to-speech-670x335.jpg" width="640" /></a></span></u><br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><b>What is TTS?</b></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Speech synthesis is the artificial production of human speech. A computer system used for this purpose is called a speech computer or speech synthesizer, and can be implemented in software or hardware products. A text-to-speech (TTS) system converts normal language text into speech; other systems render symbolic linguistic representations like phonetic transcriptions into speech.</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Basic architecture is explained in following block diagram.</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in; text-align: center;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><a href="http://2.bp.blogspot.com/-lT1iXHPDmk0/WD1pcBnC4zI/AAAAAAAAIEc/-kBaVTyPd1EYPBlFNxgDrPj2WMNqmZDIQCK4B/s1600/speech.jpg" imageanchor="1"><img border="0" height="312" src="https://2.bp.blogspot.com/-lT1iXHPDmk0/WD1pcBnC4zI/AAAAAAAAIEc/-kBaVTyPd1EYPBlFNxgDrPj2WMNqmZDIQCK4B/s640/speech.jpg" width="640" /></a> </span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Microcontroller feed with text data from any interface . microcontroller make tokens of that string into and compare appropriate soud file per word from data bases. After getting all index of each word of string micro controller play sound files one after another with proper delay in words.</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><b><i><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">As per post title I am going to use Python script to make my own speech files database(format in mp3).</span></span></span></i></b></div><div style="line-height: 100%; margin-bottom: 0in; text-align: left;"><div style="text-align: left;"><b><i><span style="font-size: small;"><span style="font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><br />
</span></span></span></span></i></b> <b><i><span style="font-size: small;"><span style="font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><br />
</span></span></span></span></i></b> <b><i><span style="font-size: small;"><span style="font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Prerequisite :</span></span></span></span></i></b></div></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">1) Installed python 2.7 ( Download and install from <a href="https://www.python.org/download/releases/2.7/">https://www.python.org/download/releases/2.7/</a>)</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">2) Internet</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><b><br />
</b></span></div><div style="line-height: 100%; margin-bottom: 0in;"><div style="text-align: left;"><span style="font-size: small;"><span style="font-family: inherit;"><b><span style="font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Step 1:</span></span></span></b></span></span></div></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">locate <span style="color: #666666;">Python27\Scripts</span> director</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">install requred python packages</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><span style="color: #666666;">press and hold shift key</span> and <span style="color: #666666;">rigth click</span> > click <span style="color: #444444;">open command window here</span></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">in command prompt type and enter </span></span></span> </div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">> <span style="color: #666666;">pip.exe install wget</span><br />
</span></span></span><br />
<span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><span style="color: #666666;"><br />
</span></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">this is package used by our script to download .mp3 files from internet</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><b>Step 2</b><b style="font-style: normal; text-decoration: none;">:</b></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">We are going to download all our .mp3 file from google database.</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Base url is <a href="https://ssl.gstatic.com/dictionary/static/sounds/de/0/hello.mp3">https://ssl.gstatic.com/dictionary/static/sounds/de/0/hello.mp3</a></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">we need to replace “hello.mp3” with our word that we want to download.</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><b>Step 3</b><b style="font-style: normal; text-decoration: none;">:</b></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Here I used the file <span style="color: #666666;">words.txt</span> that contains daily used English words. We take each word from file and replace in base URL to download it.</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span> <br />
<div style="text-align: center;"><span style="font-size: small;"><a href="http://3.bp.blogspot.com/-LONkA4AS-gA/WD1sJ83IzcI/AAAAAAAAIEo/MOSsvmjM2AIUljV-FjhIAh55rOVaHcVWgCK4B/s1600/3.jpg" imageanchor="1"><img border="0" height="640" src="https://3.bp.blogspot.com/-LONkA4AS-gA/WD1sJ83IzcI/AAAAAAAAIEo/MOSsvmjM2AIUljV-FjhIAh55rOVaHcVWgCK4B/s640/3.jpg" width="592" /></a></span></div><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><a href="https://drive.google.com/open?id=0B4tww7CJlZPyTjFCNWRWcXlCTkk"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">w</span></span></span><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">or</span></span></span><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">ds</span></span></span><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">.txt</span></span></span></a></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">download this this file and keep it in same directory where following script is placed.</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><b>Step 4:</b></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">create new text file, copy and paste following code in it. Rename that file </span></span></span><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">as</span></span></span><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"> <span style="color: #666666;">script.py</span></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;">import wget</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;">import os</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;">import os.path</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue; font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;">with open("words.txt", "r") as ins:</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue; font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> def chomp(x):</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> if x.endswith("\r\n"): return x[:-2]</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> if x.endswith("\n"): return x[:-1]</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> return x[:]</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue; font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> for line in ins:</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> line=chomp(line)+".mp3"</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> if False==os.path.isfile(line):</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> print "new file added\n"</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> file_url = "https://ssl.gstatic.com/dictionary/static/sounds/de/0/"</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> file_url=file_url+line</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> print file_url</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> file_name = wget.download(file_url)</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> else :</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: blue; font-weight: normal;"> print "file exist"</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><b>Step5:</b></span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">open command prompt from director of script and run script as </span></span></span> </div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="color: #666666; font-weight: normal;">> python script.py</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small;"><br />
</span></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><b>Step 6:</b></span></span></span><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><br />
</span></span></span><br />
<div style="text-align: center;"><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><b><a href="http://2.bp.blogspot.com/-F7eOkwHur5g/WD1smse0c2I/AAAAAAAAIEw/RBvJcq-vLbUPWqVYn8zdrb8bhcmOMesLwCK4B/s1600/Untitled.jpg" imageanchor="1"><img border="0" height="266" src="https://2.bp.blogspot.com/-F7eOkwHur5g/WD1smse0c2I/AAAAAAAAIEw/RBvJcq-vLbUPWqVYn8zdrb8bhcmOMesLwCK4B/s640/Untitled.jpg" width="640" /></a></b></span></span></span></div><span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;">Download will take time as their is load of words in text file. you can reduce them as per your requirement.</span></span></span><br />
<span style="font-size: small; font-style: normal;"><span style="text-decoration: none;"><span style="font-weight: normal;"><br />
</span></span></span></div><div style="line-height: 100%; margin-bottom: 0in;">Now you have you mp3 database for text to speech converter. I have working prototype for it using microcontroller.<br />
If you have any question please comment below or contact me.</div></div>Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-46178782033246479332016-11-10T07:49:00.003-08:002016-12-13T22:45:30.690-08:00<div dir="ltr" style="text-align: left;" trbidi="on"><div dir="ltr" style="text-align: left;" trbidi="on"><div dir="ltr" style="text-align: left;" trbidi="on"><div dir="ltr" style="text-align: left;" trbidi="on"><div dir="ltr" style="text-align: left;" trbidi="on"><h2 class="pageName" style="line-height: 100%; margin-bottom: 0in; text-align: left;"><u>Raspberry pi 3 kernel module compilation:</u></h2><div style="line-height: 100%; margin-bottom: 0in; text-align: left;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in; text-align: left;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in; text-align: center;"><a href="http://3.bp.blogspot.com/-jmdlsCQx_GY/WCSVZ6ihXUI/AAAAAAAAIBE/gQgssQ43DCQrnG0qka6xVe8YDpuJYldbwCK4B/s1600/c67f97f6f1d451350773502433580bca-970-80.jpg" imageanchor="1"><img border="0" height="225" src="https://3.bp.blogspot.com/-jmdlsCQx_GY/WCSVZ6ihXUI/AAAAAAAAIBE/gQgssQ43DCQrnG0qka6xVe8YDpuJYldbwCK4B/s400/c67f97f6f1d451350773502433580bca-970-80.jpg" width="400" /></a> </div><div style="line-height: 100%; margin-bottom: 0in; text-align: center;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in; text-align: left;"></div><div style="line-height: 100%; margin-bottom: 0in;">Raspberry pi 3 kernel module compile :</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><b>Step 1:</b></div><div style="line-height: 100%; margin-bottom: 0in;">Update current kernel</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo apt-get update</span></div><span style="color: blue;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo apt-get upgrade</span></div><span style="color: blue;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo apt-get install bc</span></div><span style="color: blue;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo apt-get install gcc</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><b>Step 2:</b></div><div style="line-height: 100%; margin-bottom: 0in;">Download linux headers for current kernel version </div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$uname -r</span></div><div style="line-height: 100%; margin-bottom: 0in;">><span style="color: #666666;">4.4.26-v7+</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">copy kernel version</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">and goto url <a href="https://www.niksula.hut.fi/~mhiienka/Rpi/linux-headers-rpi/">https://www.niksula.hut.fi/~mhiienka/Rpi/linux-headers-rpi/</a> and find your kernel version</div><div style="line-height: 100%; margin-bottom: 0in;">here in my case </div><div style="line-height: 100%; margin-bottom: 0in; text-align: center;"><a href="http://3.bp.blogspot.com/-_U1u666tOcY/WCSWQJyIdWI/AAAAAAAAIBM/95rwJV4bEt8V7gDLNX2JjCBdQ4mbCZiDgCK4B/s1600/1.png" imageanchor="1"><img border="0" height="451" src="https://3.bp.blogspot.com/-_U1u666tOcY/WCSWQJyIdWI/AAAAAAAAIBM/95rwJV4bEt8V7gDLNX2JjCBdQ4mbCZiDgCK4B/s640/1.png" width="640" /></a></div><pre class="western"> </pre><pre class="western"><a href="https://www.niksula.hut.fi/~mhiienka/Rpi/linux-headers-rpi/linux-headers-4.4.26-v7%2B_4.4.26-v7%2B-2_armhf.deb">linux-headers-4.4.26-v7+_4.4.26-v7+-2_armhf.deb</a> 20-Oct-2016 21:07 6891064</pre><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">Download it</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><b>Step3:</b></div><div style="line-height: 100%; margin-bottom: 0in;">Now install the downloaded inux headers.</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo dpkg -i linux-headers-4.4.26-v7+_4.4.26-v7+-2_armhf.deb</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">it takes while let it be complete without interrupt process.</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><b>Step 4 :</b></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$cd</span></div><span style="color: blue;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$mkdir kmod</span></div><span style="color: blue;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$cd kmod</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo nano hello-1.c</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">copy and past following programe in file then save it [^X]</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><span style="color: #0b5394;">/*hello−1.c − The simplest kernel module.*/</span><br />
<span style="color: #0b5394;">#include < linux/init.h > //linux/init.h Macros used to mark up functions e.g., __init __exit</span><br />
<span style="color: #0b5394;">#include < linux/module.h > //</span><span style="color: #0b5394;">linux/module.h</span><span style="color: #0b5394;"> Core header for loading LKMs into the kernel</span><br />
<span style="color: #0b5394;">#include < linux/kernel.h > //</span><span style="color: #0b5394;">linux/kernel.h</span><span style="color: #0b5394;"> Contains types, macros, functions for the kernel</span><br />
<br />
<br />
<span style="color: #0b5394;">int init_module(void) </span><br />
<span style="color: #0b5394;"><linux module.h=""><linux kernel.h=""> { <br />
printk(KERN_INFO "Hello world 1.\n");<br />
/*A non 0 return means init_module failed; module can't be loaded.*/<br />
return 0;<br />
}<br />
<br />
void cleanup_module(void) <br />
{ <br />
printk(KERN_INFO "Goodbye world 1.\n");<br />
} </linux></linux></span><br />
<div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">Now for compile this module we need make file </div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo nano Makefile</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">copy and past following code in make file </div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><span style="color: #0b5394;">obj-m += hello-1.o<br />
<br />
all:<br />
make -C /lib/modules/4.4.26-v7+/build M=/home/pi/kmod modules<br />
clean:<br />
make -C /lib/modules/4.4.26-v7+/build M=/home/pi/kmod clean</span><br />
<div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">remember the there is Tab before make.</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">Save it </div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><b>Step 5:</b></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">compile our hello world module</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo make</span></div><div style="line-height: 100%; margin-bottom: 0in;">></div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;">make -C /lib/modules/4.4.26-v7+/build M=/home/pi/kmod modules</span></div><span style="color: #666666;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;">make[1]: Entering directory '/usr/src/linux-headers-4.4.26-v7+'</span></div><span style="color: #666666;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;"> CC [M] /home/pi/kmod/hello-1.o</span></div><span style="color: #666666;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;"> Building modules, stage 2.</span></div><span style="color: #666666;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;"> MODPOST 1 modules</span></div><span style="color: #666666;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;"> CC /home/pi/kmod/hello-1.mod.o</span></div><span style="color: #666666;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;"> LD [M] /home/pi/kmod/hello-1.ko</span></div><span style="color: #666666;"> </span> <br />
<div style="line-height: 100%; margin-bottom: 0in;"><span style="color: #666666;">make[1]: Leaving directory '/usr/src/linux-headers-4.4.26-v7+'</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><b>Step 6:</b></div><div style="line-height: 100%; margin-bottom: 0in;">insert module into kernel</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo insmod hello-1.ko</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">if there is noerror then your module get successfully installed</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><b>Step 7:</b></div><div style="line-height: 100%; margin-bottom: 0in;">to verify it </div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo dmesg</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">You get following result </div><div style="line-height: 100%; margin-bottom: 0in; text-align: center;"> <a href="http://3.bp.blogspot.com/-uwIiYJp26Uc/WCSWnVL_DbI/AAAAAAAAIBU/B1Et8cjqUZMS5ZAKRYH3iCbaDMlJOv_hACK4B/s1600/Capture.JPG" imageanchor="1"><img border="0" height="96" src="https://3.bp.blogspot.com/-uwIiYJp26Uc/WCSWnVL_DbI/AAAAAAAAIBU/B1Et8cjqUZMS5ZAKRYH3iCbaDMlJOv_hACK4B/s640/Capture.JPG" width="640" /></a></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">now to remove module </div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo rmmod hello-1.ko</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">to verify </div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><span style="color: blue;">$sudo dmesg</span></div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">you see the kernel log as follows</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in; text-align: center;"><a href="http://4.bp.blogspot.com/-3su_pep6xRI/WCSWp9_WprI/AAAAAAAAIBc/Es3h8KJQH0UZyDThoXnyxBsHjv2XBBy-ACK4B/s1600/3.JPG" imageanchor="1"><img border="0" height="116" src="https://4.bp.blogspot.com/-3su_pep6xRI/WCSWp9_WprI/AAAAAAAAIBc/Es3h8KJQH0UZyDThoXnyxBsHjv2XBBy-ACK4B/s640/3.JPG" width="640" /></a> </div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;"><br />
</div><div style="line-height: 100%; margin-bottom: 0in;">Thank You . if you have any question comment below or email me. </div><div style="line-height: 100%; margin-bottom: 0in;"></div><div style="line-height: 100%; margin-bottom: 0in; text-align: left;"><br />
</div></div></div></div></div></div>Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0United States37.09024 -95.712891000000013-36.4162205 99.052733999999987 90 69.521483999999987tag:blogger.com,1999:blog-1566744693640221506.post-82752853130937066572016-10-19T08:19:00.000-07:002017-04-11T23:23:07.470-07:00<div dir="ltr" style="text-align: left;" trbidi="on">
<h2 style="text-align: left;">
<b><u>2.4 Ghz channel scanner using NRF24L01 RF Transreceiver :</u></b></h2>
<div style="text-align: left;">
<b>What is 2.4Ghz scanner:</b></div>
<div style="text-align: left;">
My requirement behind this project is I want to make such device which can sniff 2.4Ghz ISM frequency band. But after some research its bit hard and trick to make such device. But I figure it out to made such a device which can locate the particular channel on which data is transmitted. their are some ready made examples for Arduino but none of with GUI that can be easy to understand. here I developed GUI base 2.4GHZ channel scanner( <b>NOT SNIFFER :( </b>).<br />
<div style="text-align: left;">
Here I used channel range from 1 - 126 means NRF2401 having frequency range of <b>2.4Ghz - 2.529GHz</b> which can be divided in 126 channels each one of 1Mhz. so if you want to find wifi channel frequency for particular standard you need to map NRF2401 channel with the standard channel. see the standard <span style="font-weight: normal;"><span class="mw-headline" id="2.4.C2.A0GHz_.28802.11b.2Fg.2Fn.29">802.11b/g/n below and map </span></span><b>2.4Ghz - 2.529GHz = 1 - 126 </b>with this range<b><br />
</b></div>
<div style="text-align: left;">
<span style="font-weight: normal;"><span class="mw-headline" id="2.4.C2.A0GHz_.28802.11b.2Fg.2Fn.29"><br />
</span></span></div>
</div>
<div style="text-align: center;">
<a href="http://4.bp.blogspot.com/-ce-DsDc9aQA/WAeOBhx4fBI/AAAAAAAAH4g/OB7RDV_u15MFeS-WAXJngBlOAfNtE1d-gCK4B/s1600/1080px-2.4_GHz_Wi-Fi_channels_%2528802.11b%252Cg_WLAN%2529.svg.png" imageanchor="1"><img border="0" height="148" src="https://4.bp.blogspot.com/-ce-DsDc9aQA/WAeOBhx4fBI/AAAAAAAAH4g/OB7RDV_u15MFeS-WAXJngBlOAfNtE1d-gCK4B/s640/1080px-2.4_GHz_Wi-Fi_channels_%2528802.11b%252Cg_WLAN%2529.svg.png" width="640" /></a></div>
<div style="text-align: left;">
<b>Required :</b></div>
<div style="text-align: left;">
1) Arduino</div>
<div style="text-align: left;">
2) NRF24L01</div>
<div style="text-align: left;">
3) Microsoft Visual Studio 2015</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Screen Shots and Explanation:</b><br />
<b>Hardware:</b><br />
<div style="text-align: center;">
<b> <a href="http://2.bp.blogspot.com/-UIML-cnKccw/WAeJnAJ4bcI/AAAAAAAAH4U/jAgpHrUMiwM1wGIQMkb6DtOyozU6Rzb2ACK4B/s1600/IMG_20161019_202255.jpg" imageanchor="1"><img border="0" height="312" src="https://2.bp.blogspot.com/-UIML-cnKccw/WAeJnAJ4bcI/AAAAAAAAH4U/jAgpHrUMiwM1wGIQMkb6DtOyozU6Rzb2ACK4B/s400/IMG_20161019_202255.jpg" width="400" /></a></b></div>
</div>
<div style="text-align: left;">
<b>Step1:</b><br />
Start NRF 2.4Ghz Channel Scanner application and attach arduino to your computer. You will see active COM port in application here I got "COM8" . Select baud rate 9600.</div>
<div style="text-align: center;">
<a href="http://1.bp.blogspot.com/-xY2Cq4eQ_6Y/WAeHFnvVwFI/AAAAAAAAH3I/9NvxKMlMn-kkdaDxkGlCU5ZKzPhREJn8ACK4B/s1600/1.jpg" imageanchor="1"><img border="0" height="360" src="https://1.bp.blogspot.com/-xY2Cq4eQ_6Y/WAeHFnvVwFI/AAAAAAAAH3I/9NvxKMlMn-kkdaDxkGlCU5ZKzPhREJn8ACK4B/s640/1.jpg" width="640" /></a></div>
<div style="text-align: left;">
<b>Step 2:</b><br />
Now initialize communication with hardware by click on Init button<br />
<br />
<div style="text-align: center;">
<a href="http://2.bp.blogspot.com/-yhXw8OuqSUA/WAeAj_O94bI/AAAAAAAAH2Y/FoNlQvD204syjgkbezHkOj9RahJbN2SkgCK4B/s1600/2.jpg" imageanchor="1"></a><a href="http://2.bp.blogspot.com/-z5VtHplTL6g/WAeHH10tp1I/AAAAAAAAH3Q/kdr8qhELcXw-RzidvvKpzOeK-BVbWxh7wCK4B/s1600/2.jpg" imageanchor="1"><img border="0" height="344" src="https://2.bp.blogspot.com/-z5VtHplTL6g/WAeHH10tp1I/AAAAAAAAH3Q/kdr8qhELcXw-RzidvvKpzOeK-BVbWxh7wCK4B/s640/2.jpg" width="640" /></a> </div>
application start communication with hardware. hardware send data and application arrange it channel wise. For testing purpose here i used simple RC plane Controller to find out which channel it use to broadcast its request package further I will work to extract data from its packet.<br />
<br />
<b>Step 3:</b><br />
Whene the Controller switch is off the data chart is like this<br />
<br />
<div style="text-align: center;">
<a href="http://1.bp.blogspot.com/-wGabW6x3C6w/WAeDLJsf_bI/AAAAAAAAH2s/JHBXU3uHjqY8KYHeKbiiBX71g2p9g4GMACK4B/s1600/3.jpg" imageanchor="1"> </a><a href="http://4.bp.blogspot.com/-dmLaA6rSPlA/WAeHTq5Uq1I/AAAAAAAAH3o/065QZjw-oFc5VO08Ceb5kWbb5KzL_akEgCK4B/s1600/3.jpg" imageanchor="1"><img border="0" height="342" src="https://4.bp.blogspot.com/-dmLaA6rSPlA/WAeHTq5Uq1I/AAAAAAAAH3o/065QZjw-oFc5VO08Ceb5kWbb5KzL_akEgCK4B/s640/3.jpg" width="640" /></a></div>
<br />
<b>Step 4:</b><br />
Now Switch on Controller but without switching on receiver.<br />
<br />
<div style="text-align: center;">
<a href="http://2.bp.blogspot.com/-cO2enAsMQBM/WAeHWoWyr6I/AAAAAAAAH3w/EPUBgxmzXTQb1Bb1oKsNcE6KM5htDYEJgCK4B/s1600/IMG_20161019_192014.jpg" imageanchor="1"><img border="0" height="240" src="https://2.bp.blogspot.com/-cO2enAsMQBM/WAeHWoWyr6I/AAAAAAAAH3w/EPUBgxmzXTQb1Bb1oKsNcE6KM5htDYEJgCK4B/s320/IMG_20161019_192014.jpg" width="320" /></a></div>
<br />
LED of controller start blinking means it start broadcast packet to find receiver<br />
<br />
<b>Step 5:</b><br />
After some time Arduino send data which carrier signal is detected by it. The signal chart looks like this<br />
<b> </b><br />
<div style="text-align: center;">
<b> <a href="http://3.bp.blogspot.com/-XL65q-XwxaI/WAeHagfD5hI/AAAAAAAAH34/0O54kXPoIzchcrSxfjlFdFHrKPdflvqEgCK4B/s1600/4.jpg" imageanchor="1"><img border="0" height="171" src="https://3.bp.blogspot.com/-XL65q-XwxaI/WAeHagfD5hI/AAAAAAAAH34/0O54kXPoIzchcrSxfjlFdFHrKPdflvqEgCK4B/s320/4.jpg" width="320" /></a></b></div>
<b> </b><br />
In this image see the channel number 82,83,84 and 85 the scanner sense the carrier signals thats mean the RC controller sending request on these four channel ( <span style="color: red;"><b>The color indication :Dark is more packet strick</b></span>).<br />
<br />
<b>Step 6:</b><br />
Now test on some other RF devices here I used Bluetooth which also work on 2.4 Ghz band range.<br />
See the diagram below put module in between two mobile which currently exchanging data. I send Mp3 file form one mobile to other . the result I get shown in Image<br />
<div style="text-align: center;">
<a href="http://1.bp.blogspot.com/-hZB_2qOYMCY/WAeHvSuqChI/AAAAAAAAH4A/6xKOSUxcjV0br5hkkzLgmJAMZTpexeuagCK4B/s1600/7.jpg" imageanchor="1"><img border="0" height="275" src="https://1.bp.blogspot.com/-hZB_2qOYMCY/WAeHvSuqChI/AAAAAAAAH4A/6xKOSUxcjV0br5hkkzLgmJAMZTpexeuagCK4B/s400/7.jpg" width="400" /></a> </div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: left;">
Result of this experiment as follows</div>
<div style="text-align: left;">
<a href="http://4.bp.blogspot.com/-wd3awrXzXVQ/WAeH3L6u5-I/AAAAAAAAH4M/-HjAHPGQ8_8mBVjA2Cg57AJ7gxGtyT_6gCK4B/s1600/5.jpg" imageanchor="1"><img border="0" height="342" src="https://4.bp.blogspot.com/-wd3awrXzXVQ/WAeH3L6u5-I/AAAAAAAAH4M/-HjAHPGQ8_8mBVjA2Cg57AJ7gxGtyT_6gCK4B/s640/5.jpg" width="640" /> </a></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
If you want to go to deep of Bluetooth need to learn <span class="st">FHSS which does not use single channel to transmit data it. so here data sense at number of channel.</span></div>
<div style="text-align: left;">
<span class="st">I am looking forward to make 2.4Ghz sniffer. </span></div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<span class="st">If have any question please comment below or email me.</span></div>
<div style="text-align: left;">
<span class="st"><br />
</span></div>
<div style="text-align: left;">
<span class="st"></span><span class="st"></span> </div>
<b> </b></div>
</div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com1tag:blogger.com,1999:blog-1566744693640221506.post-22710882741909981172016-10-08T04:28:00.006-07:002016-10-16T23:05:59.858-07:00<div dir="ltr" style="text-align: left;" trbidi="on">
<h2 style="text-align: left;">
<u><b>Working on scrolling display:</b></u></h2>
<div style="text-align: left;">
From long time I wish to have my own LED scrolling display now I got some time to work on it.</div>
<div style="text-align: left;">
Here some Photo of it working on simple LED scrolling display.</div>
<div class="separator" style="clear: both; text-align: left;">
Further extension of this module is fetch Facebook notification using wifi and display on scrolling LED display and using Bluetooth display mobile messages on it. ;).</div>
<div class="separator" style="clear: both; text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: left;">
<b>Day1 :</b></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://2.bp.blogspot.com/-A-IQNiV1qnk/V_jYOAx_BwI/AAAAAAAAHxM/hzBT0PgBwiEdfINU4958QyrAtot7osXiACK4B/s1600/IMG_20161005_235928.jpg" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="480" src="https://2.bp.blogspot.com/-A-IQNiV1qnk/V_jYOAx_BwI/AAAAAAAAHxM/hzBT0PgBwiEdfINU4958QyrAtot7osXiACK4B/s640/IMG_20161005_235928.jpg" width="640" /></a> </div>
<div class="separator" style="clear: both; text-align: left;">
<b>Day2:</b></div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-NNqPgPNEY_E/V_jYEmlRVdI/AAAAAAAAHxE/wOLdngCPo5sW4quHwNE3vq6w2bmT3RDIgCK4B/s1600/IMG_20161005_235939.jpg" imageanchor="1"><img border="0" height="480" src="https://2.bp.blogspot.com/-NNqPgPNEY_E/V_jYEmlRVdI/AAAAAAAAHxE/wOLdngCPo5sW4quHwNE3vq6w2bmT3RDIgCK4B/s640/IMG_20161005_235939.jpg" width="640" /></a> </div>
<div class="separator" style="clear: both; text-align: left;">
<br /></div>
<div class="separator" style="clear: both; text-align: left;">
<b>Day 3:</b> </div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-QqNUDUxIHjA/V_jYSSXRVsI/AAAAAAAAHxU/Ln5Q_GFFfqcnjxZ8nOvErgTvM6fHyTLHgCK4B/s1600/IMG_20161008_163613.jpg" imageanchor="1"><img border="0" height="480" src="https://1.bp.blogspot.com/-QqNUDUxIHjA/V_jYSSXRVsI/AAAAAAAAHxU/Ln5Q_GFFfqcnjxZ8nOvErgTvM6fHyTLHgCK4B/s640/IMG_20161008_163613.jpg" width="640" /></a> </div>
<div class="separator" style="clear: both; text-align: center;">
<img border="0" height="640" src="https://1.bp.blogspot.com/-AuMWH75jqTA/V_jYX4dH0OI/AAAAAAAAHxc/_vykZ7OHqB0a62_gBw8-DPuU2ab0uvzyQCK4B/s640/IMG_20161008_163600.jpg" width="480" /></div>
<div class="separator" style="clear: both; text-align: left;">
<br /></div>
<div class="" style="clear: both; text-align: left;">
<b>Day4: </b></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-pIa9gLD4dVQ/WARqNGzoYGI/AAAAAAAAH1M/7mWrgOo2p2wnZJBuVFW8fc1qjlxZjGFxwCK4B/s1600/IMG-20161011-WA0034.jpeg" imageanchor="1"><img border="0" height="240" src="https://3.bp.blogspot.com/-pIa9gLD4dVQ/WARqNGzoYGI/AAAAAAAAH1M/7mWrgOo2p2wnZJBuVFW8fc1qjlxZjGFxwCK4B/s400/IMG-20161011-WA0034.jpeg" width="400" /> </a></div>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-rSRBtkAC3T0/WARp0F-ic9I/AAAAAAAAH1E/0fYBqT-X32M9s58FGnZi7fsfRQ8ACutlQCK4B/s1600/IMG-20161011-WA0029.jpeg" imageanchor="1"><img border="0" height="640" src="https://1.bp.blogspot.com/-rSRBtkAC3T0/WARp0F-ic9I/AAAAAAAAH1E/0fYBqT-X32M9s58FGnZi7fsfRQ8ACutlQCK4B/s640/IMG-20161011-WA0029.jpeg" width="384" /></a></div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div class="separator" style="clear: both; text-align: left;">
</div>
<div style="text-align: left;">
</div>
<div style="text-align: left;">
</div>
<div style="text-align: left;">
</div>
<div style="text-align: left;">
</div>
</div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0tag:blogger.com,1999:blog-1566744693640221506.post-10858756047202851882016-09-27T04:03:00.001-07:002016-09-27T04:03:25.104-07:00<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<h2>
<u>ESP8266 AT firmware : </u></h2>
<div style="text-align: left;">
As in previous post we have seen ESP8266 as stand alone but some time in some application we need only WiFi connectivity or simple WiFi module that can be controlled through AT commands. we can program ESP8266 for work on AT command.</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Required:</b></div>
<div style="text-align: left;">
1) ESP8266</div>
<div style="text-align: left;">
3) USB to serial convertor</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
<b>Step 1: </b></div>
<div style="text-align: left;">
<a href="http://zenelectro.blogspot.in/2016/09/program-esp8266-wifi-modulewith-arduino.html">Setup ESP8266 as given in this post.</a><br />
<b><br /></b>
<b>Step 2:</b><br />
<a href="https://drive.google.com/file/d/0B4tww7CJlZPycVU4aVVYclBUMTg/view?usp=sharing">Download ESP8266 AT command firmware by AI Thinker.</a><br />
<br />
<b>Step 3:</b><br />
press and hold Flash button(GPIO0 = GND) then press Reset button(RESET pin = GND)<br />
release RESET button then Flash button now ESP8266 goes into Flash mode.<br />
<br />
<b>Step 4:</b><br />
Extract downloaded rar file.<br />
<a href="http://3.bp.blogspot.com/-ShiNI5wQIQc/V-pE5x_3bGI/AAAAAAAAHvQ/Yx9WTpTZPIIYSsDSr7LZ-OJHd0O9lliAwCK4B/s1600/Untitled.jpg" imageanchor="1"><img border="0" height="230" src="https://3.bp.blogspot.com/-ShiNI5wQIQc/V-pE5x_3bGI/AAAAAAAAHvQ/Yx9WTpTZPIIYSsDSr7LZ-OJHd0O9lliAwCK4B/s640/Untitled.jpg" width="640" /> </a><br />
<b>Step 5:</b><br />
open "flash.cmd" file and wait for complete flashing process.<br />
<br />
<br />
<a href="http://3.bp.blogspot.com/-7LT0Oyof8YI/V-pFQ2mPCnI/AAAAAAAAHvw/r0PO0suZvm0swZh0pwTesKclqC01tMNYQCK4B/s1600/Untitled1.jpg" imageanchor="1"><img border="0" height="274" src="https://3.bp.blogspot.com/-7LT0Oyof8YI/V-pFQ2mPCnI/AAAAAAAAHvw/r0PO0suZvm0swZh0pwTesKclqC01tMNYQCK4B/s640/Untitled1.jpg" width="640" /> </a><br />
<br />
<a href="http://2.bp.blogspot.com/-I7cRDaKCc5Y/V-pFXarc25I/AAAAAAAAHv4/dyfl-zRMWdYNHUJS1gdUyw41fEjcSbzvwCK4B/s1600/Untitled2.jpg" imageanchor="1"><img border="0" height="270" src="https://2.bp.blogspot.com/-I7cRDaKCc5Y/V-pFXarc25I/AAAAAAAAHv4/dyfl-zRMWdYNHUJS1gdUyw41fEjcSbzvwCK4B/s640/Untitled2.jpg" width="640" /></a><br />
<br />
<a href="http://3.bp.blogspot.com/-1wD3NYwHp5k/V-pFZGTGs1I/AAAAAAAAHwA/2x7Q0IW5xBMow3QBRGqZxDfE3-n7TeF9QCK4B/s1600/Untitled3.jpg" imageanchor="1"><img border="0" height="272" src="https://3.bp.blogspot.com/-1wD3NYwHp5k/V-pFZGTGs1I/AAAAAAAAHwA/2x7Q0IW5xBMow3QBRGqZxDfE3-n7TeF9QCK4B/s640/Untitled3.jpg" width="640" /></a><br />
<br />
<b>Step 6: </b><br />
Setup local Server for receive data. I use TCPClientServe software which allow you to create local server and client to send and receive data over TCP<br />
<a href="http://download.cnet.com/Tcp-Client-Server/3000-2085_4-75913547.html">Download Here</a><br />
<br />
<a href="http://2.bp.blogspot.com/-sbT27tau4mk/V-pRXM8N33I/AAAAAAAAHwQ/asBf0F0ei7kHx0WtzlgoFxZKCtPgyjqhACK4B/s1600/Untitled3.jpg" imageanchor="1"><img border="0" height="584" src="https://2.bp.blogspot.com/-sbT27tau4mk/V-pRXM8N33I/AAAAAAAAHwQ/asBf0F0ei7kHx0WtzlgoFxZKCtPgyjqhACK4B/s640/Untitled3.jpg" width="640" /></a><br />
Enter port 6000 and start listening.<br />
<br />
<b>Step 7 : </b><br />
Open Serial terminal at baudrate 115200<br />
Give Comman Sequence To send data to Server<br />
<br />
1) AT<br />
2) AT+CWAUTOCONN=0 ---> disable autoconnection<br />
3) AT+CWMODE=1 ---> set station mode<br />
4) AT+CWJAP="MyRouter","MyRouterPassword" --->connect to local WiFi router<br />
5) AT+CIPSTA_DEF="192.168.0.123" ---> set static IP<br />
6) AT+CIPSTART="TCP","192.168.0.2",6000 --->your local server IP adress<br />
7) AT+CIPSEND=10 --> number of bytes to send<br />
8) 12345678 ---> actual data to send<br />
<br />
Console Output:<br />
<br />
<span style="color: #666666;"> Ai-Thinker Technology Co.,Ltd.<br /><br />ready<br />AT<br /><br /><br />OK<br />AT+CWAUTOCONN=0<br /><br /><br />OK<br />AT+CWMODE=1<br /><br /><br />OK<br />AT+CWJAP="MyRouter","MyRouterPassword"<br /><br />WIFI CONNECTED<br />WIFI GOT IP<br /><br />OK<br />AT+CIPSTA_DEF="192.168.0.123"<br /><br /><br />OK<br />AT+CIPSTART="TCP","192.168.0.2",6000<br /><br />CONNECT<br /><br />OK<br />AT+CIPSEND=10<br /><br /><br />OK<br />> <br /><br />Recv 10 bytes<br /><br />SEND OK</span><br /><br />
<br />
<br /></div>
</div>
Dhananjay Khairnarhttp://www.blogger.com/profile/00771022579859672696noreply@blogger.com0