Added msgLen function, testing now...