ACPI functions

This is a discussion on ACPI functions within the Windows Programming forums, part of the Platform Specific Boards category; Hi, I'm working on some motherboard monitoring software for a motherboard whose only temperatures monitors are in an ACPI chip, ...

  1. #1
    Registered User
    Join Date
    Sep 2001
    Location
    England
    Posts
    121

    ACPI functions

    Hi, I'm working on some motherboard monitoring software for a motherboard whose only temperatures monitors are in an ACPI chip, which is blocked off by windows ACPI drivers in XP / 2000. I'd like to be able to read the chip (an Insyde H8 Keyboard / ACPI BIOS) through the windows ACPI drivers (acpiec.sys?) but apparantly there's no API for ACPI. Any suggestions on how to do this (without disabling ACPI)?

    Been a while since I posted here, thanks for any help.

  2. #2
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,691
    I would try to contact the company that created "acpiec.sys" for such an interface.

    gg

  3. #3
    Registered User
    Join Date
    Sep 2001
    Location
    England
    Posts
    121
    Unfortunately that company is microsoft, and I very much doubt they'll respond with any haste.

    I've been told by another person that attempted this before (who isnt available to help) that the EC is exposed through low level IO ports (62h and 66h), but I've never worked with hardware on this level before and I dont know where to start. I've tried using some free IO drivers to read values off the ports but I always get 255 from 62h and a seemingly random number every time (0-255) from 66h. I'm stuck.

  4. #4
    Skunkmeister Stoned_Coder's Avatar
    Join Date
    Aug 2001
    Posts
    2,572
    Free the weed!! Class B to class C is not good enough!!
    And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi

  5. #5
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,691
    You're taking on a big project to try and read from the sensor chip directly.

    I would take a look at MBM and SpeedFan as an alternative.

    MBM supports allot a chipsets and CPU information can be programmatically mined by an application you write.

    Or you can try your hand at managed C++ with the Win32_TemperatureProbe class.
    You'll have to download the WMI SDK.

    gg

  6. #6
    Registered User
    Join Date
    Sep 2001
    Location
    England
    Posts
    121
    Thanks for the links, but the problem with every other piece of MBM type software I've found, is that they expect monitors to be accessible on the southbridge, as is normal, but these monitors arent (they're on the ACPI EC).

    From the MS ACPI site it looks as if the only way I can access ACPI functionality is through a device driver, which is a possibility although something I'd like to avoid (I wouldnt want to install monitoring software that forced the installation of a dummy driver).

    I think I'm onto something directly accessing IO ports, and think I can do so by temporarily stealing control from the ACPI driver. My problem is that I dont know what to do with the returned value from the two ports, I assume certain bits represent certain registers. I've requested some documentation on the chip from insyde but I'm not optimistic they'll send me any. Are there any tools available to 'spy' on a chips registers so I can maybe determine which ones I need?

  7. #7
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,691
    So you installed MBM and it couldn't read your CPU's tempurature?

    I don't know of any tools, but you'll want to read this thread if you're gonna be reading from I/O ports.

    The ACPI website is here, and specification here.

    Good luck.

    gg

  8. #8
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Posts
    2,544
    Or you can try your hand at managed C++ with the Win32_TemperatureProbe class.

    I've tried that before, but unfortunately it always returns zero for me.

    Code:
    Set wmi = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")
    Set colProbes = wmi.ExecQuery("Select * From Win32_TemperatureProbe")
    
    MsgBox colProbes.Count
    
    For Each probe in colProbes
    	MsgBox probe.Caption & probe.CurrentReading
    Next
    I'm sorry about the vb, again, but it is easier to try something like this in vbscript to see if it will work before translating it into C/C++.

  9. #9
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,691
    Do you have the WMI SDK and .NET framework installed?

    gg

  10. #10
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Posts
    2,544
    Do you have the WMI SDK and .NET framework installed?

    No need, if you use the wmi scripting interfaces. However, wmi is unable to detect hardware sensors on my computer.

    You can run the above VBScript on any Windows 2000/XP computer with no extra installs required. If it works for anybody please post back.

    [blatant plug]With minimal effort you can use DispHelper to turn it into a C/C++ program.[/blatant plug]

    Are you sure the temperature probes are related to acpi? If you do a search on Win32_TemperatureProbe there is a lot of talk about smbios tables.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Void Functions Help
    By bethanne41 in forum C++ Programming
    Replies: 1
    Last Post: 05-09-2005, 06:30 PM
  2. Functions and Classes - What did I do wrong?
    By redmage in forum C++ Programming
    Replies: 5
    Last Post: 04-11-2005, 12:50 PM
  3. calling functions within functions
    By edd1986 in forum C Programming
    Replies: 3
    Last Post: 03-29-2005, 03:35 AM
  4. Factory Functions HOWTO
    By GuardianDevil in forum Windows Programming
    Replies: 1
    Last Post: 05-01-2004, 02:41 PM
  5. Shell functions on Win XP
    By geek@02 in forum Windows Programming
    Replies: 6
    Last Post: 04-19-2004, 06:39 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21