much work on level switching etc