Intro

You can do easily Programming with the Compiler if you use WIZnet’s Mbed Platform. It is possible to use a sensor suitable for the corresponding interface since ADC, GPIO, SWD, PWM, USART, SPI, and I2C Peripheral are supported. It also supports Ethernet communication, allowing TCP/IP or UDP. In this article, we would like to introduce a method of transmitting an image through TCP communication by connecting a camera sensor to a board.

 

 

STEP 1. Transmitting an image to the Mbed Platform!

Project Link

In this article, we introduce three ways to use Camera Sensor by using WIZnet Mbed Platform but we would like to explain more details the second method. It is easier to access than HTTP or FTP.

WIZwiki-W7500ECO board is used in this article, but WIZnet’s other Mbed Platform can be used without any modification. The camera device and the Mbed board should be connected by UART, and LAN cable should be connected to make network communication environment. You can connect it with a PC directly without a separate switch or hub if you want 1:1 communication with a PC.

This article explains how to open the Socket with TCP Client to send image data to TCP Server. Therefore, there must be a TCP Server to receive image data.

FNM3T80IHMBUQT4.LARGE

 

STEP 2. Materials

2-1. WIZnet Mbed Platform (https://eshop.wiznet.io/shop/chip/wizwiki-w7500)

2-2. Camera Sensor(LJ-DSC02)

2-3. SD Card

2-4. LAN Cable

2-5. Serial Terminal & TCP Server Program (https://hercules-setup.soft32.com/))

 

STEP 3. Prepare!

3-1 Hardware Configuration

camera

3-2 Code Import & Compile

https://os.mbed.com/users/Ricky_Kwon/code/Camera_PCStreaming_WIZwiki-W7500/

becky_curation_1

 

becky_curation_2

becky_curation_3

 

 

3-3 Firmware Upload

drap_n_drop

 

 

STEP 4. Code

You have to modify the code of your network first. The modification is possible in the following section.

Enter the TCP Server information for dest_ip and dest_port.

 

code0

 

Line 37-44 is a process for the opening socket and connecting to TCP Server, and line 51-53 is transmitting data to Server.

code1

From the function of test_jpeg_snapshot_picture(), the callback function sends the image data from jpeg_callback.

code2

 

STEP 5. <Project result>

Camera Image Data can be transmitted from WIZwiki board to PC if you implement the above.

FAD1OLJIHMBUQT5.LARGE

Conclusion

This article briefly introduced how to send image data to the TCP Server.

 

In the case of application, it is possible to transmit data by adjusting the image size according to the request from the Server. You can also use HTTP or FTP communication.

It can be confirmed through the project link in case of HTTP or FTP communication.

https://www.instructables.com/id/Ethernet-Camera-with-mbed-platform-WIZwiki-W7500/

Also, it is recommended to check the above link with the project using the LS-Y201 Sensor as a WIZwiki-W7500 board.

 

 

Curator: Becky

Email: becky@wiznet.io