bidib: I/O setup (wip)