not all listeners are decoding all channels

If you have a simple question and just want an answer.
Post Reply
cccuser
Junior Member
Posts: 7
Joined: Wed Aug 11, 2021 7:28 pm

not all listeners are decoding all channels

Post by cccuser »

i am using 2 200 development kits.
i am using one as a talker and the second as the listener

i am using the avb reference design.

on the talker board i have configured it to have 4 talkers. on the board listener i have configured it to have 4 listeners.

on the talker board i have configured it to put out test data for audio samples where each sample contains the stream id and channel number, so i can debug why in this configuration the listener board doesnt always decode all the channels. as follows

int32_t test_sample[32]={0x10101010,
0x11111111,
0x12121212,
0x13131313,
0x14141414,
0x15151515,
0x16161616,
0x17171717,
0x20202020,
0x21212121,
0x22222222,
0x23232323,
0x24242424,
0x25252525,
0x26262626,
0x27272727,
0x30303030,
0x31313131,
0x32323232,
0x33333333,
0x34343434,
0x35353535,
0x36363636,
0x37373737,
0x40404040,
0x41414141,
0x42424242,
0x43434343,
0x44444444,
0x45454545,
0x46464646,
0x47474747,
};


in this configuration when i connected as follows.
talker 1 is connected to listener 1
talker 2 is connected to listener 2
talker 3 is connected to listener 3
talker 4 is connected to listener 4

on the listener board i noticed that on listener 1 i am recieving the correct test audio samples for all 8 channels. on listener 2-4,  i dont see channel 1 i see channel 0, 2-7
since i am trying to use the output channels as not 8 channels but 4 stereo pairs, this bug results in getting left data but not right data but only on streams 2-4. stream and only on channel 1, 0,3-7 are ok. and stream 1 0-7 are always correct.
i verified using wireshark that the avb packets in each stream are always correct. they have all channel data on all streams.

im at a loss to describe why this is happening.
in this configuration, the avb design is setup to use tdm buffering and i am wondering if there is a timing issue but cant explain why it would always only affect streams 2-4

from the test data above i never see 
0x212121, 0x313131 and 0x414141 these outputs are decoded as but only on stream 1. on streams 2-4 they are always 0. this maps to channel 1 on each stream.

any insights would be appreciated.


fabra
Active Member
Posts: 35
Joined: Sat May 09, 2020 4:20 pm
Contact:

Post by fabra »

I recommend to check how the mappings are configured.

/** Get the channel map of an avb source.
* \param i interface to AVB manager
* \param source_num the local source number to set
* \param map the map, an array of integers giving the input FIFOs that
* make up the stream
* \param len the length of the map; should be equal to the number of channels
* in the stream
*/
static inline int get_source_map(
client interface avb_interface i,
unsigned source_num,
int map[],
int &len)

/** Set the channel map of an avb source.
*
* Sets the channel map of a source i.e. the list of
* input FIFOs that constitute the stream.
*
* This setting will not take effect until the next time the source
* state moves from disabled to potential.
*
* \param i interface to AVB manager
* \param source_num the local source number to set
* \param map the map, an array of integers giving the input FIFOs that
* make up the stream
* \param len the length of the map; should be equal to the number of channels
* in the stream
*
**/
static inline int set_source_map(
client interface avb_interface i,
unsigned source_num,
int map[len],
unsigned len)

/** Get the map of an AVB sink.
* \param i interface to AVB manager
* \param sink_num the number of the sink
* \param map array containing the media output FIFOs that the
* stream will be split into
* \param len the length of the map; should equal to the number
* of channels in the stream
*/
static inline int get_sink_map(
client interface avb_interface i,
unsigned sink_num,
int map[],
int &len)

/** Set the map of an AVB sink.
*
* Sets the map i.e. the mapping from the 1722 stream to output FIFOs.
*
* This setting will take affect immediately.
*
* \param i interface to AVB manager
* \param sink_num the number of the sink
* \param map array containing the media output FIFOs that the
* stream will be split into
* \param len the length of the map; should equal to the number
* of channels in the stream
*/
static inline int set_sink_map(
client interface avb_interface i,
unsigned sink_num,
int map[len],
unsigned len)
Post Reply