X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=src%2Fcore%2Fao_storage.c;h=66394e01296a199d6832f3dded53448e827009cb;hb=29edf6d901432a1afc65900ff599c963edac5a2b;hp=6ffca0e5f10313f70f687701652abc6f6c8f0b11;hpb=9513be7f9d3d0b0ec29f6487fa9dc8f1ac24d0de;p=fw%2Faltos diff --git a/src/core/ao_storage.c b/src/core/ao_storage.c index 6ffca0e5..66394e01 100644 --- a/src/core/ao_storage.c +++ b/src/core/ao_storage.c @@ -15,7 +15,7 @@ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#include "ao.h" +#include uint8_t ao_storage_read(uint32_t pos, __xdata void *buf, uint16_t len) __reentrant @@ -103,7 +103,7 @@ ao_storage_dump(void) __reentrant } } -#if 0 +#if HAS_STORAGE_DEBUG /* not enough space for this today */ @@ -160,6 +160,7 @@ ao_storage_zapall(void) __reentrant void ao_storage_info(void) __reentrant { + ao_storage_setup(); printf("Storage size: %ld\n", ao_storage_total); printf("Storage erase unit: %ld\n", ao_storage_block); ao_storage_device_info(); @@ -168,7 +169,7 @@ ao_storage_info(void) __reentrant __code struct ao_cmds ao_storage_cmds[] = { { ao_storage_info, "f\0Show storage" }, { ao_storage_dump, "e \0Dump flash" }, -#ifdef HAS_STORAGE_DBG +#if HAS_STORAGE_DEBUG { ao_storage_store, "w ...\0Write data to flash" }, #endif { ao_storage_zap, "z \0Erase " },