v.0.10.0 redesign prj structure, multi dev containers

This commit is contained in:
tiijay
2025-11-20 11:50:19 +00:00
parent 53b1b96fb3
commit 76a8203458
52 changed files with 63 additions and 83 deletions

29
pico-client/async.py Normal file
View File

@@ -0,0 +1,29 @@
import uasyncio as asyncio # type: ignore
async def task1():
for i in range(5):
print('Task 1:', i)
await asyncio.sleep(1) # Non-blocking sleep
async def task2():
for i in range(5):
print('Task 2:', i)
await asyncio.sleep(2) # Different sleep time
async def task3():
for i in range(5):
print('Task 3:', i)
await asyncio.sleep(4) # Different sleep time
async def main():
# Run both tasks concurrently
await asyncio.gather(task1(), task2(), task3())
print("we're done.")
# Run the event loop
asyncio.run(main())