LIBUSB_ERROR_TIMEOUT

I’m trying to connect my TX1 to a Basler Ace USB3 Camera but getting the following error/traceback:

ubuntu@tegra-ubuntu:~/Downloads/PylonSample_gstreamer$ ./Grab
15.06.2017 19:37:51.813243 Unable to ensure stalled pipe 1, status=0xe2100007 LIBUSB_ERROR_TIMEOUT
15.06.2017 19:37:51.814441 Failed to stall control channel pipe 0, status=0xE2100007
Camera Information:
  Model: acA1920-155um
15.06.2017 19:37:54.955355 Unable to ensure stalled pipe 1, status=0xe2100007 LIBUSB_ERROR_TIMEOUT
15.06.2017 19:37:54.955400 Failed to stall control channel pipe 0, status=0xE2100007
Segmentation fault

Any ideas on how to resolve this?

My L4T uses kernel version 4.4.15

The code I was running is below and was built on another TX1 and was presumably functional with this camera:

// Basic example of using Basler daA1280-54uc color usb3 camera and Pylon drivers/API with GStreamer <matt.breit@baslerweb.com> (2017).
// Partially based on public domain code by Florian Echtler <floe@butterbrot.org> (2015).

#include <pylon/PylonIncludes.h>
#include <pylon/usb/BaslerUsbInstantCamera.h>
#include <gst/gst.h>
#include <gst/app/gstappsrc.h>
#include <stdio.h>

#include <iostream>
#include <sstream>

#include <stdint.h>
#include <stdlib.h>

#include <time.h>
#include <signal.h>

#define WIDTH 1280
#define HEIGHT 960
#define FRAMERATE 50

#define NUM_FRAMES_TO_CAPTURE 100
#define TARGET_BITRATE 10000000

using namespace Pylon;
using namespace GenApi;
using namespace std;

class BaslerAppSrc {
public:
	BaslerAppSrc(int w, int h, int numFrames) :
		captureWidth(w), captureHeight(h), numFramesToCapture(numFrames),
		imageSize(0)
	{Pylon::PylonInitialize();}
	~BaslerAppSrc(void) {Pylon::PylonTerminate();}

	int factory_make();
	int pipeline_make();
	int watcher_make();

	bool OpenCamera(void);
	bool grabFrame(Pylon::CPylonImage *image);
	int getFrameSize() { return imageSize;}

private:
	int captureWidth;
	int captureHeight;
	int numFramesToCapture;

	GstElement *source;
	GstElement *filter1;
	GstElement *convert;
	GstElement *accel;
	GstElement *encoder;
	GstElement *filter2;
	GstElement *queue;
	GstElement *parser;
	GstElement *muxer;
	GstElement *sink;

	GstCaps *filter1_caps;
	GstCaps *filter2_caps;

	GstBus *bus;

	guint bus_watch_id;

	Pylon::CBaslerUsbInstantCamera camera;
	
	int imageSize;
};

static GMainLoop *loop;
GstElement *pipeline;

static void sigint_restore(void)
{
	struct sigaction action;

	memset(&action, 0, sizeof(action));
	action.sa_handler = SIG_DFL;

	sigaction(SIGINT, &action, NULL);
}

/* Signal handler for ctrl+c */
void intHandler(int dummy) {
	//! Emit the EOS signal which tells all the elements to shut down properly:
	printf("Sending EOS signal to shutdown pipeline cleanly\n");
	gst_element_send_event(pipeline, gst_event_new_eos());
	sigint_restore();
	return;
}

static gboolean bus_call(GstBus     *bus,
	GstMessage *msg,
	gpointer    data)
{
	GMainLoop *loop = (GMainLoop *)data;

	switch (GST_MESSAGE_TYPE(msg)) {

	case GST_MESSAGE_EOS:
		g_print("End of stream\n");
		g_main_loop_quit(loop);
		break;

	case GST_MESSAGE_ERROR: {
		gchar  *debug;
		GError *error;

		gst_message_parse_error(msg, &error, &debug);
		g_free(debug);

		g_printerr("Error: %s\n", error->message);
		g_error_free(error);

		g_main_loop_quit(loop);
		break;
	}

	default:
		break;
	}

	return TRUE;
}

