Index
How to erase and unlock protected read memory
Please note that memory will be erased and the original firmware will be lost.The next commands will erase the original firmware as also will setup the STM8 options bytes to enable the PWM N channels:
echo "00 00 ff 20 df 00 ff 00 ff 00 ff 00 ff 00 ff" | xxd -r -p > option_bytes_pwm_n_channels_enabled.bin
sudo stm8flash -c stlinkv2 -p stm8s105?6 -s opt -w option_bytes_pwm_n_channels_enabled.bin
Example: