SPFlashTools devShells Flake
It's might better to do wrapQtAppsHook.
Maybe I'll do it next time when I need it.
Save this and $ nix develop.
Go to directory where it contains SPFlashToolV6 and run $ spflashtool.
You must expose your /dev/ttyACM0 as 0666. Use following:
services.udev.extraRules = ''
# Rule for mediatek
KERNEL=="ttyACM*", ATTRS{idVendor}=="0e8d", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1"
'';