some questions: snapshot (). save filename & RTC

I am sorry that the question level is low because I am an embedded beginner.

When saving as a jpg file using “snapshot (). save”, I want to save the file name using only RTC’s year / month / day / time. How should I write the code?

And is there any way to get the now time when using RTC?

Please search the forums for RTC topics, you’ll find many examples on how to initialize and use the RTC, there’s even a script saving images with timestamps (and an example in the IDE and docs). However, note you need to set the RTC time on each power up and keep the power connected otherwise the RTC will reset to the default time/date.