---
title: "How to use ioLibrary with Simulink?"
url: "https://maker.wiznet.io/forum/14336"
markdown_url: "https://maker.wiznet.io/forum/14336/md"
type: "Forum topic"
category: "Ethernet Chips"
author: "Matt Danecca"
created: "2021-08-26T13:10:32+09:00"
last_activity: "2022-04-01T01:29:16+09:00"
language: "en"
views: 369
replies: 4
source: "WIZnet Makers forum (https://maker.wiznet.io/forum/)"
---

# How to use ioLibrary with Simulink?

## Question

Asked by Matt Danecca on 2021-08-26 in Ethernet Chips.

Hi, I have a W5500 chip connect to my NXP S32K148 by SPI. I only need to send data out and not receive. I have a block to transmit SPI data on the master, what would be the best way to add this into my Simulink model so I can send data out onto ethernet?

Thanks!

## Replies

### Reply 1 by louis, 2021-08-27

Hi matt,

W5500 has one 16KB TX memory for Socket n TX Buffer Blocks and one 16KB RX memory for Socket n RX buffer Blocks. 16KB TX memory is initially allocated in 2KB size for each Socket TX Buffer Block.

[![image](https://maker.wiznet.io/forum_uploads/wiznet/original/2X/1/16b5d8d7674c5d1bd1f75dee643a70ac3a74bc81.png) image621×865 67 KB](https://maker.wiznet.io/forum_uploads/wiznet/original/2X/1/16b5d8d7674c5d1bd1f75dee643a70ac3a74bc81.png)

Thank you.

### Reply 2 by Matt Danecca, 2021-08-27

Hi, I only need to send 400 bytes of data every 100ms so I guess I only need to use 1 socket Tx buffer as that is 2K? Do I pack the buffer at 100ms then send SEND command, clear the buffer then repeat every 100ms?

### Reply 3 by louis, 2021-08-27

Yes, 400bytes are sufficient to transmit to 1 socket.

Thank you.

### Reply 4 by yuvsaha123, 2022-04-01

Matt_Danecca:

> Hi, I only need to send 400 bytes of data every 100ms so I guess I only need to use 1 socket Tx buffer as that is 2K? Do I pack the buffer at 100ms then send SEND command, clear the buffer then repeat every 100ms?

thanks my issue has been fixed.

---

Source: https://maker.wiznet.io/forum/14336
