7.4.8.2 Write an Encrypted Program when Keys are already Written

CommandDescription
0x00000000_DE05_5345ACBAAfter Reset, unblock the bootloader
0x00000000_DE05_ACBA5345
0x00000000_0004_0000XXXXSet the number of blocks of the encrypted program
0x00000000_0005_XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXXSet the initialization vector of the encrypted program
0x00000000_0006_XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXXXSet signature of the encrypted program
0x00000000_0001_EEEEEEEE…Write the program at consecutive addresses from 0x00000000
0x00000000_0013_00000000Launch code decryption
0x00000000_0012_00000000Check bootloader status to know if decrypt process has finished. Answers:
  • 0x”Bootloader Hardware signature”_0000_ 00000002 (aes_active)
  • 0x”Bootloader Hardware signature”_0000_ 00000000 (bootloader ready)
0x00000000_0002_XXXXXXXX…(Optional) Read the decrypted program to validate it (READ_RAM fuse must not be set)
0x400E1800_0000_00000000Clear CPUWAIT to start program operation
0x00000000_A66A_00000000Give control of the MISO signal to M7-SPI and disable bootloader clock