FA2022 USB-D11C-serial (Ubuntu_Live_USB + edbg + Xiao)
ref.Linux UbuntuのLive USBメモリ作成・インストール手順
Make Ubuntu Bootable USB
Download Ubuntu Desktop
Ubuntu 20.04.3 LTS
Write iso file to USB_memory_1
Raspberry Pi Imager
- Operating System > Use custom > ubuntu-20.04.3-desktop-amd64.iso
- Storage > USB3.0 HIGH SPEED MEDIA
Boot Ubuntu from USB
BIOS Setting
- Turn on PC
- Press F2 to open BIOS Setup Utility
- Change order of Boot Device:
- USB-HDD
- Windows HDD drive
Plug USB memory into PC and Boot Ubuntu from USB
Press: Try Ubuntu
Check DISK
Open Terminal
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 | $ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
loop0 7:0 0 2G 1 loop /rofs
loop1 7:1 0 55.4M 1 loop /snap/core18/2128
loop2 7:2 0 51M 1 loop /snap/snap-store/547
loop3 7:3 0 65.1M 1 loop /snap/gtk-common-themes/1515
loop4 7:4 0 32.3M 1 loop /snap/snapd/12704
loop5 7:5 0 219M 1 loop /snap/gnome-3-34-1804/72
sda 8:0 0 465.8G 0 disk
├─sda1 8:1 0 400M 0 part
├─sda2 8:2 0 300M 0 part
├─sda3 8:3 0 128M 0 part
├─sda4 8:4 0 449.8G 0 part
├─sda5 8:5 0 466M 0 part
└─sda6 8:6 0 14.8G 0 part
sdb 8:16 0 223.6G 0 disk
├─sdb1 8:17 0 2.9G 0 part /cdrom
├─sdb2 8:18 0 3.9M 0 part
└─sdb3 8:19 0 220.7G 0 part /var/crash
|
Plug USB_memory_2(32GB)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23 | $ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
loop0 7:0 0 2G 1 loop /rofs
loop1 7:1 0 55.4M 1 loop /snap/core18/2128
loop2 7:2 0 51M 1 loop /snap/snap-store/547
loop3 7:3 0 65.1M 1 loop /snap/gtk-common-themes/1515
loop4 7:4 0 32.3M 1 loop /snap/snapd/12704
loop5 7:5 0 219M 1 loop /snap/gnome-3-34-1804/72
sda 8:0 0 465.8G 0 disk
├─sda1 8:1 0 400M 0 part
├─sda2 8:2 0 300M 0 part
├─sda3 8:3 0 128M 0 part
├─sda4 8:4 0 449.8G 0 part
├─sda5 8:5 0 466M 0 part
└─sda6 8:6 0 14.8G 0 part
sdb 8:16 0 223.6G 0 disk
├─sdb1 8:17 0 2.9G 0 part /cdrom
├─sdb2 8:18 0 3.9M 0 part
└─sdb3 8:19 0 220.7G 0 part /var/crash
sdc 8:32 1 28.7G 0 disk
├─sdc1 8:33 1 2.9G 0 part /media/ubuntu/Ubuntu 20.04.3 LTS amd64
├─sdc2 8:34 1 3.9M 0 part
└─sdc3 8:35 1 25.8G 0 part /media/ubuntu/writable
|
sdc is USB_memory_2 for Live_USB
make Ubuntu_Live_USB
ref.Linux UbuntuのLive USBメモリ作成・インストール手順
Run Ubuntu 20.04.3LTS Installer
on the desktop
Make new Partition on sdc(USB_memory_2)
- 1st Partition
- size: 4094 MB
- Type of the new partition: Primary
- Location of the new partition: End of this space
- Use as: swap
- Mount point: none
- 2nd Partition
- size: 26668 MB (all)
- Type of the new partition: Primary
- Location of the new partition: Beginning of this space
- Use as: ext4
- Mount point: /
Boot from Live_USB
- shutdown Ubuntu
- take of Bootable USB (USB memory_1)
- remain Live_USB (USB memory_2)
- Tour on PC and Press F2 to open BIOS
- Change order of Boot Device:
- USB-HDD
- Ubuntu
- Windows HDD drive
- Boot Ubuntu from Live_USB
esbg Setup
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72 | $ sudo apt update
$ sudo apt install libudev-dev
$ sudo apt install make
$ sudo apt install build-essential
$ sudo apt install git
$ git clone https://github.com/ataradov/edbg.git
$ ls
edbg
$ cd edbg/
$ ls
Makefile
$ make all
$ ./edbg -h
CMSIS-DAP SWD programmer. Built Dec 27 2021 23:03:25.
Usage: ./edbg [options]
Options:
-h, --help print this help message and exit
-b, --verbose print verbose messages
-e, --erase perform a chip erase before programming
-p, --program program the chip
-v, --verify verify memory
-k, --lock lock the chip (set security bit)
-u, --unlock unlock the chip (forces chip erase in most cases)
-r, --read read the whole content of the chip flash
-f, --file <file> binary file to be programmed or verified; also read output file name
-t, --target <name> specify a target type (use '-t list' for a list of supported target types)
-l, --list list all available debuggers
-s, --serial <number> use a debugger with a specified serial number or index in the list
-c, --clock <freq> interface clock frequency in kHz (default 16000)
-o, --offset <offset> offset for the operation
-z, --size <size> size for the operation
-F, --fuse <options> operations on the fuses (use '-F help' for details)
$ cd
$ ls
edbg
$ git clone https://github.com/mattairtech/ArduinoCore-samd.git
$ ls
ArduinoCore-samd
edbg
$ cd ArduinoCore-samd/bootloaders/zero/binaries
$ ls
sam_ba_Generic_D11C14A_SAMD11C14A.bin
$ cp sam_ba_Generic_D11C14A_SAMD11C14A.bin ~/edbg/
$ cd ~/edbg/
$ ls
sam_ba_Generic_D11C14A_SAMD11C14A.bin
edbg
$ ./edbg -l
Attached debuggers:
0: 1DFBFE6050575230372E3120FF160724 - Seeed CMSIS-DAP
$ sudo ./edbg -b -t samd11 -epv -f sam_ba_Generic_D11C14A_SAMD11C14A.bin -s 0
Debugger: Seeed Seeed CMSIS-DAP 1 2.0.0 (SJ)
Clock frequency: 16.0 MHz
Target: SAM D11C14A (Rev B)
Erasing... done.
Programming.... done.
Verification.... done.
$ lsusb
Bus 002 Device 004: ID 2886:802f
Bus 002 Device 003: ID 0781:5597 SanDisk Corp.
Bus 002 Device 006: ID 16d0:0557 MCS
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 058f:b201 Alcor Micro Corp.
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
|
Last update: December 27, 2021