{"action":"closed","issue":{"url":"https://api.github.com/repos/AVnu/Open-AVB/issues/264","labels_url":"https://api.github.com/repos/AVnu/Open-AVB/issues/264/labels{/name}","comments_url":"https://api.github.com/repos/AVnu/Open-AVB/issues/264/comments","events_url":"https://api.github.com/repos/AVnu/Open-AVB/issues/264/events","html_url":"https://github.com/AVnu/Open-AVB/issues/264","id":99944447,"number":264,"title":"Simple_listener more than one stream issue","user":{"login":"pcub","id":7065417,"avatar_url":"https://avatars.githubusercontent.com/u/7065417?v=3","gravatar_id":"","url":"https://api.github.com/users/pcub","html_url":"https://github.com/pcub","followers_url":"https://api.github.com/users/pcub/followers","following_url":"https://api.github.com/users/pcub/following{/other_user}","gists_url":"https://api.github.com/users/pcub/gists{/gist_id}","starred_url":"https://api.github.com/users/pcub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pcub/subscriptions","organizations_url":"https://api.github.com/users/pcub/orgs","repos_url":"https://api.github.com/users/pcub/repos","events_url":"https://api.github.com/users/pcub/events{/privacy}","received_events_url":"https://api.github.com/users/pcub/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-08-10T00:44:44Z","updated_at":"2015-08-11T08:06:49Z","closed_at":"2015-08-11T08:06:49Z","body":"Two xmos daisy chain (DC) boards are connected to each other (daisy chain topology) without AVB switch and one DC is connected to PC. I want this:\r\nTwo DC as talkers and PC as listener.\r\nListener should now record from 8 audio channels that came from two talkers.\r\nHowever, the signal recorded using simple_listener is not as expected.\r\n\r\nI changed the following part in simple_listener.c:\r\n\r\n#define CHANNELS (8) //8 audio channels\r\nvoid pcap_callback(u_char* args, const struct pcap_pkthdr* packet_header, const u_char* packet)\r\n{\r\nunsigned char* test_stream_id;\r\nstruct ethernet_header* eth_header;\r\nuint32_t buf;\r\nuint32_t frame[2] = { 0 , 0 };\r\nint i;\r\n(void) args; / unused /\r\n(void) packet_header; / unused */\r\n\r\n#if DEBUG\r\nfprintf(stdout,\"Got packet.\\n\");\r\n#endif /* DEBUG*/\r\n\r\neth_header = (struct ethernet_header*)(packet);\r\n#if DEBUG\r\nfprintf(stdout,\"Ether Type: 0x%02x%02x\\n\", eth_header->type[0], eth_header->type[1]);\r\n#endif /* DEBUG*/\r\n\r\nif (0 == memcmp(glob_ether_type,eth_header->type,sizeof(eth_header->type)))\r\n{       \r\ntest_stream_id = (unsigned char*)(packet + ETHERNET_HEADER_SIZE + SEVENTEEN22_HEADER_PART1_SIZE);\r\n\r\n#if DEBUG\r\nfprintf(stderr, \"Received stream id: %02x%02x%02x%02x%02x%02x%02x%02x\\n \",\r\ntest_stream_id[0], test_stream_id[1],\r\ntest_stream_id[2], test_stream_id[3],\r\ntest_stream_id[4], test_stream_id[5],\r\ntest_stream_id[6], test_stream_id[7]);\r\n#endif /* DEBUG*/\r\n\r\n    if (0 == memcmp(test_stream_id, stream_id, sizeof(STREAM_ID_SIZE)))\r\n    {\r\n#if DEBUG\r\nfprintf(stdout,\"Stream ids matched.\\n\");\r\n#endif /* DEBUG/\r\nbuf = (uint32_t) (packet + HEADER_SIZE);\r\nfor(i = 0; i < SAMPLES_PER_FRAME * CHANNELS; i += CHANNELS)\r\n{\r\n\r\nmemcpy(&frame[0], &buf[i], sizeof(frame));\r\nfor(i=0;i<CHANNELS;i++)\r\n{\r\n            frame[i] = ntohl(frame[i]); \r\n            frame[i] &= 0x00ffffff;\r\n            frame[i] <<= 8;    \r\n            sf_writef_int(glob_snd_file, (const int *)frame, 1);\r\n        }\r\n}\r\n    }   \r\n}\r\n}\r\n\r\n1. How to implement this setup?\r\n2. Is there any document?\r\n\r\nThank you."}}