Bugfixes and implementation of standard FLASH