add IB support
Refactored init code.