revised getMacAddress