Ok, this setup works a little differently than you seem to believe.
The Yamaha sound bar responds to the NEC1 IR protocol, device 120. The Comcast red button remote is not able to send these signals, unless programmed with a JP1 cable (about $20).
Instead, your remote is controlling the LG TV. When the TV is setup to send sound to external speakers, the audio signal which the TV sends to the speaker bar is controlled by the TV volume setting. I suppose that if the TV is turned off, the sound bar recognizes that there is no signal at all, and it aslo shuts off. LG has chosen, at least for some models, to not mute the sound to the external speakers
, even though the TV has received a IR mute signal.
Setup code 10030 is NEC1 device 4, which a LG TV will respond to, at least for basic functions.
Your choices are to get a JP1 cable
and use free software to upload the capability to control the sound bar to the Comcast remote--and to be able to extend the functionality of the Comcast remote in other ways.
Or, you could buy a RCA RCRP05B, and use setup code Audio 1375 (or 1331) for the sound bar, Cable 1982 (or 1376) for the Comcast box, and TV 0178 for the LG TV. You would also use Volume punch through to cause the IR signals for volume and mute to be sent to the sound bar rather than the TV. Atlas remotes used by many cable companies would also work in the same way.