swap lua to use tointeger

goes with https://github.com/tessel/runtime/pull/637. also fixes https://github.com/tessel/firmware/issues/107