TotalPhase-Blog-Erlebniswelten

How can I send large data transactions using the Aardvark

Question

For a communication scenario, I am using the Aardvark Software API for data transactions. Here is the call that I am using:

aa_i2c_write (handle, deviceAddress, AA_I”C_NO_FLAGS, numbytes, bufferin)

If I define numbytes=300, is there a limitation when sending data due to the buffer size of 64 bytes? In other words, I would like to know what is the maximum size of data (number of bytes) that the Aardvark I2C/SPI Host Adapter can process.

Answer

For the Aardvark adapter, the buffer space is 64 bytes, and the maximum slave response is 64 bytes. However, the transactions can be much larger. Here are the details:

The size of the I2C and SPI buffers are 16 Kbytes each - they can hold many separate transactions. These buffers are only used when an Aardvark API call is invoked. This buffer size is adequate for your use, as the overall limitation for asynchronous messages is determined by the operating systems internal buffer size.

The Aardvark adapter can reliably send and receive transactions of 4 Kbytes or less as an SPI master or slave. This is due to operating system issues and the full-duplex nature of the SPI signaling.

When configuring Aardvark adapter for Master Write, the maximum message size is 64k (65535) bytes when using 7-bit addressing and 64k-1 (65534) bytes when using 10-bit addressing. For more details about addresses, please refer to this knowledge base article: 7-bit, 8-bit, and 10-bit I2C Slave Addressing.

Please note, the number of bytes that can be written in the API call  aa_i2c_write is 65535. 

I2C programming & debugging tools

Aardvark I2C/SPI Host AdapterAardvark I2C/SPI Host Adapter
Aardvark I2C/SPI Host Adapter
TP240141
Erase, program, verify Memory Devices - The Aardvark I2C/SPI Host Adapter is a fast and powerful I2C bus and SPI bus host adapter through USB.

€309.00*
Beagle I2C/SPI Protokoll Analyzer - Total Phase
Beagle I2C/SPI Protocol Analyzer
TP320121
The versatile Beagle I2C/SPI Protocol Analyzer is the ideal tool for the embedded engineer who is developing an I2C, SPI, or MDIO based product.

€369.00*
Promira I2C/ SPI/ eSPI Platform
TP500110-S
Promira is a universal hardware platform usable for a variety of applications, like I2C, SPI and eSPI.

Variants from €900.00*
€1,060.00*