Does N2 bond with Oxygen atoms in the atmosphere?
Well you will notice that 78% of the atmosphere is N2 and 20% is O2 so these gases make up nearly all of the gases in the air and therefore they do not react very easily together. As you noticed though there are NxOy (NO, NO2,N2O2, N2O etc) compounds which obviously exist. These require some very serious and extreme reaction conditions to form. They form naturally through lightening (and this to my knowledge is the only natural method that produces these compounds). Car engines though combust petrol in the air at high temperatures to form these compounds. I don’t know if there is a ‘general rule’ but the reaction conditions must have sufficient energy to break the bonds of the N2 molecule which is pretty inert. This wikipedia article might be helpful. EDIT: I forgot another natural method of forming these would be a photochemical method.