Fixed trim issue and updated constants.