Mechanism of activated chemiluminescence of cyclic peroxides: 1,2-dioxetanes and 1,2-dioxetanones.