fixed segmentation of embedded code, and added some clarifying code-comments