Windows System Software -- Consulting, Training, Development -- Unique Expertise, Guaranteed Results

Before Posting...
Please check out the Community Guidelines in the Announcements and Administration Category.

GPIO test

tatuotatuo Member Posts: 17

I tried to install the sample driver of simdevice below at GPIO of Windows-driver-samples-master without any modification.
The system crashed.
The project name: sim.sln
Used command is: devcon install simdevice.inf ACPI\TEST0003
Can anyone tell me how to test it?

Thanks in advance.

Comments

  • Tim_RobertsTim_Roberts Member - All Emails Posts: 12,969
    via Email
    tatuo wrote:
    > I tried to install the sample driver of simdevice below at GPIO of Windows-driver-samples-master without any modification.
    > The system crashed.
    > ...
    > Used command is: devcon install simdevice.inf ACPI\TEST0003

    And that's why it crashed.  "devcon install" is among the most dangerous
    commands in the world of Windows, because it does not actually do you
    think it does.  It should have a different name. What that command did
    is create a fake device called ACPI\TEST0003, and then cause your driver
    to be loaded for it. Because it is a fake device, it isn't backed by any
    hardware, so your driver was not given any resources.  Kaboom.


    > Can anyone tell me how to test it?

    Unless you control the BIOS for your computer, you can't really test
    it.  The doc for that samples tries to say that, but obliquely.  It's an
    example, demonstrating the concepts.  Did you notice the
    GpioSampleKMDF.asl file in the sample?  That file is trying to show you
    how you could modify the DSDT in your BIOS to expose GPIO pins to a
    device called TEST0003.  Assuming you had put that in your BIOS (which
    you probably can't do), then there would automatically be an
    ACPI\TEST0003 device that your driver could handle, and that driver
    would be given the resources described in the ASL file.

    If your computer has GPIO pins, there is probably a way to access them
    without modifying the BIOS DSDT.  Are you working with an IoT platform?

    Tim Roberts, [email protected]
    Providenza & Boekelheide, Inc.

  • tatuotatuo Member Posts: 17

    Dear Tim

    Thank you very much for your help.
    I understand.
    What a fool thing I did! I think There is no GPIO device in my computer.

    Thanks again.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Upcoming OSR Seminars
Developing Minifilters 29 July 2019 OSR Seminar Space
Writing WDF Drivers 23 Sept 2019 OSR Seminar Space
Kernel Debugging 21 Oct 2019 OSR Seminar Space
Internals & Software Drivers 18 Nov 2019 Dulles, VA