[X Style (Pure) Android Development] mdkathon:
By the way, this worked for me. Wifi would not turn on after using the tool. I kept the log here is the error to look for:

Test
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
error: device not found
< waiting for device >
target reported max download size of 536870912 bytes
sending 'partition' (32 KB)...
OKAY [ 0.010s]
writing 'partition'...
(bootloader) This may take a few seconds, if a
(bootloader) different partition table is being
(bootloader) flashed since we need to backup
(bootloader) and restore a few partitions
(bootloader) Flashing primary GPT image...
(bootloader) Flashing backup GPT image...
OKAY [ 0.665s]
finished. total time: 0.681s
target reported max download size of 536870912 bytes
sending 'bootloader' (2699 KB)...
OKAY [ 0.068s]
writing 'bootloader'...
(bootloader) flashing aboot ...
(bootloader) flashing sbl1 ...
(bootloader) flashing pmic ...
(bootloader) flashing rpm ...
(bootloader) flashing tz ...
(bootloader) flashing hyp ...
(bootloader) flashing sdi ...
OKAY [ 1.663s]
finished. total time: 1.737s
target reported max download size of 536870912 bytes
sending 'logo' (2001 KB)...
OKAY [ 0.052s]
writing 'logo'...
OKAY [ 0.053s]
finished. total time: 0.114s
target reported max download size of 536870912 bytes
sending 'boot' (40960 KB)...
OKAY [ 0.975s]
writing 'boot'...
OKAY [ 0.758s]
finished. total time: 1.743s
target reported max download size of 536870912 bytes
sending 'recovery' (41040 KB)...
OKAY [ 0.945s]
writing 'recovery'...
OKAY [ 0.761s]
finished. total time: 1.711s
target reported max download size of 536870912 bytes
sending 'system' (260220 KB)...
OKAY [ 5.709s]
writing 'system'...
OKAY [ 5.362s]
finished. total time: 11.085s
target reported max download size of 536870912 bytes
sending 'system' (252707 KB)...
OKAY [ 5.663s]
writing 'system'...
OKAY [ 4.773s]
finished. total time: 10.455s
target reported max download size of 536870912 bytes
sending 'system' (258179 KB)...
OKAY [ 5.774s]
writing 'system'...
OKAY [ 4.942s]
finished. total time: 10.731s
target reported max download size of 536870912 bytes
sending 'system' (261640 KB)...
OKAY [ 5.830s]
writing 'system'...
OKAY [ 5.204s]
finished. total time: 11.049s
target reported max download size of 536870912 bytes
sending 'system' (247577 KB)...
OKAY [ 5.520s]
writing 'system'...
OKAY [ 4.623s]
finished. total time: 10.159s
target reported max download size of 536870912 bytes
sending 'system' (256244 KB)...
OKAY [ 5.785s]
writing 'system'...
OKAY [ 5.052s]
finished. total time: 10.842s
target reported max download size of 536870912 bytes
sending 'system' (257510 KB)...
OKAY [ 5.561s]
writing 'system'...
OKAY [ 5.004s]
finished. total time: 10.570s
target reported max download size of 536870912 bytes
sending 'system' (257477 KB)...
OKAY [ 5.710s]
writing 'system'...
OKAY [ 4.839s]
finished. total time: 10.553s
target reported max download size of 536870912 bytes
sending 'system' (258112 KB)...
OKAY [ 5.640s]
writing 'system'...
OKAY [ 4.643s]
finished. total time: 10.289s
target reported max download size of 536870912 bytes
sending 'system' (215364 KB)...
OKAY [ 4.645s]
writing 'system'...
OKAY [ 4.154s]
finished. total time: 8.804s
target reported max download size of 536870912 bytes
sending 'modem' (41675 KB)...
OKAY [ 0.905s]
writing 'modem'...
(bootloader) Preflash validation failed
FAILED (remote failure)
finished. total time: 0.940s
erasing 'modemst1'...
OKAY [ 0.009s]
finished. total time: 0.012s
erasing 'modemst2'...
OKAY [ 0.008s]
finished. total time: 0.011s
target reported max download size of 536870912 bytes
sending 'fsg' (1297 KB)...
OKAY [ 0.034s]
writing 'fsg'...
OKAY [ 0.052s]
finished. total time: 0.092s
erasing 'cache'...
OKAY [ 0.023s]
finished. total time: 0.026s
erasing 'userdata'...
OKAY [ 0.580s]
finished. total time: 0.583s
rebooting...

finished. total time: 0.004s

You can see the error when flashing modem.

Fix as noted above:

PS C:\Users\sfinn\Desktop\CLARK_RETUS_5.1.1_LPH23.116-18_cid9_subsidy-DEFAULT_CFC.xml_SHAWN5162> .\adb reboot bootloader
> .\fastboot flash modem NON-HLOS.bin
target reported max download size of 536870912 bytes
sending 'modem' (41675 KB)...
OKAY [ 0.912s]
writing 'modem'...
OKAY [ 0.932s]
finished. total time: 1.851s
> .\adb reboot system
error: device not found
> .\adb devices
List of devices attached

> .\fastboot reboot
rebooting...

finished. total time: 0.002s

note, the .\ is due to me using powershell.