---
title: "SUPER DISKON INS29SR Serial To Ethernet Converter Board W5100 with ATmega328"
url: "https://maker.wiznet.io/WIZnet/resellers/super-diskon-ins29sr-serial-to-ethernet-converter-board-w5100-with-atmega328/"
markdown_url: "https://maker.wiznet.io/WIZnet/resellers/super-diskon-ins29sr-serial-to-ethernet-converter-board-w5100-with-atmega328/md"
type: "VAR: Value-Added Reseller Products"
author: "Jakarta Barat"
author_url: "https://www.bukalapak.com/p/komputer/aksesoris-226/aksesoris-lainnya-241/3geyc9j-jual-super-diskon-ins29sr-serial-to-ethernet-converter-board-w5100-with-atmega328-rrrr"
editor: "WIZnet"
editor_url: "https://maker.wiznet.io/"
original_author: "Jakarta Barat"
original_url: "https://www.bukalapak.com/p/komputer/aksesoris-226/aksesoris-lainnya-241/3geyc9j-jual-super-diskon-ins29sr-serial-to-ethernet-converter-board-w5100-with-atmega328-rrrr"
published: "2023-04-04"
language: "en"
likes: 1
views: 412
comments: 0
source: "WIZnet Makers (https://maker.wiznet.io/)"
---

# SUPER DISKON INS29SR Serial To Ethernet Converter Board W5100 with ATmega328

> SUPER DISKON INS29SR Serial To Ethernet Converter Board W5100 with ATmega328

Original author: Jakarta Barat (source: https://www.bukalapak.com/p/komputer/aksesoris-226/aksesoris-lainnya-241/3geyc9j-jual-super-diskon-ins29sr-serial-to-ethernet-converter-board-w5100-with-atmega328-rrrr)

## Article

#### Overview

The Serial to 10/100 Ethernet product is a device that converts serial communication data to Ethernet data. The product has two main features.

First, the product can connect various devices to an Ethernet network using a serial port. This makes it easy to transfer data between serial devices and Ethernet networks.

Second, the product provides a 10/100 Ethernet port to provide fast data rates. This allows you to increase the data transfer rate in applications that require high bandwidth and improve the performance of your system.

Based on these features, Serial to 10/100 Ethernet products are used in a variety of applications. For example, in factory automation systems, Serial to 10/100 Ethernet products are used to connect robots, PLCs, and other control devices to an Ethernet network to transmit real-time data. They are also used to connect IP cameras, intercom systems, and other network devices. This allows users to manage serial devices more efficiently and improve the overall performance of the system.

#### Example Code

Serial temperature data to Modbus protocol based on Arduino IDE with ATMega328 + W5100 Ethernet shield. (Code generated by chat.GPT)

```
#include &lt;SPI.h>
#include &lt;Ethernet.h>
#include &lt;ModbusIP.h>

#define SRL_RX 0
#define SRL_TX 1
#define SRL_BAUD 9600

#define MB_PORT 502

EthernetServer server(MB_PORT);
ModbusIP modbus;

void setup() {
Serial.begin(SRL_BAUD);
Ethernet.begin(mac);

modbus.config(server, 192.168.1.177, MB_PORT);
modbus.addHreg(0, 0); // Serial temperature data
}

void loop() {
// Read Serial temperature data
float temperature = readTemperature(); //

// Write data to Modbus register
modbus.Hreg(0, (int)(temperature * 10)); // temperature * * 10

modbus.task();
}

float readTemperature() {
}
```

In the code above, `SRL_RX` and `SRL_TX` are the serial port pin numbers of the ATmega328, and `SRL_BAUD` is the baud rate of the serial communication. MB_PORT` is the Modbus TCP port number, and `modbus.addHreg(0, 0)` is the code to add a Modbus register to store the Serial temperature data.

The `readTemperature()` function is the function to read the Serial temperature data. This function reads the temperature from the Serial sensor and returns it. You will need to implement this function yourself.

The `loop()` function calls the `readTemperature()` function to read the Serial temperature data, and then uses the `modbus.Hreg()` function to write to a Modbus register, which stores the temperature multiplied by a factor of 10. This is because the Modbus protocol does not support real numbers.

If you open the above code in the Arduino IDE, implement the `readTemperature()` function yourself, and upload it to the ATmega328 and W5100 Ethernet shield, you will have a Serial to Ethernet converter that can process Serial temperature data with the Modbus protocol.

---

Source: https://maker.wiznet.io/WIZnet/resellers/super-diskon-ins29sr-serial-to-ethernet-converter-board-w5100-with-atmega328/
