A thermodynamic model previously outlined for the prediction of the bonding in amorphous hydrogenated carbon-nitrogen alloy films (a-CxNyHz), is extended here to include the effects of enthalpy and entropy. Predictions are presented for the bonding of tetrahedral C(sp3), trigonal C(sp2), pyramidal N(sp3), and trigonal N(sp2) atoms in the alloy as well as the bonding of H to these atoms. When bond energies alone are considered, it is predicted that typical a-CxNyHz films will undergo a phase separation into graphitic regions containing C(sp2) atoms, and C(sp2)-N(sp3)-H groups, and diamond-like or polymeric regions containing only C(sp3) and H atoms. When the effects of entropy are also included, phase separation is eliminated and C(sp3)-C(sp2), C(sp2)=N(sp2), and C(sp2)-N(sp2), bonds are also predicted to be present. The model predictions are compared with experimental results for typical amorphous a-CxNyHz alloys that have been prepared via plasma-enhanced chemical vapor deposition from mixtures of nitrogen and acetylene. In a film with y=0.07 the carbon atoms sp3/sp2 ratio is predicted to be 0.7, while 80% of N atoms are predicted to be trigonal N(sp2) atoms.