WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
Hi,
I just completed my virtual box install on Windows 10. Followed instructions from Espressif for the development environment/toolchain and successfully compiled hello_world (yay!). Now the difficulties start. How to connect the devices. Googled a bunch, but no success.
1. I set up a filter for the FTDI Dual RS232-HS [0700] in the Oracle VM VirtualBox Manager (tried both USB 2.0 and USB 3.0)
2. Start the VirtualBox (Linux Ubuntu 16.04LTS).
3. Plug in the Espressif ESP32 DevKit WRover (v3)
4. Go to the Devices menu entry for my running VirtualBox and try to select one of the FTDI interfaces.
5. No joy. Just a "Failed to attach the USB device FTDI..... to the virtual machine UbuntuBox"
6. The reason stated was that the device is busy with a previous request.
7. I checked the Control Panel..Device Manager in windows 10, and it sees the VirtualBox USB device as active and listed under Universal Serial Bus Controllers.
I decided to abandon my attempts at WSL (Windows Subsystem for Linux) since it couldn't see the JTAG stuff properly. It can only see /dev/ttyS8 etc...
What am I missing for my VirtualBox? It's my understanding that some of the users here have experienced success with this.
GJN
I just completed my virtual box install on Windows 10. Followed instructions from Espressif for the development environment/toolchain and successfully compiled hello_world (yay!). Now the difficulties start. How to connect the devices. Googled a bunch, but no success.
1. I set up a filter for the FTDI Dual RS232-HS [0700] in the Oracle VM VirtualBox Manager (tried both USB 2.0 and USB 3.0)
2. Start the VirtualBox (Linux Ubuntu 16.04LTS).
3. Plug in the Espressif ESP32 DevKit WRover (v3)
4. Go to the Devices menu entry for my running VirtualBox and try to select one of the FTDI interfaces.
5. No joy. Just a "Failed to attach the USB device FTDI..... to the virtual machine UbuntuBox"
6. The reason stated was that the device is busy with a previous request.
7. I checked the Control Panel..Device Manager in windows 10, and it sees the VirtualBox USB device as active and listed under Universal Serial Bus Controllers.
I decided to abandon my attempts at WSL (Windows Subsystem for Linux) since it couldn't see the JTAG stuff properly. It can only see /dev/ttyS8 etc...
What am I missing for my VirtualBox? It's my understanding that some of the users here have experienced success with this.
GJN
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
In your Virtual Box configuration, do NOT try and map the USB through virtual box at the settings. Leave them all blank. When you start Ubuntu in Virtual box, you will see a menu (Virtual Box) called Devices. Within Devices you will find USB and within USB you will find FTDI Dual RS232-HS. Select this entry and you should then find /dev/ttyUSB0 and /dev/ttyUSB1.
Make sure that NOTHING in the Windows host environment is trying to use the USB device.
Make sure that NOTHING in the Windows host environment is trying to use the USB device.
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
Greetings nkolban!
Well. I figured out my woes regarding USB in Ubuntu.
Wireshark, WinPCAP, and USBCap.
Removed them from the system, and a sliver of joy has returned to Delaware (at least my neck of it). Although it is not yet complete.
1. I successfully can flash the SparkFun ESP32 Thing (yayyyy!!!!)
2. I successfully can flash the ESP32-devkitj (yayyyy!!!!)
3. OpenOCD fails because libusb cannot see the USB device (BOOO!!!!)
Now, I'm plugging in the WRover devkit (v3), I do a dmesg | grep -i tty and here's the output, plus the failure. What will I need for openocd???
GJN
Well. I figured out my woes regarding USB in Ubuntu.
Wireshark, WinPCAP, and USBCap.
Removed them from the system, and a sliver of joy has returned to Delaware (at least my neck of it). Although it is not yet complete.
1. I successfully can flash the SparkFun ESP32 Thing (yayyyy!!!!)
2. I successfully can flash the ESP32-devkitj (yayyyy!!!!)
3. OpenOCD fails because libusb cannot see the USB device (BOOO!!!!)
Now, I'm plugging in the WRover devkit (v3), I do a dmesg | grep -i tty and here's the output, plus the failure. What will I need for openocd???
GJN
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
Hi,
I did read Neil's section on setting up the jtag on the WRover dev-kit. Attached is a picture of my setup.
1. I do a make menuconfig and change the flash to /dev/ttyUSB1
2. I plug in the device, use the menu entry 'Device' to capture both USB interfaces in the Virtual Box
3. I dmesg | grep -I tty to see the dump of the connections. Both interfaces for the WRover kit are there
4. I 'sudo chmod 666' both interfaces to give permission to use them.
5. (I am able to successfully build hello_world and flash it to the ttyUSB1 and monitor the messages)
6. I try the sudo bin/openocd method and...no joy I've attached a picture of my board jumper setup.
I'm reaaaaallll close, I think.
Output of some of the above commands
Setup of jumpers (see lower right)
I did read Neil's section on setting up the jtag on the WRover dev-kit. Attached is a picture of my setup.
1. I do a make menuconfig and change the flash to /dev/ttyUSB1
2. I plug in the device, use the menu entry 'Device' to capture both USB interfaces in the Virtual Box
3. I dmesg | grep -I tty to see the dump of the connections. Both interfaces for the WRover kit are there
4. I 'sudo chmod 666' both interfaces to give permission to use them.
5. (I am able to successfully build hello_world and flash it to the ttyUSB1 and monitor the messages)
6. I try the sudo bin/openocd method and...no joy I've attached a picture of my board jumper setup.
I'm reaaaaallll close, I think.
Output of some of the above commands
Setup of jumpers (see lower right)
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
In my environment, I am running Windows 10, Virtual Box, Ubuntu. I do all my development in Ubuntu ... so we seem similar/same there. I am running a WROVER-DevKit ... just like you. One distinction is that I do NOT have a jumper on the S_TDI pin which your picture shows you do ... otherwise jumpers are same.
I startup open-ocd ... it starts and pauses at the end. I then open up gdb using the "recipe" and it all "just works".
Try with the S_TDI jumper removed. If no improvements occur, we can try and find a mutual time to do a screen share and/or I'll go through my recipe slowly and maybe create a video.
Consider also a deep study here:
https://github.com/espressif/openocd-esp32
This is the home page for the openocd project for ESP32. Search through the issues (open and closed) and see if one comes close. If not, maybe translate your post into a Github issue. That way the owners of the repository may be able to assist and other users may get some love if they find other users with same puzzles.
I startup open-ocd ... it starts and pauses at the end. I then open up gdb using the "recipe" and it all "just works".
Try with the S_TDI jumper removed. If no improvements occur, we can try and find a mutual time to do a screen share and/or I'll go through my recipe slowly and maybe create a video.
Consider also a deep study here:
https://github.com/espressif/openocd-esp32
This is the home page for the openocd project for ESP32. Search through the issues (open and closed) and see if one comes close. If not, maybe translate your post into a Github issue. That way the owners of the repository may be able to assist and other users may get some love if they find other users with same puzzles.
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
Well...
Thank you Neil for the hour of your life you and I spent trying to figure this one out. For the rest of us on the forum, here's what we did to try to figure the problem out.
1. Made sure we had identical installs of xtensa-esp32-elf and esp-idf
2. Made sure ttyUSB0 and ttyUSB1 were connected with proper permissions
3. Verified we had the same experimenter boards installed
4. Tried same Linux Virtual Box OS (I had Ubuntu 16.04LTS but ended up installing Ubuntu 17.10, and still didn't work)
All in all, apart from the computer, we had identical setups. Yikes. Didn't work! I will install the Ubuntu platform on my more hopped up laptop and see if the computer makes a difference. The current machine I'm using is a Surface Pro 2017 I7 256G 8Gram.
Bummed! But thanks again to Neil and his willingness to help a newbie.
Thank you Neil for the hour of your life you and I spent trying to figure this one out. For the rest of us on the forum, here's what we did to try to figure the problem out.
1. Made sure we had identical installs of xtensa-esp32-elf and esp-idf
2. Made sure ttyUSB0 and ttyUSB1 were connected with proper permissions
3. Verified we had the same experimenter boards installed
4. Tried same Linux Virtual Box OS (I had Ubuntu 16.04LTS but ended up installing Ubuntu 17.10, and still didn't work)
All in all, apart from the computer, we had identical setups. Yikes. Didn't work! I will install the Ubuntu platform on my more hopped up laptop and see if the computer makes a difference. The current machine I'm using is a Surface Pro 2017 I7 256G 8Gram.
Bummed! But thanks again to Neil and his willingness to help a newbie.
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
Well... The problem is the same. Error: JTAG scan chain interrogation failed: all ones
Did complete install on a separate machine. Below is the history list of all the commands I executed on a fresh Ubuntu VirtualBox using 16.04LTS.
The errors I'm getting are identical, and the only USB device I have hooked up is the WRover dev kit. Where am I going wrong???
The only change I make in make menuconfig is the flash port. I set that to /dev/ttyUSB1
This is now happening on two separate Windows 10 machines. One is a SurfacePro 2017 I7 and the other is an ASUS laptop I7. Plenty of memory on each. What's going on???
My Recipe for Ubuntu 16.04LTS espressif toolchain build
My ~/.profile
Did complete install on a separate machine. Below is the history list of all the commands I executed on a fresh Ubuntu VirtualBox using 16.04LTS.
The errors I'm getting are identical, and the only USB device I have hooked up is the WRover dev kit. Where am I going wrong???
The only change I make in make menuconfig is the flash port. I set that to /dev/ttyUSB1
This is now happening on two separate Windows 10 machines. One is a SurfacePro 2017 I7 and the other is an ASUS laptop I7. Plenty of memory on each. What's going on???
My Recipe for Ubuntu 16.04LTS espressif toolchain build
Code: Select all
1 sudo apt-get update
2 mkdir esp
3 ls
4 cd esp
5 wget https://dl.espressif.com/dl/xtensa-esp32-elf-linux64-1.22.0-80-g6c4433a-5.2.0.tar.gz
6 tar -xzf xtensa-esp32-elf-linux64-1.22.0-80-g6c4433a-5.2.0.tar.gz
7 rm xtensa-esp32-elf-linux64-1.22.0-80-g6c4433a-5.2.0.tar.gz
8 ls
10 cd ~
11 sudo nano .profile
12 export PATH=~/esp/xtensa-esp32-elf/bin:$PATH
13 export IDF_PATH=~/esp/esp-idf
14 cd esp
15 sudo apt-get install git wget make libncurses-dev flex bison gperf python python-serial
16 git clone --recursive https://github.com/espressif/esp-idf
18 cp -r esp-idf/examples/get-started/hello_world .
21 cd hello_world
22 make menuconfig
23 make -j5
24 dmesg | grep -i tty
25 nano main/main.c
26 nano main/hello_world_main.c
27 make
29 sudo chmod 666 /dev/ttyUSB0
30 sudo chmod 666 /dev/ttyUSB1
31 sudo usermod -a -G dialout gnorkus
33 make flash
34 cd ~/esp
35 wget https://dl.espressif.com/dl/openocd-esp32-linux64-07baed8.tar.gz
36 tar -xzf openocd-esp32-linux64-07baed8.tar.gz
37 cd openocd-esp32
38 sudo bin/openocd -s share/openocd/scripts -f interface/ftdi/esp32_devkitj_v1.cfg -f board/esp32-wrover.cfg
Code: Select all
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
# set PATH so it includes user's private bin directories
PATH="$HOME/bin:$HOME/.local/bin:$PATH"
export PATH=~/esp/xtensa-esp32-elf/bin:$PATH
export IDF_PATH=~/esp/esp-idf
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
You showed me yours, here's mine:
I can't tell you what "version" mine is ... but I notice at least one "spot the difference". In your picture you have a "don't touch" and "no led" on the silk screen while mine doesn't. I can't imagine that would have been removed, so I'm going to guess your board is newer than mine.
I can't tell you what "version" mine is ... but I notice at least one "spot the difference". In your picture you have a "don't touch" and "no led" on the silk screen while mine doesn't. I can't imagine that would have been removed, so I'm going to guess your board is newer than mine.
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
SOLVED
And I wish that Espressif would pay me the roughly $2k of time it took to figure it out, but I'd settle if they shipped me 100 of the WRover modules. Neil, they owe you too!!!
It turns out I had a defective board. There was a ground short UNDERNEATH the ESP32-WRover module. How was this determined...
1. Figured it might be a problem with the jtag pins, so ground to pin continuity was checked on the TMS TDO TDK and TCK pins of J8 (the pins closer to the inside of the board). Continuity was detected at TCK pin. 0.4 ohms.
2. Removed R50. It was indeed a 10k 0402 resistor as per schematic. Checked both of the pads for continuity to ground, and both were grounding.
3. Traced line back to IO13 on the WRover module. Determined that it's neighboring pin was a ground pin, so removed R37. Once removed, only one of the R50 pads was now having continuity to ground.
4. Removed WRover Module from board using hot air rework tool. Discovered this board was actually designed to use WRoom or WRover, and that a couple of the pads for the WRoom were shorted by a solder blob. Those pads connected to ground and IO13 on the WRover module.
5. Soldered on new WRover module. Joy again in ESP32 land.
6. Will never take for granted that the factory did their QA inspection.
And I wish that Espressif would pay me the roughly $2k of time it took to figure it out, but I'd settle if they shipped me 100 of the WRover modules. Neil, they owe you too!!!
It turns out I had a defective board. There was a ground short UNDERNEATH the ESP32-WRover module. How was this determined...
1. Figured it might be a problem with the jtag pins, so ground to pin continuity was checked on the TMS TDO TDK and TCK pins of J8 (the pins closer to the inside of the board). Continuity was detected at TCK pin. 0.4 ohms.
2. Removed R50. It was indeed a 10k 0402 resistor as per schematic. Checked both of the pads for continuity to ground, and both were grounding.
3. Traced line back to IO13 on the WRover module. Determined that it's neighboring pin was a ground pin, so removed R37. Once removed, only one of the R50 pads was now having continuity to ground.
4. Removed WRover Module from board using hot air rework tool. Discovered this board was actually designed to use WRoom or WRover, and that a couple of the pads for the WRoom were shorted by a solder blob. Those pads connected to ground and IO13 on the WRover module.
5. Soldered on new WRover module. Joy again in ESP32 land.
6. Will never take for granted that the factory did their QA inspection.
Re: WRover-Kit Attach to Ubuntu 16.04LTS VirtualBox
Just kidding about the fee...but it still would be nice if they sent out prizes...
Who is online
Users browsing this forum: No registered users and 194 guests