Bcms v4 update

Please accept this merge request.
The code now works with BCMS v.4.0.0.alpha