Meaning of the error codes for DB backup to flash

FAQ #101284

With the function codes SYSRD K 3000 or K 3100 it is possible to read the flash status (to check whether the flash is ready for backing up extension memory to flash).

Not all return values are mentioned in the manual versions until version 9.

 

Read Flash Status

Reads the Flash status and stores it in the ACCU and a Register with a SYSRD

SYSRD  K 3000  ;for PCD with FlashCard
  K 3100 ;for PCD Onboard Flash (PCD3 and PCD2.M5) 


Result

  • If the ACCU is set Low and the return value in the register is 0 --> OK
  • If the return value in the register is not 0 --> please refer to the list of status bits below for the reason why the flash can not be used.
  • If the ACCU is set High  --> if the Flash is busy and SYSWR was not executed.

The Error Flag is set if there is an error. See status bits for details. The destination register contains the status bits (description below)

Status bits

 Bit DescriptionCause 
 0
 No flash No flash is fitted
 1
 No header config There is no header/user program copied on the Flash Card
 2
 SYSWR not enabled The DB/Text mode is not enable (memory allocation)
 3
 DB/Text does not exist Incorrect DB/Text number
 4
 DB/Text size is not equal DB/Text size is different, has been changed
 5
 Restored DB/Text on FlashCard were restored because an error was detected
 6
 Buffer full To much DB/Text are saved, memory is full
 7
 Already started Last SYSWR command was not finished before a new one
 was started (For PCD3 and PCD2.M5 please read FAQ 101466, too)
 *8
 Flash error No backup DB is configured on the flash or on the SRAM.
 Impossible to access the flash, the bit is updated during
 the "initializing backup" or the "copying DB to flash. (For PCD3
 and PCD2.M5 please read FAQ 101466, too)
 *9
 Flash busy Another job is working on flash
 *10
 DB size error DB size is zero. The bit is updated during the backup and restore DB
 11..15
 Not used 
 *16
 Header different The "User Program Backup Size" of the Flash is different from SRAM. The bit is updated during the "initializing backup" process.
 *17
 No flash card Flash card is not present. The bit is updated during the "initializing backup" process.
 *18
 No flash free The "User Program Backup Size" >= "User flash size". The bit is updated during the "initializing backup" process.
 19...31
 (for future use) 

































* not used by PCD2/4/M170

 

Categories

PCD3 / Mxxx

PCD2 / M5xxx

PCD2 / M1xx

PCD2 / M48x

Last update: 01.06.2015 01:08

First release: 20.08.2009 11:39

Views: 23115

The requested software / document is no longer marketed by Saia-Burgess Controls AG and without technical support. It is an older software version which can be operated only on certain now no longer commercially available products.

Download