Click here to Skip to main content
Licence 
First Posted 6 Dec 2006
Views 111,024
Downloads 3,435
Bookmarked 62 times

Hard drive information using S.M.A.R.T.

By | 25 May 2007 | Article
Retrieving Hard drive information using S.M.A.R.T.

Sample Image - SMARTIMAGE.jpg

Introduction

This is very simple program which communicates with the Hard drive to get the information using S.M.A.R.T. available within the hard drive.

The core part is to prepare the command structure and pass it to the device driver which communicates with the hard drive. It uses the DeviceIoControl function. For eg: bRet=DeviceIoControl(hDevice,SMART_SEND_DRIVE_COMMAND,&stCIP,sizeof(stCIP),&stCOP,sizeof(stCOP),&dwRet,NULL);

Don't forget to include the "DDKInclude" folder in the workspace to your VC's include folder before compiling. This sample is only intended for beginners. Most of the information for S.M.A.R.T. is available in the net.

Also the information for each id is stored in an .ini file. You can see that in the Debug / Release folder.

Double click on any of the item in the list box to get more information about it. For e.g., xx sector count

Please contact me for any doubts and i will be happy to answer to your questions

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

Saneesh

Software Developer (Senior)

United States United States

Member

I am from the beautiful sea side town called Kochi ( cochin), Kerala, South India.

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board. (secure sign-in)
 
Search this forum  
 FAQ
    Noise  Layout  Per page   
  Refresh
BugRegarding RAW and Threshold Value PinmemberNidheesh V N18:49 16 May '12  
GeneralRe: Regarding RAW and Threshold Value PinmemberSaneesh4:34 17 May '12  
QuestionProject settings Pinmemberjlkdaslkfjd0:24 31 Oct '11  
AnswerRe: Project settings PinmemberSaneesh4:34 17 May '12  
QuestionCan not compile in VC6.0 [modified] Pinmemberweishoumeng17:06 24 Aug '10  
AnswerRe: Can not compile in VC6.0 PinmemberSaneesh17:21 30 Aug '10  
GeneralBlank screen when click on 'Read SMART Values' Button PinmemberNicholas Amh20:32 20 Apr '10  
GeneralRe: Blank screen when click on 'Read SMART Values' Button PinmemberSaneesh5:20 21 Apr '10  
GeneralRe: Blank screen when click on 'Read SMART Values' Button Pinmemberarun0023:22 19 Feb '11  
GeneralC++ win32 console aplication Pinmembermadmat8713:57 14 Nov '09  
GeneralRe: C++ win32 console aplication PinmemberSaneesh15:56 18 Nov '09  
QuestionUse this Code for C# PinmemberMasterChef9:31 23 Oct '09  
AnswerRe: Use this Code for C# PinmemberSaneesh6:35 24 Oct '09  
QuestionRe: Use this Code for C# PinmemberMasterChef6:10 25 Oct '09  
QuestionHow can read the S.M.A.R.T information with C# PinmemberAlexXie3:37 23 Aug '09  
AnswerRe: How can read the S.M.A.R.T information with C# PinmemberSaneesh12:22 24 Aug '09  
GeneralRe: How can read the S.M.A.R.T information with C# PinmemberAlexXie3:48 25 Aug '09  
GeneralSupport for SCSI HDD PinmemberDP3216:23 6 Apr '09  
GeneralRe: Support for SCSI HDD PinmemberSaneesh6:15 7 Apr '09  
GeneralRe: Support for SCSI HDD Pinmembersukhas1918:08 8 Apr '09  
GeneralRe: Support for SCSI HDD Pinmembersukhas1921:00 19 Apr '09  
GeneralRe: Support for SCSI HDD PinmemberSaneesh4:12 21 Apr '09  
GeneralRe: Support for SCSI HDD PinmemberSaneesh4:13 21 Apr '09  
GeneralThresholds PinmemberKenshin2k22:18 29 Dec '08  
GeneralRe: Thresholds PinmemberSaneesh3:42 30 Dec '08  

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Mobile
Web04 | 2.5.120528.1 | Last Updated 25 May 2007
Article Copyright 2006 by Saneesh
Everything else Copyright © CodeProject, 1999-2012
Terms of Use
Layout: fixed | fluid