some changes to make it compatible with the LightBlueBean