-
12. Get Device ID
In HT660/PA96x, an unique ID had been burnt into terminal, user can check it by pressing
“Func”+”9”.
The sample code for read device ID as follow,
////////////////////////////////////////////////////////////////
HWND hDeviceId = GetDlgItem(hWnd, IDC_DEVICEID);
PDEVICE_ID pDeviceID = NULL;
TCHAR outBuf[512], deviceID[200];
DWORD bytesReturned;
char platformID[64];
pDeviceID = (PDEVICE_ID)outBuf;
pDeviceID->dwSize = sizeof(outBuf);
if (KernelIoControl(IOCTL_HAL_GET_DEVICEID, NULL, 0, outBuf, sizeof(outBuf), &bytesReturned))
{
// Platform ID
memcpy((PBYTE)platformID, (PBYTE)pDe pDeviceID->dwPlatformIDOffset, pDeviceID->dwPlatformIDBytes);
// Device ID
memcpy((PBYTE)deviceID, (PBYTE)pDe pDeviceID->dwPresetIDOffset, pDeviceID->dwPresetIDBytes);
}
/////////////////////////////////////////////////////////
The code will have platformID holds Platform ID, and deviceID holds Device ID.
13. Get OEM Info
In HT660/PA96x, an OEM ID had been burnt into terminal, user can check it by pressing
“Func”+”9”.
The sample code for read OEM ID as follow,
////////////////////////////////////////////////////////////////
{
TCHAR
szBuff[500];
ZeroMemory(szBuff,
sizeof(szBuff));
SystemParametersInfo(SPI_GETOEMINFO, 500, (LPVOID)szBuff, 0);
MessageBox(szBuff);
}
/////////////////////////////////////////////////////////