Appendix A. Programming Guide - Advantech EH-8100 Reference Manual

Ethernet & tcp/ip protocols stack
Table of Contents

Advertisement

Appendix A. Programming Guide

1. Notes when executing "Close command"
A. Recommendations before executing "Close command" When you execute "close command" in
the Ethernet I/F of EH-8100-Lx, check whether "Tx buffer" is empty first.
Only when it is empty, execute "close command". If you execute "close command" with "Tx
buffer" filled, there could be problems of flooding of FIN and ACK packet
.
B. Recommendations after executing "Close command" You can use both "interrupt method" and
"polling method" to check whether right sockets are closed properly after executed "close
command" at the Ethernet I/F of EH-8100-Lx. In "interrupt method", you can confirm normal
socket close by checking "interrupt status register", and in "polling method", you can verify socket
close by reading socket status register of currently handling channels periodically. One more thing
to be cautious is that when you execute "close command" in the Ethernet I/F of EH-8100-Lx, socket
status becomes "closed (0x00)" for a certain time. But it will return to its normal status shortly. So
just disregard the phenomena and proceed to your normal steps.
2. Notes when setting "MSS maximum value"
Maximum MSS value of the Ethernet I/F of EH-8100-Lx is limited to 1460 in UDP or IP Raw mode.
Therefore, do not set an MSS value greater than 1460 in UDP or IP Raw mode.
3. Notes when processing data in "IP Raw mode"
Don't use the value as a data length. The data length value which was received in IP Raw mode
should be recalculated by adding 4 bytes for use.
4. Notes when handling "Shadow register"
As internal pointer register is 4 bytes and data bus for CPU is 1 byte in the Ethernet I/F of
EH-8100-Lx, there is Shadow register in order not to update pointer register by operations of the
Ethernet I/F of EH-8100-Lx while CPU is reading pointer register. If interrupts are generated during
reading Shadow register, Shadow register value can be changed. To prevent this unexpected
function, we recommend you to disable external Interrupt while reading Shadow register.
- 30 -

Advertisement

Table of Contents
loading

Table of Contents