implemented init of emac