refactored abb.py and fixed server mutex bug