Tool/software: Linux
Hi everyone,
(Running latest SDK to date ti-processor-sdk-linux-am57xx-evm-03.01.00.06)
I have to use UDP for my project, and I am testing the UDP capability on AM5728 EVM.
My configuration: AM5728 directly connect to host linux PC in VM through gigabit cable. My host application sends 18kbyte and 13kbyte packets (through different ports) to EVM at 500 packet per second each. Total transmitting speed is 15.5 Mbyte/s.
The receiver side (EVM) has no problem receiving the data, except that when user input occurs (touch screen, keyboard, mouse, etc), I see an instant packet drop(s).
I also see a small number of packet drop even just launch "top" to monitor cpu usage. It drops 80-100 packets of every million packets.
Without any user input or and any other application running aside, UDP drops 1 or 2 packet of every million.
Question:
1) Is it expected to happen as user input event may take too much time on the system?
2) Will it solve the problem if I use UDP interrupt/event instead of while()?
Pseudo code on the EVM side:
main()
{
while(1){
if ((recv_len_1 = recvfrom(s1, buf1, BUFLEN_1, 0, (struct sockaddr *) &si_other_1, &slen_1)) == -1)
die("recvfrom()");
else
readbuffer1();
if ((recv_len_2 = recvfrom(s2, buf2, BUFLEN_2, 0, (struct sockaddr *) &si_other_2, &slen_2)) == -1)
die("recvfrom()");
else
readbuffer2();
}
void die(char *s)
{
perror(s);
exit(1);
}