Do not call possible blocking call from ISR.

Create separate assert for ISR.
Added asserts for possible buffer overflow.