Contribute
Register

[GUIDE] General Framebuffer Patching Guide (HDMI Black Screen Problem)

Joined
Oct 3, 2013
Messages
67
Motherboard
HP Probook 450 G6-Clover
CPU
i7-8565U
Graphics
UHD 620, 1920x1080
Mobile Phone
iOS
@CaseySJ, thanks for the guide! :)

I just read the entire thread (all 62 pages!), in order to inform my self of all the details before attempting this. I have a few rigs I'm upgrading and would like to get IGPU working.

For the purpose of this post, I'm working with the following hardware: Gigabyte H370 Aorus Gaming 3 WIFI (with the WIFI module removed), Intel i5-8400, and Acer ET321-HQU (2560X1440) monitor (has HDMI, DP and DVI). I also have a Dell U2415 (1920X1200, DP and HDMI) and a Gateway 2703 (1920X1080, DVI and VGA) that I can also test on if need be. All tests will be done with direct cables, no adapters/converters.
Software: Mojave 14.4, Hackintool 2.4.4, Clover 4920, latest LILU, AppleALC, WhateverGreen, FakeSMC, USBInjectAll (with proper custom USB SSDT in place) and Ethernet kext in L/E.
I'll also be doing this procedure on 2 other Gigabyte boards, and will post working configurations for all 3 as soon as they are confirmed working; all boards running latest Gigabyte BIOS.

But for now, due to the methodical testing that must be performed, my goal is to know what is the minimal amount of things I need to include in the patch to successfully test ports (what boxes to check/uncheck), without adding unnecessary/extra variables that may interphere or mess things up. So my questions (before I get started) are as follows:

1. Do I need to do anything with the connector flags? By default, when openning Hackintool, some of the flags are checked. Should they all be unchecked?

2. I'm assuming since Mojave 14.4 has support for CFL graphics that I don't need to use device ID, just the recommended 3E9B0007 ig-platform-id? (read a post a few pages back that seems to imply this)

3. Since my UEFI allows me to change video mem sizes and such, do I need the VRAM boxes checked when patching? Or just connectors and graphic device?

4. Do I need HDMI20 checked (is it for 4k only, or would 1440p (2k?) also require it)?

5. Do I do anything with the pipes number column? Only mention of it I read was setting them all to 18 to fix a certain issue; is leaving them at their default for now also OK? Right now with the ig-platform-id set, they are 9, 10, and 8 for index 1-3 respectively.

6. This board only has 2 ports, 1 DVI and 1 HDMI. Is using type dummy and busID 0x00 still the best way to disable the third unused port?

7. Finally, (more so for informational/learning purposes), is there a post somewhere that explains when to check what box in the patch section of Hackintool to produce certain effects? At least those that relate to FB patching. :) If not, any chance they could be added to your guide? It may be useful to have a good understanding in order for each user to be informed of what they may or may not require when patching.

That's all for now, thanks for any answers you or anyone else can provide!
 
Last edited:
Joined
Jan 3, 2018
Messages
41
Motherboard
q77
CPU
Core i5 3570 3.40Ghz
Graphics
Nvidia GTX 1050
Mac
iMac, MacBook Pro
Mobile Phone
Android
Some questions:
  • Which operating system version are you running?
  • The HDMI port on motherboard is working with iGPU acceleration ('About this Mac' shows you have 1536MB VRAM)?
    • If so, did you apply a connector patch to enable HDMI?
  • If a connector patch has already been applied and HDMI output is working, then:
    • Configuring the other connectors may not make a difference, but you can still try enabling your DVI-D port or set all the other connectors to Index -1, BusID 0x00, Type DUMMY.
  • For wake-related issues:
    • You might want to try different values of darkwake in Clover Configurator --> Boot Arguments section.
    • Disconnect all internal and external USB devices except keyboard and mouse. Check if sleep and wake are okay. If so, reconnect one USB device at a time until you find the offending device.
    • Install EmuVariableUefi-64.efi in the drivers64UEFI folder and see if that makes a difference.
    • Run IORegistryExplorer and look under the XHC section to ensure that the USB ports you defined in the SSDT -- and only those ports -- are listed.
    • Search this site -- you will find a lot of good information.
Thanks a lot for your quick reply!
I'm running Mojave 10.14.3
Hdmi works with full acceleration and shows 1536 mb in about this Mac.
Smbios 18,1 imac
I did some patching when I was solving the hdmi audio issue following the method at idiots lilu guide, but in the end was not relevant cause my issue was related to Apple hda kext. Anyway, before that I already had acceleration by updating lilu and finding the right platform id for my hardware configuration.

Today I tried your advices, first tried the EmuVariableUefi-64.efi but didn't make difference. Then I tried darkwake 0, then darkwake=10, darkwake=8 and darkwake=2, but was always the same result, attempting to wake up results = restart the computer.

