Skip to content
Snippets Groups Projects
Commit 42a63265 authored by Kevin Whitaker's avatar Kevin Whitaker
Browse files

add some more structure

parent eab0d342
No related branches found
No related tags found
No related merge requests found
import ElementTree
from urllib import urequest
import sdcard
import gc
import uos
......@@ -10,6 +9,18 @@ class uNextcloud:
def __init__(self):
self.sd_spi = machine.SPI(0, sck=machine.Pin(18, machine.Pin.OUT), mosi=machine.Pin(19, machine.Pin.OUT), miso=machine.Pin(16, machine.Pin.OUT))
self.sd = sdcard.SDCard(sd_spi, machine.Pin(22))
self.username = None
self.password = None
uos.mount(sd, "/sd")
gc.collect()
def set_auth(self, username, password):
self.username = username
self.password = password
def get_folder_items(self, folder_path):
pass
def download_file_to_path(self, folder_path, file, destination_path):
pass
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment