Unable to run TinyML "Hello World" on Sparkfun Edge

Hi,

Request any advice/suggestion on what I am doing wrong. I am trying to run the ‘hello world’ example on my Sparkfun Edge board as described in Chapter 6 of TnyML book by Pete Warden & Daniel Situnayake. Here is my set up:

  1. laptop: Dell Inspiron 5558 with windows 10 home

  2. Installed Virtual box 6.1 and VM running Ubuntu 20.04.1 and extensions

  3. Attached Sparkfun board with serial basic breakout to a USB port on my laptop

  4. Configured USB port is I communicate with it from Ubuntu VM

  5. I then ran everything as described in the book starting on page 115 as follows:

  6. export DEVICENAME=/dev/ttyUSB0

  7. export BAUD_RATE=921600

  8. Then held down button 14 on the Sparkfun board, reset by pressing RST, and then ran the python program as below.

  9. It prints the ‘Sending Hello’ message, and after sometime it produces the error message as shown. And the same result with many tries. Only difference is once in a while, it sayd received 49 bytes instead of 11 more often

  10. Appreciate any input.

ram@ram-VirtualBox:~/tinyml/tensorflow$ python3 tensorflow/lite/micro/tools/make/downloads/AmbiqSuite-Rel2.2.0/tools/apollo3_scripts/uart_wired_update.py -b $BAUD_RATE $DEVICENAME -r 1 -f main_nonsecure_wire.bin -i 6

Connecting with Corvette over serial port /dev/ttyUSB0…

Sending Hello.

No response for command 0x00000000

received bytes 11

[‘0xdc’, ‘0x68’, ‘0x7’, ‘0x87’, ‘0x88’, ‘0x80’, ‘0x80’, ‘0x83’, ‘0x80’, ‘0x80’, ‘0x80’]

Traceback (most recent call last):

File “tensorflow/lite/micro/tools/make/downloads/AmbiqSuite-Rel2.2.0/tools/apollo3_scripts/uart_wired_update.py”, line 338, in

main()

File “tensorflow/lite/micro/tools/make/downloads/AmbiqSuite-Rel2.2.0/tools/apollo3_scripts/uart_wired_update.py”, line 40, in main

connect_device(ser)

File “tensorflow/lite/micro/tools/make/downloads/AmbiqSuite-Rel2.2.0/tools/apollo3_scripts/uart_wired_update.py”, line 60, in connect_device

response = send_command(hello, 88, ser)

File “tensorflow/lite/micro/tools/make/downloads/AmbiqSuite-Rel2.2.0/tools/apollo3_scripts/uart_wired_update.py”, line 237, in send_command

raise NoResponseError

main.NoResponseError

Cheers

Ram

This might be helpful, I had the same issue.

viewtopic.php?f=153&t=54276

Thx a lot Humiliation (is that really your name :-)). Those suggestions the Colab helped.

But is interesting that I have to do that (what is explained in the Colab page) every time I start my Ubuntu machine and insert the Sparkfun board. In other words, for those trying this for the first time, and face the same issues, here is what worked for me:

  1. Go ahead and install the Linxu drivers as explained in: https://learn.sparkfun.com/tutorials/ho … 40-drivers

  2. Then if you try flashing the board, you will get a NoResponse error like the one I posted above

  3. Then go ahead and do what is suggested in the Colab link that Humiliation posted

  4. Flash again, and this it it will work

  5. At least, I had to do this every time I restart my laptop and insert the board.

RamSastry:
Thx a lot Humiliation (is that really your name :-)). Those suggestions the Colab helped.

But is interesting that I have to do that (what is explained in the Colab page) every time I start my Ubuntu machine and insert the Sparkfun board. In other words, for those trying this for the first time, and face the same issues, here is what worked for me:

  1. Go ahead and install the Linxu drivers as explained in: https://learn.sparkfun.com/tutorials/ho … 40-drivers

  2. Then if you try flashing the board, you will get a NoResponse error like the one I posted above

  3. Then go ahead and do what is suggested in the Colab link that Humiliation posted

  4. Flash again, and this it it will work

  5. At least, I had to do this every time I restart my laptop and insert the board.

Haha, no it’s not my real name.

Yes, I’m having the same issue. I need to re-do the steps every time I boot. Linux seems to always replace this driver with the CH341 one and I can’t find a way to prevent it from doing so.