NAME
DesfireAPI :: Core of the writing functions
COPYRIGHT
(c) 2009 SpringCard - www.springcard.com
DESCRIPTION
Implementation of the various DESFIRE write functions.
NAME
WriteData
DESCRIPTION
Allows to write data from Standard Data File or Backup Data File
SYNOPSIS
[[sprox_desfire.dll]] SWORD SPROX_Desfire_WriteData(BYTE file_id, BYTE comm_mode, DWORD from_offset, DWORD size, const BYTE data[]); [[sprox_desfire_ex.dll]] SWORD SPROXx_Desfire_WriteData(SPROX_INSTANCE rInst, BYTE file_id, BYTE comm_mode, DWORD from_offset, DWORD size, const BYTE data[]); [[pcsc_desfire.dll]] LONG SCardDesfire_WriteData(SCARDHANDLE hCard, BYTE file_id, BYTE comm_mode, DWORD from_offset, DWORD size, const BYTE data[]);
INPUTS
BYTE file_id : File IDentifier BYTE comm_mode : file's communication settings (DF_COMM_MODE_PLAIN, DF_COMM_MODE_MACED, DF_COMM_MODE_PLAIN2 or DF_COMM_MODE_ENCIPHERED)(see chapter 3.2 of datasheet of mifare DesFire MF3ICD40 for more information) DWORD from_offset : starting position for the write operation in bytes DWORD size : size of the buffer in bytes BYTE data[] : buffer to write to the card
RETURNS
DF_OPERATION_OK : success, data has been written Other code if internal or communication error has occured.
SEE ALSO
WriteData2
NAME
WriteData2
DESCRIPTION
Allows to write data from Standard Data File or Backup Data File
SYNOPSIS
[[sprox_desfire.dll]] SWORD SPROX_Desfire_WriteData2(BYTE file_id, DWORD from_offset, DWORD size, const BYTE data[]); [[sprox_desfire_ex.dll]] SWORD SPROXx_Desfire_WriteData2(SPROX_INSTANCE rInst, BYTE file_id, DWORD from_offset, DWORD size, const BYTE data[]); [[pcsc_desfire.dll]] LONG SCardDesfire_WriteData2(SCARDHANDLE hCard, BYTE file_id, DWORD from_offset, DWORD size, const BYTE data[]);
INPUTS
BYTE file_id : File IDentifier DWORD from_offset : starting position for the write operation in bytes DWORD size : size of the buffer in bytes BYTE data[] : buffer to write to the card
RETURNS
DF_OPERATION_OK : success, data has been written Other code if internal or communication error has occured.
SEE ALSO
WriteData