Add Raspberry Pi Pico project

This commit is contained in:
2025-04-17 20:48:12 +02:00
parent 8b9661f149
commit 3a9413ebd6
6 changed files with 223 additions and 0 deletions

12
pico/delete_folder.py Normal file
View File

@@ -0,0 +1,12 @@
import os
def delete_folder(path):
for file in os.listdir(path):
full_path = path + "/" + file
try:
os.remove(full_path) # Datei löschen
except OSError:
delete_folder(full_path) # Falls es ein Ordner ist, rekursiv löschen
os.rmdir(path) # Ordner selbst löschen
delete_folder("/mfrc522") # Beispiel: Löscht den gesamten MFRC522-Ordner