Fix exceptions handling in baremetal script
Fix typos in baremetal script