Monthly Archives: October 2013

Seg 4: Hardware connection

2.3 Hardware debug

Generally speaking, a new wifi module is no problem in use. But for ensure to use, we can debug the new wifi hardware from the following.

  1. Hardware connection

    Fistly, wifi module is inserted into the Arduino shield board. Note that the insertion direction. A way for the judgment of direction is by the power. When power on, if the insertion direction is not right, then only one red LED light is lightened for the wifi module, and the remaining LED lights cannot be lightened (in fact, the remaining two LED lights is weakly shinning if you see them detailedly, since there exists interface around the two LED lights). Vice visa, if the insertion direction is right, then LED light is lightened and red at first. After a while, the other two LED lights can be lightened, where one LED light would be shining regularly.


    Figure 2-4 Description of LED lights for wifi module

Seg 3: Arduino shield board

  1. Arduino shield board

    From Figure 2-1, the Arduino shield board has two power provision ways; one is RS232 interface. As show in Figure 2-1, by using the cable USB to RS232, wifi signal can be changed into USB signal to computer by RS232 interface. So, when the wifi module are inserted into the Arduino shield, the power is provided by USB cable. But, since the Arduino and the shield board are powered by USB from computer, it may be not enough for the power source. Therefore, the best way to provide voltage is the use of power adapter. This can promise the enough power. In addition, by utilizing such Arduino shield, the communication ways can be wifi and Bluetooth (ble) for the short wireless communication.

Seg 2: wifi module

  1. Wifi module

    From Figure 2-1, wifi module has two rows of pins. If seen it in detail, there are labels for the two rows pins in wifi module, i.e., p1 and p2, which is denoted by the first row pins and the second ones. Each row of pins has 14 pins. Certainly, different type of wifi module is corresponding to the different labels. For example, wifi module is shown in Figure 2-2 has a mental shell, which facilitates heat dissipation, and its pins are labeled from 1 to 28. Similarly, all of the pins are arranged into two rows, each of which has 14 pins. Its schematic diagram could be seen in Figrue 2-3. When the 28 pins are inserted into the Arduino shield board, wifi signal is changed into serial signal, and/or vice versa. In general, there are two MAC addresses in the wifi module, which are used to look for the Application Point (Ap). The relevant context can be referred to the association in the first lesson part.


    Figure 2-2 wifi module with mental shell


    Figure 2-3 Schematic diagram of wifi module (unite: mm)

    Table 2-1 Definitions of pins in the wifi module

number

function

direction

description

1

VCC

Power In

5V power input

2

GND

GND

Power grand

3

WLAN_LED

O

WIFI start instruction

4

VDD

Power Out

3.3V power output

5

LINK2

O

Net gape 2 connection instruction

6

USB_P

I/O

USB signal +

7

USB_M

I/O

USB signal -

8

STA/GPIO_0

I/O

Status instruction/GPIO_0

9

GPIO_1

I/O

GPIO_1

10

ES/RST

I

Exit the passthrough/recovery factory value

11

TX0P2

A

Net gape 2 TX-P

12

TXON2

A

Net gape 2 TX-N

13

RXIP1

A

Net gape 1 RX-P

14

RXIN1

A

Net gape 1 RX-N

15

RXIN2

A

Net gape 2 RX-P

16

RXIP2

A

Net gape 2 RX-P

17

TXON1

A

Net gape 1 TX-N

18

TXOP1

A

Net gape 1 TX-P

19

RTS_N/GPIO_2

I/O

Net gape 2 RTS

20

UART_RX

I

Serial 1 RX

21

UART_TX

O

Serial 1 TX

22

RXD/GPIO_3

I/O

Serial 2 RX

23

LINK1

I/O

Net gape 1 connection instruction

24

CTS_N/GPIO_4

O

Serial 1 CTS

25

WPS/RST

I

WPS button/recovery factory value

26

TXD/GPIO_5

O

Serial 2 TX

27

VDD_1_8

Power Out

Net gape 1.8V output

28

VCC

Power In

5V input

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

number

name quatity function note

1

Wifi module 1 Wireless communication

2

Arduino shield 1 Wifi connection

3

USB to RS232 1 Transformation and connetion

4

5V1A voltage adapter 1 Provide voltage

5

antenna 1 Transmit wifi signal

6

PC tools 1

7

Mobile tools 1

The required materials are shown in Figure 2-1.


Figure 2-1 Hardware of network serial debug