Tag Archives: wifi

Seg 1: Temperature sent to Cloud by using Arduino and wifi

3.1 Problem presention: how to use Arduino and wifi for sending temperature to remote cloud

In this section, we will give a presentation how can we send the measured temperature data to the remote cloud by using Arduino control board and wifi module. Then, by login into the distributed clients, you can check the temperature around your lovers at any countries in the remote Atlantic side. Certainly, if using many types of sensors, you can check and read many other required information.

3.2 Hardware and software

The required materials in this experiment are shown in Table 3-1.

Table 3-1: the required materials


name quantity function note


Arduino software 1 platform


server 1 Collection data


Wifi module 1 Wireless communication


Arduino shield board 1 Connection wifi All version


USB to serial RS232 1 conversion


5V1A voltage adapter 1 voltage


antenna 1 Transmit wifi signal optional


HTC mobile phone 1 Wifi hot spot


client 1 Read data

The hardware materials can be seen in Figrue 3-1.

Figure 3-1 Hardware

Seg 7: Look for the wifi networks

(2) Look for the wifi networks

Figure 2-8 Look for the wifi network signal

After setting the relevant parameters by the above-mentioned step (1), we can find the wifi signal transmitted from wifi board according to the followings.

  1. After power on the wifi board for about 30 seconds, the three LED lights would be exhibited normally. That is, LED1 is lighting with red all the time, LED2 is light with green all along as well, and LED3 is blinking with green light. The relevant context can be referred as shown in Section 2.3. Then, clicking the network icon, you would find there are many wireless network signals, where there is a named as HI_LINK_XXXX wifi signal, which is the wanted wireless wifi network signal. Therefore, we can double click such wifi signal, then it is needed to input password 12345678, which is the default password. If it is the first connection, it needs us to input the password, but thereafter, we may not input the password. Note that, the later 4 letters “XXXX” in the wifi signal name HI-LINK_XXXX is denoted by the different names, since their names may be different according to the different wifi devices. For example, in our such example, the name of wifi signal is HI-LINK_0021, which is also the same as the name encountered in the mobile phone. After double clicking the HI-LINK_0021 wifi signal and input the password, we can make the computer connect to the wifi module on the Arduino shield board, as shown in Figure 2-8.
  2. According to 1), we can connect the wifi network HI-LINK_0021 transmitted from wifi module. Then, return to the network-serial assistant shown in Figure 2-6, click the “Open” button on the left serial setting, and click the “Connect” on the right wifi setting, which are denoted by opening the serial port COM6 and connecting wifi network HI-LINK_0021, as shown in Figure 2-9 with red label. Note that, if the serial port doesn’t open, or the wifi network doesn’t be connected, the buttons “Open” and “Connect” would not work normally, and thus we cannot change the states of buttons “Open” and “Connect”. In other word, “Open” cannot be changed into “close”, and “Connect” cannot be changed into “disconnect”.

Figure 2-9 open the serial port and connect wifi network

  1. After connecting the serial port and wifi networks by Figure 2-10, we can transmit and receive data between serial port and wifi module, as shown in Figure 2-11. When we send a digital number “1″ at serial port, then we can receive “1″ at wifi network. Similarly, if sending “1″ at wifi networks, we can receive “1″ at serial port. Thus, we have realized the normal communication between serial port and wifi network.

    Figure 2-10 WIFI connection based on Arduino shield board

    Figure 2-11 Communication between serial port and wifi network

Seg 5: Get a better view of the LED lights on wifi board

  1. Get a better view of the LED lights

    If you get a better view of the wifi board, there are three LED lights. As the above-mentioned, if the insertion direction is right on the wifi board, the three LED lights would be lightened, as shown in Figure 2-4, where LED1 is the indicator for the power source, if the LED is light with red all the time, it shows that the power source works normally; LED2 is lighting with green, which shows the wifi module works normally; vice versa, the wifi module cannot work normally if LED2 is dark. LED3 is denoted by the state of wireless transmission. If LED3 is shining fast, it shows that the wifi module is transmitting data, and shining slowly shows that the wifi module is idle and has no data to transmit. Moreover, if LED3 is dark, it shows the wifi module close the wireless transmission.

Note that, if the wifi module has ever been used (i.e., it is not a new wifi module). To ensure the configuration is right, the wifi board should recovery the factory default setting. If wifi board is already default setting, you can skip over this step. Firstly, give the wifi board a 5V (350mA) power and wait about 30 seconds. Then press the RST button on the Arduino shield board for about 6s, as shown in Figure 2-5. The wifi board would reboot. After this, the wifi board can return to the default factory setting.

Fgure 2-5 RST button on the Arduino shield board

Seg 1: WIFI wireless communication module serial debug based on the Arduino shield board

2.1 Problem presentation: how to use serial tools to debug wifi module?

In this part, we will discuss whether a new wifi module works normally. For this purpose, we can from the following two aspects.

  1. From the wifi hardware, we can judge whether a new wifi module normally work from its pilot lamp;
  2. By using the serial tools to debug the wifi module from software. Note that, in this section, the serial software includes mobile and computer (PC) version.

2.2 Hardware and software

For debug whether a new wifi module normally work, we need the following hardware and software, as shown in Table 2-1.

Table 2-1 the required materials


name quatity function note


Wifi module 1 Wireless communication


Arduino shield 1 Wifi connection


USB to RS232 1 Transformation and connetion


5V1A voltage adapter 1 Provide voltage


antenna 1 Transmit wifi signal


PC tools 1


Mobile tools 1

The required materials are shown in Figure 2-1.

Figure 2-1 Hardware of network serial debug

Seg 1: What is wifi

  1. Problem presentation: know Wi-Fi

In the basic part of Arduino, we have known Arduino to some extent. From this part, we will come to learn the knowledge on the combination of Arduino and wireless communication, which can promote us interact with Arduino. In the first chapter, we will simply get at the relevant concepts and basic knowledge about Wi-Fi (which is also written as wifi) to prepare the future work.

  1. What is wifi

WIFI is the abbreviation of Wireless Fidelity, which is a technology working in the vicinity of the frequency 2.4/5GHz. Its velocity is relative high, and the distance is relative long. Moreover, it is compatible with the existing 802.11 DSSS devices. DSSS (Direct Sequence Spread Spectrum) is a wireless sequence transformation way with high security and anti-interference. DSSS can extend the signal spectrum at send end by utilizing the high velocity spread sequence. Naturally, at the receive end, by using the decoding with the same spread spectrum code sequence, the extended signal can restore to the original signal. This is the principle of direct sequence spread spectrum (DSSS). Wifi can be read as [waifai]. The wireless router shown in Figure 1-1 is already used the wireless communication technology, i.e., wifi.

Figure 1-1 Wi-Fi wireless router