double ms_time(void)
{
	struct timespec now_timespec;
	clock_gettime(CLOCK_MONOTONIC, &now_timespec);
	return ((double)now_timespec.tv_sec)*1000.0 + ((double)now_timespec.tv_nsec)*1.0e-6;
}

bool BaslerAppSrc::grabFrame(Pylon::CPylonImage *image)
{
	Pylon::CGrabResultPtr ptrGrabResult;

	bool success = camera.RetrieveResult(5000, ptrGrabResult, Pylon::ETimeoutHandling::TimeoutHandling_ThrowException);	

	if (ptrGrabResult->GrabSucceeded())
	{		
		image->AttachGrabResultBuffer(ptrGrabResult);
	}
	else
	{		
		printf("Failed to capture image from Camera!\n");
		return false;
	}
	return true;
}

static void cb_need_data(GstElement *appsrc, guint unused_size, gpointer user_data) {

	BaslerAppSrc *app = (BaslerAppSrc*)user_data;
	static gboolean white = FALSE;
	static double last_cap_time = ms_time();
	static double frame_rate_avg = 30.0;
	static double frame_dt_ms = 33.0;
	static double last_frameRate_count_time = ms_time() - 1001.0;
	static int last_frameCount = 0;
	static int frameCount = 0;
	static bool once = false;
	GstBuffer *buffer;
	guint size;
	GstFlowReturn ret;

	double cap_time = ms_time();

	Pylon::CPylonImage image;
	
	if (!app->grabFrame(&image)) {
		printf("Failed to grab!\n");
		return;
	}

	int imageSize = app->getFrameSize();
	
	buffer = gst_buffer_new_wrapped_full(
		(GstMemoryFlags) GST_MEMORY_FLAG_PHYSICALLY_CONTIGUOUS,
		(gpointer)image.GetBuffer(),
		imageSize,
		0,
		imageSize,
		NULL,
		NULL);
	
	g_signal_emit_by_name(appsrc, "push-buffer", buffer, &ret);

	if (!once) {
		once = true;
	}
	else {
		frame_dt_ms = cap_time - last_cap_time;
		if (cap_time - last_frameRate_count_time > 1000.0) {
			int framesInOneSecond = frameCount - last_frameCount;
			last_frameRate_count_time = cap_time;
			last_frameCount = frameCount;
		}
	}

	last_cap_time = cap_time;
	frameCount++;
	
}

bool BaslerAppSrc::OpenCamera(void) {
	
	camera.Attach(Pylon::CTlFactory::GetInstance().CreateFirstDevice());
	
	printf("Camera Information:\n");
	printf("  Model: %s\n", camera.GetDeviceInfo().GetModelName().c_str());

	camera.Open();

	// setup the camera
	camera.Width.SetValue(WIDTH);
	camera.Height.SetValue(HEIGHT);
	camera.AcquisitionFrameRate.SetValue(FRAMERATE);
	camera.PixelFormat.FromString("RGB8"); // RGB8 means we do 5x5 bayer interpolation and color correction inside the camera (PGI)!
	
	// tuning transmision and driver for high-bandwidth stability
	camera.GetStreamGrabberParams().MaxTransferSize.SetValue(camera.GetStreamGrabberParams().MaxBufferSize.GetValue());
	camera.GetStreamGrabberParams().NumMaxQueuedUrbs.SetValue(100);	
	
	imageSize = camera.PayloadSize.GetValue();

	camera.StartGrabbing(Pylon::EGrabStrategy::GrabStrategy_LatestImageOnly);

	return true;
}

