Unroot Galaxy Note 5 SM-N902i (XSA Australia) with Heimdall - "System UI has stopped" I am running a linux machine and trying to unroot my Galaxy Note 5. I've downloaded the lastest firmware from sammobile: N920IDVU4CRG1_N920IXSA4CRG1_XSA.zip which extracts to:
boot.img
cache.img
cm.bin
hidden.img
modem.bin
recovery.img
sboot.bin
system.img

Then I've been trying to use heimdall like so:

heimdall flash --verbose --BOOTLOADER sboot.bin --CM cm.bin --BOOT boot.img --RECOVERY recovery.img --RADIO modem.bin --SYSTEM system.img --CACHE cache.img --HIDDEN hidden.img

The process finishes successfully but then when the phone reboots it hangs with an error: "System UI has stopped"

I've previously executed heimdall print-pit to check the pit list. I noticed that there are more pit entries than the 8 provided in the firmware. I don't know if that's normal.
I also tried using the pit file found on the forum with the same negative result: NOBLELTE_AUS_XSA.pit

heimdall flash --pit NOBLELTE_AUS_XSA.pit --verbose --BOOTLOADER sboot.bin --CM cm.bin --BOOT boot.img --RECOVERY recovery.img --RADIO modem.bin --SYSTEM system.img --CACHE cache.img --HIDDEN hidden.img

Same error.

Is there something that I've been missing or done wrong?

Many thanks :)
The problems exists in the system.img. It might have been comiled with a corrupted systemUI.apk. Try other flashable files.