Xhc section has only the correct ports, my custom ssdt for usb inject all works perfectly.

Tried to exclude the other connectors with hackintool but after reboot had pink color screen and 2048mb vram! Was not intentional.
Tried to use other config plists after rebooting but even with my old configs the screen was still pink!! I was scared, but after many attempts somehow I got it back to 1536 vram. Now at least it's like it was before.
Does hackintool change things in the other config plists? Why these settings were not reverting back? I also tryed to clear nvram...

Also Sometimes when I play with some settings my asrock boot screen turns bigger, but stays like that even when I revert these settings. Does nvram somehow gets "locked".?

I did a lot of research but there are not many people with the same hardware and the ones I found have already give up trying to get sleep wake working.

Exept one guy that said disabling the other connectors fixed the issue for him. That's why I wanted to try...

Thanks again and congratulations for this awesome job at the community!
 
Joined
May 9, 2019
Messages
3
Motherboard
MSI B360 mortar
CPU
i5-8400
Graphics
uhd 630
sorry to bother you, I have read all the answers, but didn't find about moutherboad MSI B360 MORTAR.I only have DVI dispaly,can you give me some advices?B360 have DVI,HDMI and DP。
 

CaseySJ

Moderator
Joined
Nov 11, 2018
Messages
4,577
Motherboard
Gigabyte Designare Z390
CPU
i7-9700K
Graphics
RX 580
Mac
MacBook Air, Mac Pro
Classic Mac
Quadra
Mobile Phone
iOS
@CaseySJ, thanks for the guide! :)

I just read the entire thread (all 62 pages!), in order to inform my self of all the details before attempting this.
There should be a Nobel Prize for that! :)
...
But for now, due to the methodical testing that must be performed, my goal is to know what is the minimal amount of things I need to include in the patch to successfully test ports (what boxes to check/uncheck), without adding unnecessary/extra variables that may interphere or mess things up. So my questions (before I get started) are as follows:

1. Do I need to do anything with the connector flags? By default, when openning Hackintool, some of the flags are checked. Should they all be unchecked?
You have a Coffee Lake CPU (i5-8400), Mojave 10.14.4, Gigabyte H370 Aorus Gaming 3 WIFI, and two good monitors with both DP and HDMI. You are already off to a great start.

You should start Hackintool by selecting:
  • Intel Generation: Coffee Lake
  • Platform ID: 0x3E9B0007
When you select the Connectors tab, the first three will be set to DP. Your motherboard has DVI-D and HDMI, which are both considered by MacOS to be type "HDMI". Your motherboard has no DP port. So your first test configuration might be:

Index 1: BusID 0x01, Type HDMI (unused port? You can set to HDMI anyway)
Index 2: BusID 0x04, Type HDMI (physically an HDMI port?)
Index 3: BusID 0x06, Type HDMI (physically a DVI-D port?)

Gigabyte boards with Coffee Lake CPUs tend to prefer BusID 0x04 for true HDMI (physical HDMI port). The BusID for DVI-D can take on any other value (0x01, 0x02, 0x06).

Be sure to follow the Procedure mentioned in the Guide by watching for red highlighted rows.

2. I'm assuming since Mojave 14.4 has support for CFL graphics that I don't need to use device ID, just the recommended 3E9B0007 ig-platform-id? (read a post a few pages back that seems to imply this)
Correct.

3. Since my UEFI allows me to change video mem sizes and such, do I need the VRAM boxes checked when patching? Or just connectors and graphic device?
Always start with the fewest patch settings. In your case omit the VRAM and DVMT Pre-Alloc settings in the beginning. But don't hesitate to add them if the system fails to boot, boots to a black screen, takes far too long to boot, etc.

4. Do I need HDMI20 checked (is it for 4k only, or would 1440p (2k?) also require it)?
This enables a patch for HDMI 2.0, which provides 4K at 60Hz. Not all systems require it. The HDMI port on your H370 is v1.4 that supports a maximum of 4K at 30Hz, so you do not need this.

5. Do I do anything with the pipes number column? Only mention of it I read was setting them all to 18 to fix a certain issue; is leaving them at their default for now also OK? Right now with the ig-platform-id set, they are 9, 10, and 8 for index 1-3 respectively.
In the Patch --> Advanced section you will find a checkbox labeled Hotplug Reboot Fix. This should be checked on to prevent the system from rebooting when you plug or unplug video cables while the system is running. This has the effect of setting all Pipe values to the same number, in this case 18 was chosen. We believe there's nothing special about the number 18. What's important is to place all connectors into the same Pipe.

