/* This function tranfers 1 data sector from memory to RAM.  */
Ctrl_status nand_flash_mem_2_ram(uint32_t addr, void *ram)
/* This function tranfers 1 data sector from memory to RAM.  */
Ctrl_status nand_flash_mem_2_ram(uint32_t addr, void *ram)
{
	if (nand_flash_status == NAND_FLASH_READY) {
		if (!nand_flash_read((addr * SECTOR_SIZE), ram, SECTOR_SIZE)) {
			return CTRL_GOOD;
		}
		return CTRL_FAIL;
	}
	return CTRL_BUSY;
}