adapting code to biicode