6. This board only has 2 ports, 1 DVI and 1 HDMI. Is using type dummy and busID 0x00 still the best way to disable the third unused port?
Yes, but at this time you do not know whether the unused port is at Index 1, Index 2, or Index 3. So you have to start by setting them all to HDMI as previously mentioned and then seeing which row lights up in red when you connect HDMI cable and DVI-D cable. The row that never lights up is the unused port.

7. Finally, (more so for informational/learning purposes), is there a post somewhere that explains when to check what box in the patch section of Hackintool to produce certain effects? At least those that relate to FB patching. :) If not, any chance they could be added to your guide? It may be useful to have a good understanding in order for each user to be informed of what they may or may not require when patching.
Good idea. I'll add a section explaining some of the checkboxes, but for now, the minimum recommended configuration is shown in the two screenshots below.
Screen Shot 2019-05-08 at 7.25.18 PM.png Screen Shot 2019-05-08 at 7.25.48 PM.png
 
Last edited:

CaseySJ

Moderator
Joined
Nov 11, 2018
Messages
4,577
Motherboard
Gigabyte Designare Z390
CPU
i7-9700K
Graphics
RX 580
Mac
MacBook Air, Mac Pro
Classic Mac
Quadra
Mobile Phone
iOS
...
Also Sometimes when I play with some settings my asrock boot screen turns bigger, but stays like that even when I revert these settings. Does nvram somehow gets "locked".?

I did a lot of research but there are not many people with the same hardware and the ones I found have already give up trying to get sleep wake working.

Exept one guy that said disabling the other connectors fixed the issue for him. That's why I wanted to try...
...
There's certainly no harm in disabling unused connectors. You should try that. Also feel free to post your config.plist with serial numbers redacted from SMBIOS. There might be some power management checkboxes or ACPI flags (such as Fix HPET, Fix IPIC, etc.) that may help.
 

CaseySJ

Moderator
Joined
Nov 11, 2018
Messages
4,577
Motherboard
Gigabyte Designare Z390
CPU
i7-9700K
Graphics
RX 580
Mac
MacBook Air, Mac Pro
Classic Mac
Quadra
Mobile Phone
iOS
sorry to bother you, I have read all the answers, but didn't find about moutherboad MSI B360 MORTAR.I only have DVI dispaly,can you give me some advices?B360 have DVI,HDMI and DP。
If your monitor only supports DVI, you might have a more difficult time. We really recommend current-generation monitors with DP 1.2+ and HDMI 1.4+ support.

Nevertheless, you should follow the Procedure in the Guide.

Connect the DVI-D cable to computer and to monitor. Start by setting the Connector Type to HDMI because MacOS considers DVI-D to be a form of HDMI. (And VGA is considered to be a form of DisplayPort.)

You will have to try several experiments. Perhaps like this:

Index 1, BusID 0x01, Type HDMI
Index 2, BusID 0x04, Type HDMI
Index 3, BusID 0x06, Type HDMI

Apply patches, reboot, see which row lights up in red. If you get black screen, then try next experiment below.

Index 1, BusID 0x02, Type HDMI
Index 2, BusID 0x04, Type HDMI
Index 3, BusID 0x06, Type HDMI

If nothing works, feel free to ask for help. But when you do, please provide this information:
  • Which version of macOS is running? 10.14.4?
  • What is the make/model of your monitor?
  • Post your config.plist, but remove serial numbers from SMBIOS section.
  • Run IORegistryExplorer, select File --> Save As... and upload the IOReg file.
 
Joined
May 9, 2019
Messages
3
Motherboard
MSI B360 mortar
CPU
i5-8400
Graphics
uhd 630
If your monitor only supports DVI, you might have a more difficult time. We really recommend current-generation monitors with DP 1.2+ and HDMI 1.4+ support.

Nevertheless, you should follow the Procedure in the Guide.

Connect the DVI-D cable to computer and to monitor. Start by setting the Connector Type to HDMI because MacOS considers DVI-D to be a form of HDMI. (And VGA is considered to be a form of DisplayPort.)

You will have to try several experiments. Perhaps like this:

Index 1, BusID 0x01, Type HDMI
Index 2, BusID 0x04, Type HDMI
Index 3, BusID 0x06, Type HDMI

Apply patches, reboot, see which row lights up in red. If you get black screen, then try next experiment below.

Index 1, BusID 0x02, Type HDMI
Index 2, BusID 0x04, Type HDMI
Index 3, BusID 0x06, Type HDMI

If nothing works, feel free to ask for help. But when you do, please provide this information:
  • Which version of macOS is running? 10.14.4?
  • What is the make/model of your monitor?
  • Post your config.plist, but remove serial numbers from SMBIOS section.
  • Run IORegistryExplorer, select File --> Save As... and upload the IOReg file.
 
