Chapter 4: Software
Omnii HDK API Functions
56
Psion Teklogix Omnii HDK User Manual
4.7.4.21 Hdk7545_WriteEepromExtendedData
Syntax
DWORD Hdk7545_WriteEepromExtendedData( HANDLE hdk, DWORD offset, DWORD size,
const BYTE *data );
Parameters
•
hdk – [in] an open HDK handle.
•
offset – [in] 0-based offset in bytes from the start of the extended data region.
•
size – [in] the number of bytes of data to write to the extended data region.
•
data – [in] pointer to a BYTE array containing the EEPROM data to write. The array must not
be null, and must be at least 'size' bytes in length.
Description
This function writes to the extended data area of an EEPROM. The extended data region starts at
the first byte past the end of the EEPROM header (see Chapter 8: “EEPROM Specifications” for
more information).
The size of the EEPROM may vary. Drivers should use the extended data region size reported in
the Hdk7545_Eeprom structure (m_ExtendedSize) to determine how much space is available for
extended data. See
for details on reading the EEPROM header.
The format and contents of the extended data region are device-specific.
Returns
•
ERROR_SUCCESS – if successful.
•
ERROR_INVALID_HANDLE – the specified handle is invalid.
•
ERROR_INVALID_PARAMETER – one of the parameters was null/invalid, or the caller
specified an invalid offset or size.
•
ERROR_INVALID_DATA - an exception was generated.
•
Other errors are possible.
if( eeprom.m_ExtendedSize < dataSize ) {
Hdk7545_Close(&hdkHandle);
return ERROR_INVALID_DATA;
}
result = Hdk7545_ReadEepromExtendedData(hdkHandle, offset,
dataSize, data);
if( result != ERROR_SUCCESS ) {
// handle error here...
Hdk7545_Close(&hdkHandle);
return result;
}
Hdk7545_Close(&hdkHandle);
return ERROR_SUCCESS;
}
Summary of Contents for OMNii HDK XT10
Page 4: ......
Page 10: ......
Page 12: ......
Page 18: ......
Page 20: ......
Page 24: ......
Page 26: ......
Page 32: ......
Page 72: ......
Page 90: ......
Page 92: ......
Page 116: ......
Page 124: ......
Page 126: ......
Page 130: ......
Page 132: ......
Page 154: ......
Page 168: ......
Page 170: ......
Page 182: ......
Page 184: ......
Page 188: ......