Matlab: Don't forget commands while the door is open

Fix #8