Joined
May 9, 2019
Messages
3
Motherboard
MSI B360 mortar
CPU
i5-8400
Graphics
uhd 630
thanks for your idea,I'll try it later
 
Joined
Oct 3, 2013
Messages
67
Motherboard
HP Probook 450 G6-Clover
CPU
i7-8565U
Graphics
UHD 620, 1920x1080
Mobile Phone
iOS
Thanks for the helpful reply @CaseySJ!
So I just tested the H370 Aorus Gaming 3 WIFI, and got the following:

Index 1/port 5: not used. I set it to BusID 00, pipe 0 and type to dummy.
Index 2/port 6: physical DVI. BusID set to 02, type to HDMI of course. I first tried BusIDs 06 and 05, neither worked.
Index 3/port 7: physical HDMI. BusID set to 04, type to HDMI. That was the first BusID I tried as per @CaseySJ's note about Gigabyte boards' HDMI, so it worked right away!
For the 2 working ports I set pipe to 18.

Both ports work great, system starts up normal. HDMI gives me 2560X1440 on the Acer monitor, I had the Gateway plugged in to the DVI, and that got me a full 1920X1080 (highest res for that monitor) with no issues.

I had purple/green screen on HDMI at first, but that was because the first time I ran the patch, for some reason Hackintool didn't create the entire code, or the port types got reset back to DP and so it didn't generate port type code. Therefore when I restarted, the ports were still DP. So anyone having issues, remember to check the connectors tab before patching (as the guide explains), just in case things get reset. Once I redid the code things worked great!

@CaseySJ, here is the code generated by Hackintool, so you can add it to the boards configurations list. If something's missing or you need something else added/tested, let me know! :)

I didn't include the keys/values marked with a * in my config, as I didn't feel I needed them for things to work. I left them here for the sake of completeness and just in case.
Should I put them in? Or are they not needed if things are showing up fine in system info?

Patch code for Gigabyte H370 Aorus Gaming 3 WIFI FrameBuffer:

<key>Properties</key>
<dict>
<key>PciRoot(0x0)/Pci(0x2,0x0)</key>
<dict>
<key>AAPL,ig-platform-id</key>
<data>
BwCbPg==
</data>
<key>AAPL,slot-name</key> *
<string>Internal</string> *
<key>device_type</key> *
<string>VGA compatible controller</string> *
<key>framebuffer-con0-busid</key>
<data>
AAAAAA==
</data>
<key>framebuffer-con0-enable</key>
<data>
AQAAAA==
</data>
<key>framebuffer-con0-pipe</key>
<data>
AAAAAA==
</data>
<key>framebuffer-con0-type</key>
<data>
AQAAAA==
</data>
<key>framebuffer-con1-busid</key>
<data>
AgAAAA==
</data>
<key>framebuffer-con1-enable</key>
<data>
AQAAAA==
</data>
<key>framebuffer-con1-pipe</key>
<data>
EgAAAA==
</data>
<key>framebuffer-con1-type</key>
<data>
AAgAAA==
</data>
<key>framebuffer-con2-busid</key>
<data>
BAAAAA==
</data>
<key>framebuffer-con2-enable</key>
<data>
AQAAAA==
</data>
<key>framebuffer-con2-pipe</key>
<data>
EgAAAA==
</data>
<key>framebuffer-con2-type</key>
<data>
AAgAAA==
</data>
<key>framebuffer-patch-enable</key>
<data>
AQAAAA==
</data>
<key>model</key> *
<string>UHD Graphics 630 (Desktop)</string> *
</dict>
</dict>


Any comments? Did I miss something? Can I improve it somehow? :)

Also, when doing the patch I only checked Graphic device and Connectors, for now left everything else in both tabs unchecked. I didn't touch the connector flags section either.
 
Last edited:
Joined
Apr 19, 2019
Messages
32
Motherboard
ASUS Strix Z270-F
CPU
i7-7700K
Graphics
HD 630
Mac
iMac
Hello @CaseySJ , the current situation is this:
Monitor 1 (main) HP 24o
Out PC HDMI, direct cable HDMI to HDMI connected to the monitor in HDMI port:
Perfectly working

Monitor 2 (Samsung 2243WM)
Out port PC DVI direct cable DVI to DVI connected to the monitor in DVI port:
Black screen.

DP Cable not connected.

I noticed that if I use 18.3 instead of 17.1 the connectors index2 Bus id 04 and Index 3 Bus id 0x06 turn red, but monitor 1 creates strips and monitor 2 remains off.
While if I use 17,1 the monitor 1 works well but only one connector (index 2 0x04) turns red and monitor 2 is always off.

ps: the monitor 1 ram is correct (2048 MB)?
 

Attachments

Top