Contribute
Register

[Guide] Asus ZenBook UX303LA (Broadwell Edition)

Joined
Jul 25, 2012
Messages
35
Motherboard
GA-Z77X-UD5H/ZenBook UX303LA
CPU
i5 3570K/i5-5200U
Graphics
GTX770/HD5500
Mac
Classic Mac
Mobile Phone
Android
Hello! So I'm going to make a guide how to make a pretty much perfect hackintosh out of the UX303LA using El Capitan. Let's start with the specs on it:

Asus ZenBook UX303LA:

  • Intel Core i5 Broadwell 5200U
  • Intel Graphics HD5500 (no dedicated graphics card, if you want that check out the UX303LN)
  • Audio Codec: Conexant CX20751/2
  • 1080p matte screen
  • 3x USB3.0 (Intel)
  • 1x SD Card reader
  • WebCam
  • Automatic Light Sensor (ALS)
  • 1x Full-size HDMI 2.0
  • 1x Mini DisplayPort
  • Backlit Keyboard
  • 3.5mm jack
  • FocalTech Trackpad
  • Intel 9 Chipset (Wildcat Point-LP SATA Controller etc)
  • Extra mSATA port for a half-size mSATA SSD inside
  • Comes with 8GB of RAM, and is upgradable.
  • Comes with two accessories: A miniDP to VGA converter, and a USB Ethernet dongle.
  • Intel Wireless-AC 7265 (M.2 NGFF card)
All in all an extremely nice ultrabook, but what works in OS X? All of the above. You read that right, pretty much everything. The Webcam, Ambient Light Sensor, SD Card reader, both HDMI (inc. HDMI Audio) and DisplayPort (even VGA when using the DP converter it comes with), the USB Ethernet works, the audio, the trackpad work flawlessly and even has a lot of settings you can play with like gestures in OS X, the backlit keyboard works with sixteen light settings, it's almost a perfect Hackintosh.

The only non-working part on this computer would be the Intel Wireless which needs to be swapped out for a DW-1560 or an another OS X compatible M.2 NGFF card, personally I purchased the DW-1560. That's the only thing that doesn't work, and once you get it working I'd say it's a perfect hackintosh.

For this guide you will need:

  1. At least 1x USB stick (preferably two)
  2. Another OS X machine (if you don't have another, loan a friend's Mac or use a VM or something)
  3. Reading skills
  4. A few hours to spare

I'd like to thank jhawk and RehabMan for their work on the Asus ZenBook UX305 (Core M ultrabook) which has almost identical procedures and DSDT/SSDT edits as they are extremely similar with the big exception being the processor.

The UX303LN might work with this guide, however you'd need further DSDT edits to disable the optimus card in order for the UX303LN to work. The UX303LA does not have a optimus card.

The Hardware:

The Intel network card will not work, thus you will not get WiFi on this device unless you replace the Intel card with another one. This one has a M.2 NGFF slot and the DW-1560 is a good replacement that also gives you 802.11AC. However the DW-1560 is not easy to get your hands on, and is usually really expensive (I had to pay about $100 for mine). These NGFF cards are getting more used however, so they'll most likely go down in price.

