GoPro updates Hero5 firmware, get your GoPro updates here
The first time I got an SD card error on my GoPro camera it was tough. I threw the house at the thing with zero results. Formatted the SD card, tried a different SD from another camera, bought a new SD card... nothing. Then it hit me, I updated the firmware and problem solved(!). Lesson learned: keep your GoPro up to date. Coincidentally this new firmware improves SD card stability. Download the latest firmware for your Hero5 Black or Hero5 Session here.