CPU: Freescale i.MX8MQ rev2.0 1500 MHz (running at 1000 MHz) CPU: Commercial temperature grade (0C to 95C) at 64C Reset cause: POR Model: Freescale i.MX8MQ Phanbell DRAM: 1 GiB Board id: 6 Baseboard id: 1 MMC: FSL_SDHC: 0, FSL_SDHC: 1 *** Warning - bad CRC, using default environment
In: serial Out: serial Err: serial
BuildInfo: - ATF - U-Boot 2017.03.3
flash target is MMC:0 Net: Warning: ethernet@30be0000 using MAC address from ROM eth0: ethernet@30be0000 Fastboot: Normal Hit any key to stop autoboot: 0 u-boot=> [A
That is shown on the screen monitor of Google Coral Dev Board.
We now need to input fastboot 0 on u-boot=>
prompt. After having connected the Type C OTG cable, we should be able
to see on the host:
Now, login with - username: mendel - password: mendel
1 2
➜ ~ mdt devices mocha-shrimp (192.168.100.2)
You will be able to see Google Coral Dev Board is
NOW connected. If you don’t see the EXPECTED output
mocha-shrimp (192.168.101.2), just plug out and
plug in the Type C power cable again.
Unfortunately, mdt tool does NOT
work properly.
1 2 3 4 5 6 7 8 9 10 11
➜ mendel-enterprise-day-13 mdt shell Waiting for a device... Connecting to mocha-shrimp at 192.168.101.2 Key not present on mocha-shrimp -- pushing
It looks like you're trying to connect to a device that isn't connected to your workstation via USB and doesn't have the SSH key this MDT generated. To connect with `mdt shell` you will need to first connect to your device ONLY via USB.
Cowardly refusing to attempt to push a key to a public machine.
This bug has been clarified on StackOverflow.
By modifying file vim
$HOME/.local/lib/python3.6/site-packages/mdt/sshclient.py line
86, from if not self.address.startswith('192.168.100'): to
if not self.address.startswith('192.168.10'):, problem
solved.
➜ mendel-enterprise-day-13 mdt shell Waiting for a device... Connecting to mocha-shrimp at 192.168.101.2 Key not present on mocha-shrimp -- pushing Linux mocha-shrimp 4.14.98-imx #1 SMP PREEMPT Fri Nov 8 23:28:21 UTC 2019 aarch64
The programs included with the Mendel GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright.
Mendel GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Thu Feb 14 10:12:02 2019 mendel@mocha-shrimp:~$ ls mendel@mocha-shrimp:~$ pwd /home/mendel mendel@mocha-shrimp:~$ uname -a Linux mocha-shrimp 4.14.98-imx #1 SMP PREEMPT Fri Nov 8 23:28:21 UTC 2019 aarch64 GNU/Linux mendel@mocha-shrimp:~$ lsb_release -a No LSB modules are available. Distributor ID: Mendel Description: Mendel GNU/Linux 4 (Day) Release: 10.0 Codename: day mendel@mocha-shrimp:~$ ip -c address 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 1000 link/ether 7c:d9:5c:b1:fa:cc brd ff:ff:ff:ff:ff:ff 3: wlan0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 3000 link/ether 7c:d9:5c:b1:fa:cd brd ff:ff:ff:ff:ff:ff 4: p2p0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 3000 link/ether 00:0a:f5:89:89:81 brd ff:ff:ff:ff:ff:ff 5: usb0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000 link/ether 02:22:78:0d:f6:df brd ff:ff:ff:ff:ff:ff inet 192.168.100.2/24 brd 192.168.100.255 scope global noprefixroute usb0 valid_lft forever preferred_lft forever inet6 fe80::cc6d:b3d4:f07e:eed1/64 scope link tentative noprefixroute valid_lft forever preferred_lft forever 6: usb1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000 link/ether 02:22:78:0d:f6:de brd ff:ff:ff:ff:ff:ff inet 192.168.101.2/24 brd 192.168.101.255 scope global noprefixroute usb1 valid_lft forever preferred_lft forever inet6 fe80::5bf4:c217:d9c9:859c/64 scope link noprefixroute valid_lft forever preferred_lft forever mendel@mocha-shrimp:~$
After activate the Internet by nmtui, we can
NOW clearly see the wlan0 IP is
automatically allocated.
1 2 3 4 5 6 7 8 9 10 11
mendel@mocha-shrimp:~$ ip -c address ...... 3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 3000 link/ether 7c:d9:5c:b1:fa:cd brd ff:ff:ff:ff:ff:ff inet 192.168.1.110/24 brd 192.168.1.255 scope global dynamic noprefixroute wlan0 valid_lft 86367sec preferred_lft 86367sec inet6 2001:569:7e6e:dc00:d1c4:697a:f60e:b5a4/64 scope global dynamic noprefixroute valid_lft 7468sec preferred_lft 7168sec inet6 fe80::e10b:9dc6:60c4:b91b/64 scope link noprefixroute valid_lft forever preferred_lft forever ......
Of course, we can setup a static IP for this particular Google Coral Dev Board
afterwards.
2.1.5 SSH into Mendel
In order to SSH into Mendel and connect remotely, we
need to do Connect
to a board’s shell on the host computer. You MUST
pushkey before you can ssh into the board via the
Internet IP instead of the virtual IP via USB, say
192.168.100.2 or 192.168.101.2.
1 2
➜ ~ ssh -i ~/.ssh/id_rsa_mendel.pub mendel@192.168.1.97 Connection closed by 192.168.1.97 port 22
However, for now, I've got NO idea why
sshNETVER works for Google Coral Dev Board
any more.
From now on, a huge
modification.
2.2 Flash from U-Boot on an SD
card
If you get unlucky and you can't even boot your board into U-Boot, then you can recover the system by booting into U-Boot from an image on the SD card and then reflash the board from your Linux
(cited from Google
Coral Dev Board's Official Doc). Now, fastboot devices
from host is NOW back.
➜ mendel-enterprise-day-13 mdt shell Waiting for a device... Connecting to green-snail at 192.168.100.2 Key not present on green-snail -- pushing Linux green-snail 4.14.98-imx #1 SMP PREEMPT Fri Nov 8 23:28:21 UTC 2019 aarch64
The programs included with the Mendel GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright.
Mendel GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Mon Nov 11 18:19:48 2019
Run ssh-keygen and pushkey
consequently:
1 2 3 4 5 6 7 8 9 10 11 12 13 14
➜ .ssh ssh-keygen Generating public/private rsa key pair. Enter file in which to save the key (/home/longervision/.ssh/id_rsa): /home/longervision/.ssh/id_rsa_mendel Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in /home/longervision/.ssh/id_rsa_mendel. Your public key has been saved in /home/longervision/.ssh/id_rsa_mendel.pub. The key fingerprint is: ...... ➜ .ssh mdt pushkey ~/.ssh/id_rsa_mendel.pub Waiting for a device... Connecting to green-snail at 192.168.100.2 Pushing /home/longervision/.ssh/id_rsa_mendel.pub Key /home/longervision/.ssh/id_rsa_mendel.pub pushed.
Then, with mdt shell, run command nmtui to
activate wlan0.
mendel@deft-orange:~$ edgetpu_demo --stream Press 'q' to quit. Press 'n' to switch between models.
(edgetpu_detect_server:9991): Gtk-WARNING **: 07:56:57.725: Locale not supported by C library. Using the fallback 'C' locale. INFO:edgetpuvision.streaming.server:Listening on ports tcp: 4665, web: 4664, annexb: 4666 INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:37536 INFO:edgetpuvision.streaming.server:Number of active clients: 1 INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:37538 INFO:edgetpuvision.streaming.server:[192.168.1.200:37536] Rx thread finished INFO:edgetpuvision.streaming.server:[192.168.1.200:37536] Tx thread finished INFO:edgetpuvision.streaming.server:Number of active clients: 2 INFO:edgetpuvision.streaming.server:[192.168.1.200:37536] Stopping... INFO:edgetpuvision.streaming.server:[192.168.1.200:37536] Stopped. INFO:edgetpuvision.streaming.server:Number of active clients: 1 INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:37540 INFO:edgetpuvision.streaming.server:Number of active clients: 2 INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:37542 INFO:edgetpuvision.streaming.server:Number of active clients: 3 INFO:edgetpuvision.streaming.server:[192.168.1.200:37538] Rx thread finished INFO:edgetpuvision.streaming.server:[192.168.1.200:37540] Rx thread finished INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:37544 INFO:edgetpuvision.streaming.server:[192.168.1.200:37538] Tx thread finished INFO:edgetpuvision.streaming.server:[192.168.1.200:37542] Rx thread finished INFO:edgetpuvision.streaming.server:[192.168.1.200:37542] Tx thread finished INFO:edgetpuvision.streaming.server:Number of active clients: 4 ......
mendel@green-snail:~/Downloads/tflite/python/examples/classification$ python3 classify_image.py --model models/mobilenet_v2_1.0_224_inat_bird_quant_edgetpu.tflite --labels models/inat_bird_labels.txt --input images/parrot.jpg ----INFERENCE TIME---- Note: The first inference on Edge TPU is slow because it includes loading the model into Edge TPU memory. 13.5ms 3.5ms 2.7ms 3.0ms 3.0ms -------RESULTS-------- Ara macao (Scarlet Macaw): 0.77734
(edgetpu_detect_server:4081): Gtk-WARNING **: 10:40:45.436: Locale not supported by C library. Using the fallback 'C' locale. INFO:edgetpuvision.streaming.server:Listening on ports tcp: 4665, web: 4664, annexb: 4666 INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:33950 INFO:edgetpuvision.streaming.server:[192.168.1.200:33950] Rx thread finished INFO:edgetpuvision.streaming.server:[192.168.1.200:33950] Tx thread finished INFO:edgetpuvision.streaming.server:Number of active clients: 1 INFO:edgetpuvision.streaming.server:[192.168.1.200:33950] Stopping... INFO:edgetpuvision.streaming.server:[192.168.1.200:33950] Stopped. INFO:edgetpuvision.streaming.server:Number of active clients: 0 INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:33952 INFO:edgetpuvision.streaming.server:Number of active clients: 1 INFO:edgetpuvision.streaming.server:[192.168.1.200:33952] Rx thread finished INFO:edgetpuvision.streaming.server:[192.168.1.200:33952] Tx thread finished INFO:edgetpuvision.streaming.server:New web connection from 192.168.1.200:33954 INFO:edgetpuvision.streaming.server:Number of active clients: 2 INFO:edgetpuvision.streaming.server:[192.168.1.200:33952] Stopping... INFO:edgetpuvision.streaming.server:[192.168.1.200:33954] Rx thread finished INFO:edgetpuvision.streaming.server:[192.168.1.200:33952] Stopped. INFO:edgetpuvision.streaming.server:Number of active clients: 1 ......
2.3.4 Bugs
1 2 3 4 5 6 7 8 9 10 11
mendel@green-snail:~$ edgetpu_demo --stream Press 'q' to quit. Press 'n' to switch between models. Unable to init server: Could not connect: Connection refused
(edgetpu_detect_server:8391): Gtk-WARNING **: 20:18:07.433: Locale not supported by C library. Using the fallback 'C' locale. Unable to init server: Could not connect: Connection refused Unable to init server: Could not connect: Connection refused
(edgetpu_detect_server:8391): Gtk-WARNING **: 20:18:07.473: cannot open display:
1 2 3 4 5 6 7 8 9 10
mendel@green-snail:~/Downloads/edgetpu/test_data$ edgetpu_detect_server --model ./mobilenet_ssd_v2_face_quant_postprocess_edgetpu.tflite Unable to init server: Could not connect: Connection refused
(edgetpu_detect_server:8382): Gtk-WARNING **: 20:16:43.553: Locale not supported by C library. Using the fallback 'C' locale. Unable to init server: Could not connect: Connection refused Unable to init server: Could not connect: Connection refused Unable to init server: Could not connect: Connection refused
(edgetpu_detect_server:8382): Gtk-WARNING **: 20:16:44.967: cannot open display: :0