fixed problems introduced due to a scoping bug in MPS (expressions and types from BL were used instead of mbeddr