Publication LOGIX-AP007B-EN-P - January 2007
CompactFlash Commands
17
•
The checksums are verified and the data in data_to_write and data_read
are compared to make sure they are equal.
•
The file is closed.
•
Error handling is performed, if needed.
Set Up the Write Command
To set up the write command, you need to set the bit execute_CF_Write_Data.
The application code handles resetting this bit.
1.
Define a file name including a file extension, for example, testfile1.dat.
2.
Enter the number of bytes you want to write to the file.
3.
Move the data to be written in the CF_Data_Working UDT into the
Data array.
We recommended that you clear the data array before moving the data
into the array. This will clear out any data from previous read or write
commands.
Refer to Chapter 4, Example Application for complete instructions.
TIP
If the checksums are not calculated, compared, and
parsed, the file is closed and the write sequence is
restarted from the beginning.
The application will attempt to write a file four times.
After the fourth failure, a checksum error is set.
Summary of Contents for controllogix 1756-L61
Page 6: ...Publication LOGIX AP007B EN P January 2007 6 Notes...
Page 10: ...Publication LOGIX AP007B EN P January 2007 10 CompactFlash Card Enhancements Overview Notes...
Page 42: ...Publication LOGIX AP007B EN P January 2007 42 Format a CompactFlash Card Notes...
Page 48: ...Publication LOGIX AP007B EN P January 2007 48 Troubleshoot the CompactFlash File System Notes...
Page 55: ......