fixed createDevice did not return true