fixed swap bug
added #ifdefs for each ethernet type