some changes to fit latest API changes in freehal-core