int BaslerAppSrc::factory_make()
{
	/* Create gstreamer elements */
	pipeline = gst_pipeline_new("pipeline");
	source = gst_element_factory_make("appsrc", "source");
	filter1 = gst_element_factory_make("capsfilter", "filter1");
	convert = gst_element_factory_make("videoconvert", "conv");
	encoder = gst_element_factory_make("omxh264enc", "dmaienc_h264");
	filter2 = gst_element_factory_make("capsfilter", "filter2");
	parser = gst_element_factory_make("h264parse", "parser");
	muxer = gst_element_factory_make("qtmux", "mux");
	sink = gst_element_factory_make("filesink", "filesink");
		
	//! setup
	g_object_set(G_OBJECT(source), "caps",
		gst_caps_new_simple("video/x-raw",
		"format", G_TYPE_STRING, "RGB",
		"width", G_TYPE_INT, WIDTH,
		"height", G_TYPE_INT, HEIGHT,
		"framerate", GST_TYPE_FRACTION, FRAMERATE, 1,
		NULL), NULL);

	/* Video caps */
	filter1_caps = gst_caps_new_simple("video/x-raw",
		"format", G_TYPE_STRING, "RGB",
		"width", G_TYPE_INT, WIDTH,
		"height", G_TYPE_INT, HEIGHT,
		NULL);

	filter2_caps = gst_caps_new_simple("video/x-h264",
		"stream-format", G_TYPE_STRING, "byte-stream",
		NULL);

	/* Set up elements */
	g_object_set(G_OBJECT(filter1), "caps", filter1_caps, NULL);
	g_object_set(G_OBJECT(filter2), "caps", filter2_caps, NULL);
	gst_caps_unref(filter1_caps);
	gst_caps_unref(filter2_caps);
	g_object_set(G_OBJECT(source), "num-buffers", NUM_FRAMES_TO_CAPTURE, NULL);
	g_object_set(G_OBJECT(encoder), "bitrate", TARGET_BITRATE, NULL);

	/* we set the input filename to the source element */
	g_object_set(G_OBJECT(sink), "location", "video.h264", NULL);

	/* setup appsrc */
	g_object_set(G_OBJECT(source),
		"stream-type", GST_APP_STREAM_TYPE_STREAM,
		"format", GST_FORMAT_TIME,
		"is-live", TRUE,
		"do-timestamp", TRUE,
		NULL);
	g_signal_connect(source, "need-data", G_CALLBACK(cb_need_data), this);
	printf("Factory made\n");
	return 0;
}

int BaslerAppSrc::pipeline_make()
{
	/* we add all elements into the pipeline */
	gst_bin_add_many(GST_BIN(pipeline),source, filter1, convert, encoder, filter2, parser, muxer, sink, NULL);
	/* we link the elements together */
	gst_element_link_many(source, filter1, convert, encoder, filter2, parser, muxer, sink, NULL);
	printf("pipeline made\n");
	return 0;
}

int BaslerAppSrc::watcher_make()
{
	/* we add a message handler */
	bus = gst_pipeline_get_bus(GST_PIPELINE(pipeline));
	bus_watch_id = gst_bus_add_watch(bus, bus_call, loop);
	gst_object_unref(bus);
	printf("watcher made\n");
	return 0;
}

gint main(gint argc, gchar *argv[]) {

try
{
	signal(SIGINT, intHandler);

	BaslerAppSrc app(WIDTH, HEIGHT, NUM_FRAMES_TO_CAPTURE);

	if (!app.OpenCamera()) {
		return -1;
	}

	/* init GStreamer */
	gst_init(&argc, &argv);

	loop = g_main_loop_new(NULL, FALSE);
	
	/* Initialize elements */
	if (app.factory_make() != 0)
		return -1;

	/* Add function to watch bus */
	if (app.watcher_make() != 0)
		return -1;

	/* Add elements to pipeline, and link them */
	if (app.pipeline_make() != 0)
		return -1;

	/* play */
	printf("Playing\n");
	gst_element_set_state(pipeline, GST_STATE_PLAYING);
	
	g_main_loop_run(loop);

	/* clean up */
	gst_element_set_state(pipeline, GST_STATE_NULL);
	gst_object_unref(GST_OBJECT(pipeline));
	g_main_loop_unref(loop);
	
}
catch (GenICam::GenericException &e)
{
	//e.GetDescription();

}
catch (std::exception &e)
{
	//e.what();
}
	return 0;
}

The Makefile:

# Makefile for Basler pylon sample program
.PHONY: all clean

# The program to build
NAME       := Grab

# Installation directories for pylon
PYLON_ROOT ?= /opt/pylon5
DIR ?= /usr/include

# Build tools and flags
LD         := $(CXX)
CPPFLAGS   := $(shell pkg-config --cflags gstreamer-1.0 gstreamer-app-1.0) $(shell $(PYLON_ROOT)/bin/pylon-config --cflags) -std=c++11
CXXFLAGS   := #e.g., CXXFLAGS=-g -O0 for debugging
LDFLAGS    := $(shell $(PYLON_ROOT)/bin/pylon-config --libs-rpath) 
LDLIBS     := $(shell pkg-config --libs gstreamer-1.0 gstreamer-app-1.0) $(shell $(PYLON_ROOT)/bin/pylon-config --libs)

