]>
apps.delaporte.us Git - dotfiles.git/blob - invoke/esptool/tasks.py
1 from invoke
import task
3 from datetime
import datetime
as dt
6 HOME
= os
.path
.expanduser('~')
7 TODAY
= dt
.now().strftime('%Y.%m.%d')
12 - Set the Cardputer Adv power to 'off' state
13 - Plugging in to USB will cause it to boot
14 - Hold 'Go' while booting
15 - Hold 'Go' and press 'Reset' to try again.
16 - On success, the usual screen content still shows up
17 > Tip: Be sure to use a cable that can carry data, not just power.
20 https://github.com/echo-lalia/MicroHydra
27 result
= c
.run(f
'groups {os.getlogin()}')
28 assert 'dialout' in result
.stdout
33 input('Un-plug in the device...')
34 c
.run('lsusb > /tmp/before.txt')
35 input('Plug in the device...')
36 c
.run('lsusb > /tmp/after.txt')
37 result
= c
.run('diff /tmp/before.txt /tmp/after.txt')
41 # Maybe https://thelastoutpostworkshop.github.io/ESPConnect/ in Chromium?
47 c
.run('ls /dev/ttyACM*')
48 # c.run('ls /dev/ttyUSB*')
52 c
.run(f
'esptool --port {DEV} chip-id')