Read S.M.A.R.T attributes with win32

MAORVERED MAORVERED 21 Reputation points
2020-09-26T20:11:17.07+00:00

Hello,

I have to develop a win32 project that reads all S.M.A.R.T attributes of a fixed disk.

I found the following reply and tried it.

read-smart-data-from-hdd

But not all attributes are displayed.

Is there an MS article or another sample code ?

Thank you,
Zvika

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,498 questions
0 comments No comments
{count} votes

Accepted answer
  1. Castorix31 82,751 Reputation points
    2020-09-27T11:43:46.447+00:00

    Another good source is CrystalDiskInfo Source
    with mainly AtaSmart.cpp


2 additional answers

Sort by: Most helpful
  1. Castorix31 82,751 Reputation points
    2020-09-26T20:27:25.287+00:00

    There is the old MS sample SmartApp
    I uploaded it : smartapp.zip

    0 comments No comments

  2. MAORVERED MAORVERED 21 Reputation points
    2020-09-27T07:43:31.607+00:00

    Hello,

    Thank you for your reply.

    I ran this code under admin.

    For some reason, no SMART attributes are displayed.

    The application sends DFP_GET_VERSION command and gets: GETVERSIONOUTPARAMS VersionParams

    The value of VersionParams.bIDEDeviceMap is 0x0 so nothing is displayed.

    Is it possible that there is a newer version of this application ?

    Best regards,
    Zvika