# Rules for building
all: $(NAME)

$(NAME): $(NAME).o
	$(LD) $(LDFLAGS) -o $@ $^ $(LDLIBS)

$(NAME).o: $(NAME).cpp
	$(CXX) $(CPPFLAGS) $(CXXFLAGS) -c -o $@ $<

clean:
	$(RM) $(NAME).o $(NAME)

Not sure at all it is related, but you may try to disable usb autosuspend at boot time by adding:

usbcore.autosuspend=-1

in your /boot/extlinux/extlinux.conf and reboot to see if it gets better or not.

Disabling autosuspend resolved the first set of errors, leaving:

Camera Information:
  Model: acA1920-155um
19.06.2017 20:24:41.502693 Unable to ensure stalled pipe 1, status=0xe2100007 LIBUSB_ERROR_TIMEOUT
19.06.2017 20:24:41.503840 Failed to stall control channel pipe 0, status=0xE2100007
Segmentation fault

Do you see kernel errors about usb ?

sudo dmesg | grep usb

or in another shell you may launch

sudo dmesg --follow

and you can see errors as happening if any while you run your application.

I get the following grep output at bootup with no additional messages after I attempt to run the camera code:

ubuntu@tegra-ubuntu:~$ sudo dmesg | grep usb
[sudo] password for ubuntu: 
[    0.000000] Kernel command line: fbcon=map:0 console=tty0 console=ttyS0,115200n8 androidboot.modem=none androidboot.serialno=P2180A00P00940c003fd androidboot.security=non-secure tegraid=21.1.2.0.0 ddr_die=2048M@2048M ddr_die=2048M@4096M section=256M memtype=0 usb_port_owner_info=0 lane_owner_info=0 emc_max_dvfs=0 touch_id=0@63 video=tegrafb no_console_suspend=1 debug_uartport=lsport,0 earlyprintk=uart8250-32bit,0x70006000 maxcpus=4 usbcore.old_scheme_first=1 lp0_vec=0x1000@0xff2bf000 nvdumper_reserved=0xff23f000 core_edp_mv=1125 core_edp_ma=4000 gpt android.kerneltype=normal androidboot.touch_vendor_id=0 androidboot.touch_panel_id=63 androidboot.touch_feature=0 androidboot.bootreason=pmc:software_reset,pmic:0x0 net.ifnames=0 root=/dev/mmcblk0p1 rw rootwait usbcore.usbfs_memory_mb=1000 usbcore.autosuspend=-1
[    0.775274] usbcore: registered new interface driver usbfs
[    0.780621] usbcore: registered new interface driver hub
[    0.785939] usbcore: registered new device driver usb
[    1.161861] usb-vbus1: 5000 mV ; Rail OFF
[    1.165707] usb-vbus1: supplied by vdd-3v3
[    1.169923] usb-vbus3: 5000 mV ; Rail OFF
[    1.173791] usb-vbus3: supplied by vdd-3v3
[    1.214445] en-usb-vbus2: ; Rail OFF
[    1.450343] tegra_xusb_padctl_phy_enable: init pex uphy pll
[    2.959134] usbcore: registered new interface driver r8152
[    2.959168] usbcore: registered new interface driver asix
[    2.959191] usbcore: registered new interface driver ax88179_178a
[    2.959214] usbcore: registered new interface driver cdc_ether
[    2.959243] usbcore: registered new interface driver smsc95xx
[    2.959266] usbcore: registered new interface driver net1080
[    2.959297] usbcore: registered new interface driver cdc_subset
[    2.959319] usbcore: registered new interface driver zaurus
[    2.959359] usbcore: registered new interface driver cdc_ncm
[    2.959834] tegra_xusb_read_usb_calib: usb_calib0 = 0x0aa87413
[    2.961859] tegra-xhci tegra-xhci: Firmware File: tegra21x_xusb_firmware (124416 Bytes)
[    2.962560] usbcore: registered new interface driver cdc_acm
[    2.962585] usbcore: registered new interface driver cdc_wdm
[    2.962620] usbcore: registered new interface driver usb-storage
[    2.962702] usbcore: registered new interface driver usbserial
[    2.962724] usbcore: registered new interface driver ftdi_sio
[    2.962746] usbserial: USB Serial support registered for FTDI USB Serial Device
[    2.962767] usbcore: registered new interface driver option
[    2.962784] usbserial: USB Serial support registered for GSM modem (1-port)
[    2.962804] usbcore: registered new interface driver pl2303
[    2.962821] usbserial: USB Serial support registered for pl2303
[    2.962844] usbcore: registered new interface driver nvshieldled
[    2.965091] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    2.965097] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    2.965101] usb usb1: Product: Nvidia xHCI Host Controller
[    2.965105] usb usb1: Manufacturer: Linux 3.10.96-tegra tegra-xhci
[    2.965109] usb usb1: SerialNumber: tegra-xhci
[    2.967936] regulator_get() failed for (tegra-udc.0,usb_bat_chg), -19
[    2.967942] tegra-udc tegra-udc.0: usb_bat_chg regulator not registered: USB charging will not be enabled
[    2.968341] usbcore: registered new interface driver xpad
[    2.968394] usbcore: registered new interface driver usb_acecad
[    2.968423] usbcore: registered new interface driver aiptek
[    2.968446] usbcore: registered new interface driver gtco
[    2.968471] usbcore: registered new interface driver hanwang
[    2.968500] usbcore: registered new interface driver kbtab
[    2.968525] usbcore: registered new interface driver wacom
[    3.028055] regulator_get() failed for (tegra-ehci.0,usb_vbus), -19
[    3.028057] usb_phy: failed regulator_get vdd_vbus_usb:-19, inst:0
[    3.057435] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003
[    3.057440] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    3.057444] usb usb2: Product: Nvidia xHCI Host Controller
[    3.057448] usb usb2: Manufacturer: Linux 3.10.96-tegra tegra-xhci
[    3.057451] usb usb2: SerialNumber: tegra-xhci
[    3.402589] usb 2-1: new SuperSpeed USB device number 2 using tegra-xhci
[    3.500267] usb 2-1: New USB device found, idVendor=0955, idProduct=09ff
[    3.500274] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=6
[    3.500279] usb 2-1: Product: USB 10/100/1000 LAN
[    3.500283] usb 2-1: Manufacturer: Nvidia
[    3.500286] usb 2-1: SerialNumber: 000001000000
[    3.701283] usb 2-1: reset SuperSpeed USB device number 2 using tegra-xhci
[    3.928865] usb 2-2: new SuperSpeed USB device number 3 using tegra-xhci
[    4.053992] usb 2-2: New USB device found, idVendor=2676, idProduct=ba02
[    4.053997] usb 2-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[    4.054001] usb 2-2: Product: acA1920-155um
[    4.054005] usb 2-2: Manufacturer: Basler
[    4.054009] usb 2-2: SerialNumber: 21644912
[    4.067368] usb usb3: New USB device found, idVendor=1d6b, idProduct=0002
[    4.067373] usb usb3: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    4.067377] usb usb3: Product: Tegra EHCI Host Controller
[    4.067381] usb usb3: Manufacturer: Linux 3.10.96-tegra ehci_hcd
[    4.067385] usb usb3: SerialNumber: tegra-ehci.0
[    4.927725] usbcore: registered new interface driver uvcvideo
[    5.757338] usb 3-1: new high-speed USB device number 2 using tegra-ehci
[    5.812652] usb 3-1: New USB device found, idVendor=2109, idProduct=2811
[    5.825282] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[    5.836319] usb 3-1: Product: USB2.0 Hub             
[    5.856543] usb 3-1: Manufacturer: VIA Labs, Inc.         
[    5.902026] usbcore: registered new interface driver usbhid
[    5.902028] usbhid: USB HID core driver
[    6.371677] usbcore: registered new interface driver snd-usb-audio
[    7.914915] usb-vbus3: disabling
[   10.987903] usb 3-1.1: new low-speed USB device number 3 using tegra-ehci
[   11.021674] usb 3-1.1: New USB device found, idVendor=0461, idProduct=4d22
[   11.021685] usb 3-1.1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[   11.021691] usb 3-1.1: Product: USB Optical Mouse
[   11.024537] input: USB Optical Mouse as /devices/tegra-ehci.0/usb3/3-1/3-1.1/3-1.1:1.0/input/input2
[   11.024737] hid-generic 0003:0461:4D22.0001: input,hidraw0: USB HID v1.11 Mouse [USB Optical Mouse] on usb-tegra-ehci.0-1.1/input0
[   11.118144] usb 3-1.2: new high-speed USB device number 4 using tegra-ehci
[   11.160687] usb 3-1.2: New USB device found, idVendor=0718, idProduct=0619
[   11.160692] usb 3-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[   11.160696] usb 3-1.2: Product: Nano Pro
[   11.160698] usb 3-1.2: Manufacturer: Imation
[   11.160701] usb 3-1.2: SerialNumber: 0703348FB4EC8E54
[   11.163611] usb-storage 3-1.2:1.0: USB Mass Storage device detected
[   11.168661] scsi0 : usb-storage 3-1.2:1.0
[   11.257982] usb 3-1.4: new full-speed USB device number 5 using tegra-ehci
[   11.306930] usb 3-1.4: New USB device found, idVendor=413c, idProduct=2101
[   11.306940] usb 3-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[   11.306946] usb 3-1.4: Product: Dell Smart Card Reader Keyboard
[   11.306951] usb 3-1.4: Manufacturer: Dell
[   11.311359] input: Dell Dell Smart Card Reader Keyboard as /devices/tegra-ehci.0/usb3/3-1/3-1.4/3-1.4:1.0/input/input3
[   11.311689] hid-generic 0003:413C:2101.0002: input,hidraw1: USB HID v1.11 Keyboard [Dell Dell Smart Card Reader Keyboard] on usb-tegra-ehci.0-1.4/input0

