modified LunaComm related code