Bs3 rebased

replaces #1110
Ready for testing.