I don’t know if any of these messages are errors…

I cannot tell much more. Someone with deeper knowledge about USB messages may comment. You may also post the output of:

lsusb
lsusb -t

I would just advise if not yet done to boost your Jetson with:

sudo nvpmodel -m0
sudo /home/ubuntu/jetson_clocks.sh

Furthermore, are you running a Jetson or Shield ?
For Jetson, you may also try to plug other USB devices to USB2 micro-USB port for plugging directly your camera alone (no hub) into USB3 port. USB2 may be slow for your mass storage, of course, swapping there would be weird.

I have a Jetson TX1 and I only have the camera plugged into the USB3 port. Thanks for looking at this and if you think of anything else, let me know.

ubuntu@tegra-ubuntu:~$ lsusb
Bus 003 Device 005: ID 413c:2101 Dell Computer Corp. SmartCard Reader Keyboard
Bus 003 Device 006: ID 0718:0619 Imation Corp. 
Bus 003 Device 003: ID 0461:4d22 Primax Electronics, Ltd 
Bus 003 Device 002: ID 2109:2811 VIA Labs, Inc. Hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 004: ID 2676:ba02 Basler AG ace
Bus 002 Device 002: ID 0955:09ff NVidia Corp. 
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
ubuntu@tegra-ubuntu:~$ lsusb -t
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=tegra-ehci/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/4p, 480M
        |__ Port 1: Dev 3, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 2: Dev 6, If 0, Class=Mass Storage, Driver=usb-storage, 480M
        |__ Port 4: Dev 5, If 0, Class=Human Interface Device, Driver=usbhid, 12M
        |__ Port 4: Dev 5, If 1, Class=Chip/SmartCard, Driver=, 12M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=tegra-xhci/4p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Vendor Specific Class, Driver=r8152, 5000M
    |__ Port 2: Dev 4, If 0, Class=Miscellaneous Device, Driver=, 5000M
    |__ Port 2: Dev 4, If 1, Class=Miscellaneous Device, Driver=, 5000M
    |__ Port 2: Dev 4, If 2, Class=Miscellaneous Device, Driver=, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=tegra-xhci/5p, 480M

You could try an externally powered USB3 HUB…if it is a power issue, then the HUB may fix the issue (or at least change the issue).

Hi Dan,

Any update on this ? Power issue as mentionned by @linuxdev would have been my last easy suggestion.

However, the error may be in a driver/service or library. I have no experience in Pylon nor in Basler devices, but if you have sources you may try to debug these and find out why you get these LIBUSB_ERROR_TIMEOUT. Maybe running your app through strace or looking at symbols with objdump may help to locate where it comes from if it’s from a library.

Furthermore, probably my last though, USB is hotplug. Does it change if you unplug/replug your camera before trying your app ?