]> git.sur5r.net Git - openocd/blobdiff - src/flash/lpc288x.c
ocd_flash_banks now returns empty list when no flash banks are configured instead...
[openocd] / src / flash / lpc288x.c
index 09f4be85881e5df6ae799920f27910e96bc8ee43..8c438f8e4ced22c8c7637138e7a2c7e8cfcf2eec 100644 (file)
@@ -138,7 +138,7 @@ u32 lpc288x_wait_status_busy(flash_bank_t *bank, int timeout)
        target_t *target = bank->target;
        do
        {
-               usleep(1000);
+               alive_sleep(1);
                timeout--;
                target_read_u32(target, F_STAT, &status);
        }while (((status & FS_DONE) == 0) && timeout);
@@ -270,6 +270,7 @@ u32 lpc288x_system_ready(struct flash_bank_s *bank)
        
        if (bank->target->state != TARGET_HALTED)
        {
+               LOG_ERROR("Target not halted");
                return ERROR_TARGET_NOT_HALTED;
        }
        return ERROR_OK;
@@ -456,6 +457,7 @@ int lpc288x_probe(struct flash_bank_s *bank)
        
        if (bank->target->state != TARGET_HALTED)
        {
+               LOG_ERROR("Target not halted");
                return ERROR_TARGET_NOT_HALTED;
        }