How To Program ACPI Using Pure NASM Assembly ?
Thanks
ACPI Programming
Re: ACPI Programming
By typing code in a file and compiling it. If it even has to work, look at the manuals.
- Schol-R-LEA
- Member
- Posts: 1925
- Joined: Fri Oct 27, 2006 9:42 am
- Location: Athens, GA, USA
Re: ACPI Programming
@RUSSIANEMPIRE: Before you go any further, be aware that with the sort of questions you've asked in the the three posts you have made today, you are unlikely to get a more constructive answer than Roflo's, and rightly so.
If you want us to simply provide you with code, well, we can't - not won't, but can't. We would need to know more about what you have already done with you OS in order to give you working code. While the wiki does provide many code examples, that is all they are; they are guides, not live code, and even if you can make the snippets work as is, they would still be the equivalent of cutting and welding a Ford muffler to fit on a Mercedes.
All other considerations aside, you simply haven't given us enough information about what you are trying to accomplish for us to do say much more than RTFW. While it is true that that specific page is rather sparse, the pages it links to give a good deal more detail, and the one key piece of information - that in order to switch to ACPI mode, you need to tickle an I/O bus port at the port address listed in the Fixed ACPI Description Table entry for the SMI command - is explained with a code example showing how to do it. Yes, the code sample is in GNU C, but the function in question is a simple wrapper around the OUT instruction. I will grant that you would need to know that for the code snippet to make sense to you, but the information about the outb() function is available on the wiki as well.
Beyond that, the wiki can only give so much more information anyway, so you would do better to read the relevant version of the ACPI standard and then ask for help for any parts you are having problems with.
I would recommend re-reading the Basic Information section of the wiki, especially the page on How To Ask Questions. Otherwise, you will find your posting here to be an exercise in frustration for both you and us, something I am sure you'd rather avoid.
If you want us to simply provide you with code, well, we can't - not won't, but can't. We would need to know more about what you have already done with you OS in order to give you working code. While the wiki does provide many code examples, that is all they are; they are guides, not live code, and even if you can make the snippets work as is, they would still be the equivalent of cutting and welding a Ford muffler to fit on a Mercedes.
All other considerations aside, you simply haven't given us enough information about what you are trying to accomplish for us to do say much more than RTFW. While it is true that that specific page is rather sparse, the pages it links to give a good deal more detail, and the one key piece of information - that in order to switch to ACPI mode, you need to tickle an I/O bus port at the port address listed in the Fixed ACPI Description Table entry for the SMI command - is explained with a code example showing how to do it. Yes, the code sample is in GNU C, but the function in question is a simple wrapper around the OUT instruction. I will grant that you would need to know that for the code snippet to make sense to you, but the information about the outb() function is available on the wiki as well.
Beyond that, the wiki can only give so much more information anyway, so you would do better to read the relevant version of the ACPI standard and then ask for help for any parts you are having problems with.
I would recommend re-reading the Basic Information section of the wiki, especially the page on How To Ask Questions. Otherwise, you will find your posting here to be an exercise in frustration for both you and us, something I am sure you'd rather avoid.
Rev. First Speaker Schol-R-LEA;2 LCF ELF JAM POEE KoR KCO PPWMTF
Ordo OS Project
Lisp programmers tend to seem very odd to outsiders, just like anyone else who has had a religious experience they can't quite explain to others.
Ordo OS Project
Lisp programmers tend to seem very odd to outsiders, just like anyone else who has had a religious experience they can't quite explain to others.