BaSO4 and carbon on heating reacts to produce
BaSO4+4CHeat−−−→BaS+4CO
Thus, on heating they produce BaS + 4CO.