12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091 |
- #ifndef FLASHDEVICE1_SOURCE
- #define FLASHDEVICE1_SOURCE
- #include "../tools/flags.h"
- #include "../tools/error.h"
- #include "../plc/plc.h"
- signed FlashDevice1 (struct plc * plc)
- {
- if (WritePIB (plc))
- {
- return (-1);
- }
- if (WriteNVM (plc))
- {
- return (-1);
- }
- if (FlashNVM (plc))
- {
- return (-1);
- }
- if (WaitForRestart (plc))
- {
- return (-1);
- }
- return (0);
- }
- #endif
|