Added firmware code