Software flashing procedure for Macs involves the following steps:
1) download Mojave 10.14.3 (the 6GB+ from AppStore or with
this)
2) download
Pacifist, start it, click "Open Package" and select the Mojave installer. On the context menu click Pacifist->Show Software Update Packages..., wait a few minutes and the installer will be loaded. Inside you will find 5 FirmwareUpdate.pkg dated 8.2.2019. Select them and click Open Selected Packages, after a couple of minutes the archives will be loaded. In each folder locate and compare the corresponding .fd file of your Mac by right click->Show Info (you are going to notice that all of them are the same size and some of them are with a different date). Right click on one of each dated differently and Extract to a Custom Location. If needed, you can rename them after the extraction.
3) download
UEFI Tool, open those .fd files and compare the differences regarding their NVMe components. Click File->Search->Text tab, untick "unicode", tick "case sensitive", write "NVMe" in the search field. Click "search" button, a result will appear in the bottom as a text string, click "ASCII text "NVMe" found...". Right click on the entire branch "51116915-..." and select "extract as is", choose a folder to extract it as ".ffs".
Alternative 1: a patched Bottom
4a) reboot your Mac into Recovery Mode by restarting your computer and after the chime holding down Command + R until the progress bar appears under the Apple logo. In the Terminal write -csrutil disable . Restart the iMac.
5a) open
RomTool (password rom) and click "Dump System Rom" (note that this does NOT work in newer Macs, e.g. iMac 27" Late 2015, but works in order ones, e.g. iMac 27" Late 2013)
6a) open your dumped ROM and click File->Search->Text tab, untick "unicode", tick "case sensitive", write "NVMe" in the search field. Click "search" button. A result will appear in the bottom as a text string, click "ASCII text "NVMe" found...", right click on the entire branch "51116915-..." and select "replace as is", select your extracted ".ffs" file from above
(here for some reason the replacing does not work, if you save the file and then open it, you will see that the branch is NOT replaced, so if you manage to figure that out, there must have been something that I missed, move forward)
7a) if you have managed to replace and verify that the string is infact replaced, go up the list and select the master branch "Intel Image". Click File->Save image file and this will be your patched bootrom for the old iMac containing the NVMe bootrom part of a newer iMac.
8a) here ideally you could flash your iMac's bootrom using RomTool.
Alternative 2: inject the NVMe support directly into the Mojave installer
4b) We have to replace the extracted NVMe part from one of the .fd files to all the others within the Mojave installer. Click File->Search->Text tab, untick "unicode", tick "case sensitive", write "NVMe" in the search field. Click "search" button. A result will appear in the bottom as a text string, click "ASCII text "NVMe" found...", right click on the entire branch "51116915-..." and select "replace as is", select your extracted ".ffs" file from above
(I do not know if this replace would work, because above in step 6a) it did NOT, so it may be UEFI Tool issue, or another, someone can continue my research and find out)
5b) if you have managed to replace and verify that the string is infact replaced, run the patched Mojave 10.14.3 installer
(chances are there will be checksum protections, but I think it is worth the try, as there is not much else that can be attempted on a software level at this point)
Some more info on the topic and the procedure around
>here<
Otherwise, Matt cards are not possible on iMacs, thus hardware flashing is done with
this, but it is pricey and only worth it if you are planning to use it for business. There may be a way that a cheap SPI programmer would work, but you have to contact
info@cmizapper.com with a detailed photo of how the SPI chip looks like on the iMac's motherboard and ask if any of his MacBook tools would work there (I will take a photo of the motherboard these days when upgrading my iMac 5k Late 2015).