Buy from US | Buy from UK | Buy from DE | Buy from IT | Buy from FR | Buy from ES | ここでご購入を! |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
In Lesson 2, we learned how to use browser send control signal to a remote device and turn On/Off an LED. In this lesson, we’ll show how to read remote sensor data to your cell phone APP. We will use a photoresistor(light sensor) to read remote environment light value. This is very useful in farms, greenhouses to control the light of plants.
OSOYOO Basic board x 1
OSOYOO ESP8266 Wifi Shield x 1
Photoresistor sensor Module x 1
USB cable x 1
Jumper wires several
First, please insert the ESP8266 wifi Shield into your basic board,
Make sure jumper cap connected E_TX to D4 and E_RX to D5.
Connect your Photoresistor with Uno as following diagram,
A couple of notes before you get started:
OSOYOO Basic Board | Photoresistor sensor module |
A0 | S |
GND | – |
5V | + |
Step A) Install latest IDE from https://www.arduino.cc/en/Main/Software?setlang=en. If you have IDE version after 1.1.16, please skip this step).
Step B) Connect the OSOYOO Basic board to computer via USB cable,
Step C) Open the IDE and choose corresponding board type and port type for you project.
Step D)Download the sketch file from : https://osoyoo.com/driver/wifi-iot/lesson3/wifi-lesson3.zip
Unzip the download file and enter the folder wifi-lesson3
Step E) IDE: Click file -> click Open -> choose code “wifi-lesson2”, load up the sketch onto your IDE.
In the sketch, find following lines:
char ssid[] = "******"; // replace *** with your wifi network SSID (name) char pass[] = "******"; // replace *** with your wifi network password please replace the ****** with your correct wifi SSID and password, otherwise your project can not connect to Internet. Step F) Upload the sketch to your IDE.![]()
![]()
Step A)Open your Serial Monitor, you can see your router will assign an IP address to your IDE as following:
Step B) Open your OSOYOO IOT UDP Robot APP , If you haven’t installed this APP, please read APP installation section in Lesson 2
Step C)Make sure your Cell phone is in the same Local Network of Arduino. Open the APP, click Settings, enter your Arduino IP address from Step F and Port to 8888 in settings:
Now press any Key of your APP, your screen will display something like following picture:
The value of 982 , 5% of maximum sensor value means the environment is very dark.
DownLoad Url osoyoo.com