ESP32 flash encryption using esp-idf framework in pio

Hello everyone,

After a good read on Flash Encryption - ESP32 - — ESP-IDF Programming Guide v4.2.1 documentation I was wondering, I can’t use idf.py to flash the firmware inside platformio, neither can I use ‘idf.py encrypted-app-flash monitor’ nor ‘idf.py encrypted-flash monitor’, is it possible to encrypt ESP32’s flash using pio?

Thank you.

Can anyone give some help here?