Solution 1: Connect the digital audio output of the accessory device to the digital audio input of the TV and assign this input to the corresponding HDMI input to which the device is connected.
Solution 2: Connect the analog audio output of the accessory device to the analog audio input which serves as a back-up audio connector for the HDMI inputs. Assign this input to the corresponding HDMI input.