Replacing the card is extremely easy. All you need is a torx screwdriver and a phillips screwdriver. There are two phillips screws beneath two of the upper rubber feet on the backplate, so you need to temporarily pop those off (they're glued on and break easily, so use a soft touch!). Other than that it should be really easy, the network card is on the upper right corner when the laptop is flipped with the backplate upwards.
If you do get a DW-1560, do not screw it all the way down onto the motherboard. It'll create a static white noise while the card is in use, if you either put something between the motherboard and the card, or don't screw it all the way down it'll be fine. Remember to test if you've done it correctly and don't get the white noise before putting the backplate back on.

There's also a mSATA port for a half-mini SSD on the motherboard that you can use if you have a mSATA half-mini SSD laying around or want more space. The SSD that the computer comes with (a Kingston SSD) is easily swappable, but requires you to get the battery out of the way.

There's also one RAM slot there that is interchangeable and a soldered on 4GB of RAM, so if you need an additional 8GB for a total of 12GB on it, you can add that.

The DSDT:

First you need to extract the DSDT and SSDTs. These are vital parts to getting this computer working, you will not be able to install OS X without them.

Boot Ubuntu or some other type of GNU/Linux distribution. You can do this on Windows as well, but in this guide I'll focus on how to do it from GNU/Linux. Now open a terminal and write:

Code:
mkdir ASCPITables
sudo cp /sys/firmware/acpi/tables/* ASCPITables/
This will copy a lot of files into the ASCPITables folder located in the "Home" folder. Copy that ASCPITables folder to another USB formatted as FAT32 or something that can be read and written from both GNU/Linux and OS X. If you're having problems with this, check RehabMan's DSDT patching guide.

After this is done you can turn off the computer and bring your ASCPITables folder to a Mac.

Download MacIASL from Sourceforge on the Mac, you'll need it. Also download iasl from here and extract it.

Now copy the ASCPITables folder to the Mac, and copy it over again with another name as a backup in case you need a clean workspace later on.

Delete all files inside ASCPITables that do not contain "SSDT" or "DSDT". I'd like to remind you that inside the "Dynamic" folder there are three SSDTs that you might want. So copy these out of the Dynamic folder and into the root of the ASCPITables folder. Once that is done you need to rename all SSDTs (first SSDT.aml, then SSDT-1.aml, SSDT-2.aml, SSDT-3.aml and so forth) and DSDT so that they all end with the extension ".aml".

You can use the following bash script to add ".aml" to all the files automatically, or if you don't know how to use bash scripts you can skip it and just add ".aml" to all of them manually if you want.

Code:
#!/bin/bash
# This script renames all files inside ASCPITables to end with .aml.
# You don't need this if you've added .aml to all the files manually.
for f in ASCPITables/*; do 
mv "$f" "$f.aml"
done
After all the files end with .aml, copy the iasl executable you downloaded into that folder. You also need a text file called "refs.txt" with this information inside it:

Code:
External (_SB_.PCI0.PEG0.PEGP.SGPO, MethodObj, 2)
External (_SB_.PCI0.LPCB.H_EC.ECWT, MethodObj, 2)
External (_SB_.PCI0.LPCB.H_EC.ECRD, MethodObj, 1)
The step above is not optional, SSDT-5 and SSDT-8 will not compile properly without it and without SSDT-5 and 8 the SATA controller doesn't work.

After you've added the refs.txt file in ASCPITables, open a terminal and change directory to the ASCPITables folder and write this:

Code:
./iasl -da -dl -fe refs.txt *.aml
It will now spew out a bunch of information and you'll see that a lot of new files have been added in the ASCPITables folder that ends with .dsl.

Write this in the terminal:

Code:
cd path/to/the/ACPITables/Folder/
mkdir dsl_files
mv *.dsl dsl_files/
The .dsl files are now moved into a new folder named dsl_files. You will only work with the DSL files, do not open the .aml files in MacIASL. If you need to patch something you do that through the .dsl files and none other.

You are now ready to go on to the next step, patching the DSDT and SSDTs.

Patching the DSDT and SSDTs:

Patching the DSDT and SSDT is not too hard. It might seem intimidating, but it really isn't very hard.

First, download the "Patches.zip" in this post and extract it as a "Patches" folder on the desktop.

Open up MaciASL. You'll most likely be greeted with a lot of ACPI code. Press the MaciASL text in the menu bar and go to preferences. Go to iASL and make sure it is sat to ASCPI 5.0.

Now go to the "Sources" tab and add the following repositories:

http://pjalm.com/repos/intel9/
http://raw.github.com/RehabMan/Laptop-DSDT-Patch/master
file:///Users/[USERNAME NEEDS TO GO HERE]/Desktop/Patches

You can name the repositories whatever you want, it is not important. Personally I'll call them Pjalm Intel 9, RehabMan's repo and local patches.

After that is done and no error is encountered, quit MaciASL and open the file "DSDT.dsl" inside MaciASL from the dsl_files folder you created.

Now, at the top of the MaciASL screen you'll see a "Patch" button, click that and a lot of stuff will appear on the left hand side.

To patch the DSDT with a patch, click it, wait until the text appears and press "Apply" at the bottom. If it can't be applied the "Apply" button will be grey.

The very first patch you need to do is "Remove _DSM methods". This one is located in RehabMan's repo.

After you've applied Remove _DSM methods, these are the rest of the patches you should apply in the following order:

Pjalm Intel 9:

  • Generic Fixes
  • LPC
  • SMBus
RehabMan's Repo:

  • Audio Layout 12
  • Fix _WAK Arg0 v2
  • HPET Fix
  • IRQ Fix
  • RTC Fix
  • Fix PNOT/PPNT
  • Add IMEI
  • Fix ADGB Error
  • Brightness fix Haswell
  • Asus_N55SL/VivoBook
  • Rename GFX0 to IGPU
  • Rename B0D3 to HDAU
Local Patches:

  • ALS_Patch
  • BrightnessKeys
  • KeyboardBacklight_16Levels_Patch_(Haswell/Ivy)
  • LID
  • DTGP
  • BCM94352 (ONLY IF USING DW-1560)
Now close the patching window and go back to the wall of code. Press compile and you should see a little compiler summary window pop up with loads of warnings, optimizations and 3 errors. You need to fix these errors by pressing them to see the issue.

One of them is a line that says something with SAT0. Manually edit "SAT0" to "SATA" since all the SAT0s have been renamed to SATA by "Generic Fixes" so it can't find any SAT0 objects. Press compile and two of the errors will be gone.

The next error will say there is an error on a line that says ^^_DOS(Arg0). Above that line it says "//External(^^...". Remove the two "//" comment slashes on that line and try to compile again. It should now compile without any issue and say 0 errors (still a lot of warnings, but nevermind them).

You might get some errors regarding a line with B0D3 involved. Rename the B0D3 in those lines to HDAU and it'll compile.

You're not done yet however. It might compile now, but there's one last thing you need to do. Search after "layout-id" and you'll see the line:
"layout-id", Buffer() { 12, 0x00, 0x00, 0x00 },

Change "12" to 0x03.

Next up you need to go to all the SSDT files:

Open the SSDT dsl files one by one in MaciASL and apply the patches "Generic Fixes" from Pjalm Intel 9, "Rename GFX0 to IGPU" and Rename B0D3 to HDAU if they are possible to use. If they cannot be used the "Apply" button will simply be grey and you can skip it.

You'll have a few compiler errors on some of these SSDTs:

SSDT-1 - SAT0 issue again, rename SAT0 to SATA.
SSDT-3 - Needs to be patched with Remove _PSS placeholders from RehabMan's repo.
SSDT-5 AND SSDT-8 - You need to copy and paste the first three "External" lines at the top of the massive list of lines that start with "External" to the bottom of the list. Just cut and paste. They look like "_SB_.PCI0.LPCB.H_EC.ECRD" and has a comment at the end says "1 arguments" or "2 arguments". Remember - ONLY the first three.

Remember to patch all of them with "Generic Fixes" from Pjalm and "Rename GFX0 to IGPU" if the SSDT can have it applied. Not all of them can apply them, but if it can be applied, do apply it.

After you've done so on all the SSDTs you're done! Now create a new folder somewhere, and open each .DSL file one by one and "Save As". You need to save it as ACPI Machine Language Binary. Once you're done you can check the folder and see if the DSDT and every single SSDT (should be 1 through 10 + the normal SSDT.aml without a number) is there and ends all of them ends with .aml.

Congratulations, you just patched the DSDT!

Preparing the USB:

I'm not going to write up how to install El Capitan Beta to the USB. You can do this perfectly by following FireWolf's guide: http://www.firewolf.science/2015/06/installation-notes-install-os-x-el-capitan-10-11-on-hackintosh/

Either use method 2 or 3. Ignore the last line about rebooting to Clover. As far as I know only method 3 works in the El Capitan Beta so far, this might be unnecessary in later versions of El Capitan Beta or in the GM where method 2 would be the easiest and fastest way.

Install Clover onto the USB:

Download Clover from http://sourceforge.net/projects/cloverefiboot/

Start the installer, remember to change the install location to your USB. Press "Customize" and add the following options: Pictures

Install Clover to the USB.

Now you need to add the kexts required for it to boot and modify the config file to make it boot properly. Kexts can with Clover 3259 and newer be injected like usual in El Capitan by putting the kexts in /Volumes/EFI/EFI/CLOVER/kexts/10.11

If the EFI partition doesn't appear in the Finder after installing it, try mounting it using Clover Configurator or mounting it manually through the terminal.

Required kexts:

  • FakeSMC - Required no matter what. You cannot skip this.
  • ACPIBatteryManager - For proper battery information
  • ApplePS2SMartTouchPad (also known as the Elan Touchpad driver) - Touchpad and keyboard driver.
  • DummyHDA - For audio (if patching AppleHDA through Clover. Do not put this in Clover's EFI partition as it won't work there)

Recommended kexts:


Please download all of them manually to ensure you got the newest version of the kext instead of relying on pre-packaged kexts from a zip you found somewhere, and put them in the kexts folder on the EFI partition. You do not need to put DummyHDA there, it needs to be in /S/L/E or /L/E.

Also put your DSDT and all the SSDTs into /Volumes/EFI/EFI/Clover/ACPI/patched

After you've put all the kexts you need into the 10.11 folder on the EFI partition you need to configure Clover to satisfy your needs. I have included mine as a template, but do yourself a favour and create one yourself instead of blatantly using mine. You NEED to edit the SMBios options manually. A good SMBios for this computer is a MacBookAir7,2 or 7,1 which has a broadwell inside that is pretty similar. I haven't found any automatic SMBios generator for the MacBookAir7,x, so here is an example of crucial information in the MacBookAir7,2 SMBIOS:

Board-Id: Mac-937CB26E2E02BB01
ProductName: MacBookAir7,2
Serial: XXXXXXXXGLCP (or another MBA early 2015 serial. You can find serial endings at the bottom of Pike R Alpha's list)

There are more information in my Clover config if you want more accurate information like ChassisType, BiosVersion and BiosReleaseDate, though that is not as important as the information above.

Also make sure you don't add the KextsToPatch you don't need to the config file. If the config isn't correct you might get a kmem panic at the beginning (SMBios related), or a panic of some sort, so do make sure you configure it correctly.

After you've configured Clover it's time to start the installation process.

Installing OS X:

Installing OS X should be pretty straight forward, if you haven't changed anything yet and are starting from a clean Windows 10 build you might see that you cannot enter the UEFI options or boot menu. Check your settings in Windows if that is the case, because Windows has a "fast boot" option that disables the UEFI/BIOS settings.

Make sure your UEFI/BIOS settings has CSM enabled, otherwise your screen will glitch. You will need to turn off Secure Boot to allow for that. Also change the graphics allocated RAM to 128MB from the settings there. Luckily Asus gives us the option to change this straight from the menu, while many other computer manufacturers requires you to boot into a EFI shell and change it manually there (and some can't even do that).

If you arrive in the OS X installer and cannot find the SATA disk (this was a huge problem for me) you haven't patched the SSDTs or don't load the SSDTs correctly as the chipset controller info is in the SSDT, so it is crucial that you add patched SSDTs to Clover.

Install OS X as usual by cleaning the disk in the Disk Utility option at the top and all that. You probably know how to do this already, it's standard procedure.

Post Install:

After OS X has installed it should work as intended, so now you need to install Clover to the SSD and copy the EFI folder from the USB to the SSD so that it boots properly without the need to use a USB. You also need to install "DummyHDA.kext" to /Library/Extensions or /System/Library/Extensions.

You also need to create a SSDT for power management using ssdtPRgen. Pike R Alpha has updated it to work with the broadwell processors, so it should give you a nice SSDT that gives you proper power management. Use AppleIntelInfo version 1.2 again by Pike R Alpha to see if you get many C and P states and that PM works as intended. You can download ssdtPRGen from Piker's Github and put the generated SSDT.aml (and only that one) from ~/Library/ssdtPRGen/SSDT.aml to your EFI's Clover/ACPI/Patched folder. Make sure they are correctly named starting from SSDT.aml (the one you generated just now), SSDT-1.aml, SSDT-2.aml, SSDT-3.aml up to whatever you have. You might probably need to increment the number on every SSDT by one to have the generated SSDT fit into the line. So what was previously SSDT.aml in the EFI folder should now be SSDT-1, and what was previously known as SSDT-1 should now be SSDT-2. Remember that it needs to be "SSDT.aml, SSDT-1.aml, SSDT-2.aml, SSDT-3.aml..." without any gaps.

Configuring some of the kexts is important. Your screen's brightness level might arbitrarily go up and down, this is due to the ambient light sensor not being configured correctly. This is controlled from the AsusFNBKeys kext so check its Contents/info.plist for settings, personally I just turned it off since I found it annoying.

The keyboard and trackpad gestures are controlled through the Elan Touchpad. Read up on the documentation and edit it to your liking. Remember that you might need to go into System Settings -> Trackpad -> And re-set all the settings there to make them work correctly, this will fix the scroll speed and more.

Now you have the basics and a well working hackintosh, you might need to do some small extra tweaking yourself that I won't go through here since they are standard procedure (like fixing the identification problem with the App Store), stuff like that is very well documented so doing a Google search will enable you to fix those yourself really easily.

Good luck!
 

Attachments

Joined
Nov 25, 2014
Messages
4
Mac
Classic Mac
Mobile Phone
I Have the exact notebook, can you please send me your SSDT and DSDT Files? :)
 
Joined
Dec 8, 2012
Messages
11
Motherboard
UX303LA-R4446H
CPU
Intel Core I5-5200U
Graphics
Intel HD 5500
Mac
Classic Mac
Mobile Phone
I Have the exact notebook, can you please send me your SSDT and DSDT Files? :)
+1, also with the original DSDT & SSDTs files if possible.

I'm unable to compile the patched DSDT from MacIASL (0 errors, 94 warnings, 152 remarks, 210 optimizations). Bad generated DSDT & SSDTs files? I've made mine from CLOVER (F4 key at boot).
I have the same model with the DW-1560 wifi card.


About the guide, it seems that the "[Asus] BrightnessKeys" local patch is missing (no file associated in Patches.zip). But the line is showing up in the Patches section of MacIASL, but without any code.

Here is the code:
Code:
# Patches for getting Asus Fn brightness keys to work with my driver AsusNBFnKeys in newer notebooks(use this only if its not working with my driver)

# Replacing method _Q0E for Brightness F5 key to work
# by removing the code which prevents
into Method label _Q0E replace_content begin
                
                If (ATKP)\n
                {\n
                   ^^^^ATKD.IANE (0x20)\n
                }
            
 end;


# Replacing method _Q0F for Brightness F6 key to work
# by removing the code which prevents 
into Method label _Q0F replace_content begin
               
                If (ATKP)\n
                {\n
                    ^^^^ATKD.IANE (0x10)\n
                }  
 end;
Nevertheless it's a great guide, thank you for that Machanical ! :)
 

RehabMan

Moderator
Joined
May 3, 2012
Messages
191,123
Motherboard
Intel DH67BL
CPU
Core i7-2600K
Graphics
Intel HD 3000
Mac
MacBook Air
Mobile Phone
iOS
+1, also with the original DSDT & SSDTs files if possible.

I'm unable to compile the patched DSDT from MacIASL (0 errors,
Why? Zero errors indicates success.
 
Joined
Dec 8, 2012
Messages
11
Motherboard
UX303LA-R4446H
CPU
Intel Core I5-5200U
Graphics
Intel HD 5500
Mac
Classic Mac
Mobile Phone
Why? Zero errors indicates success.
Yes, this is what I thought. But I was so dumb thinking that just clicking on the Compile button was the only action I needed to obtain the Save file popup...
So, my bad, I've just understood how to use your software: click on the Compile button, and after go in the File menu and click on Save as, and switching in the ACPI Machine Language binary format...not waiting for a damn miracle. :D
...And I've just read the end of the SSDT/DSDT part of this guide... Well, I clearly wasn't well awake... Sorry.
 

RehabMan

Moderator
Joined
May 3, 2012
Messages
191,123
Motherboard
Intel DH67BL
CPU
Core i7-2600K
Graphics
Intel HD 3000
Mac
MacBook Air
Mobile Phone
iOS
Yes, this is what I thought. But I was so dumb thinking that just clicking on the Compile button was the only action I needed to obtain the Save file popup...
So, my bad, I've just understood how to use your software: click on the Compile button, and after go in the File menu and click on Save as, and switching in the ACPI Machine Language binary format...not waiting for a damn miracle. :D
...And I've just read the end of the SSDT/DSDT part of this guide... Well, I clearly wasn't well awake... Sorry.
Yes, Compile is just for checking for errors.

Save As needed to save as AML.
 
Joined
Jul 25, 2012
Messages
35
Motherboard
GA-Z77X-UD5H/ZenBook UX303LA
CPU
i5 3570K/i5-5200U
Graphics
GTX770/HD5500
Mac
Classic Mac
Mobile Phone
Android
About the guide, it seems that the "[Asus] BrightnessKeys" local patch is missing (no file associated in Patches.zip). But the line is showing up in the Patches section of MacIASL, but without any code.
Check if it is written correctly in the .maciasl file that are in the patches folder. It needs to have the same name, maybe I've mispelled it.

I'll cave in and give them out if anyone needs them. Here you go.

However these pre-patched DSDT + SSDTs will ONLY work on a laptop with a DW-1560 because I've patched it with that patch. If you don't have a DW-1560 they will create a KP.

Please do attempt to patch your own DSDT and SSDTs if possible. The guide should be really elaborate. Only use these pre-patched ones if you absolutely can't do it for some reason.

Unfortunately the DSLs are not included here, I'll probably add those later because I don't have them at hand right now.
 

Attachments

RehabMan

Moderator
Joined
May 3, 2012
Messages
191,123
Motherboard
Intel DH67BL
CPU
Core i7-2600K
Graphics
Intel HD 3000
Mac
MacBook Air
Mobile Phone
iOS
Check if it is written correctly in the .maciasl file that are in the patches folder. It needs to have the same name, maybe I've mispelled it.
Not misspelled. fnKeyPatch.txt is missing.
 
Joined
Jan 31, 2014
Messages
9
Mac
Classic Mac
Mobile Phone
@Machanical
How did you manage to replace the Intel Wireless-AC 7265 ? Did you find any fitting adaptator ?
 
Joined
Dec 8, 2012
Messages
11
Motherboard
UX303LA-R4446H
CPU
Intel Core I5-5200U
Graphics
Intel HD 5500
Mac
Classic Mac
Mobile Phone
Check if it is written correctly in the .maciasl file that are in the patches folder. It needs to have the same name, maybe I've mispelled it.

I'll cave in and give them out if anyone needs them. Here you go.

However these pre-patched DSDT + SSDTs will ONLY work on a laptop with a DW-1560 because I've patched it with that patch. If you don't have a DW-1560 they will create a KP.

Please do attempt to patch your own DSDT and SSDTs if possible. The guide should be really elaborate. Only use these pre-patched ones if you absolutely can't do it for some reason.

Unfortunately the DSLs are not included here, I'll probably add those later because I don't have them at hand right now.
Thank you very much. :)
You were right about what you said: for me it's not working. SSDT generated can be different from a computer to another, despite it's almost the same model (mine is exactly UX303LA-R4446H).
But I have successfully patched by myself mines (I think).
 
Top