question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

error while loading shared libraries: libopencv_videoio.so.4.5d

See original GitHub issue

If you had ‘ERROR: Impossible to reset the control’ message, give the DEBUG info displayed

DEBUG:

Ouput of linux-enable-ir-emitter -v -d /dev/videoX configure

configure command output
**I am using video2 for this command**
/usr/lib/linux-enable-ir-emitter/driver/driver-generator: error while loading shared libraries: libopencv_videoio.so.4.5d: cannot open shared object file: No such file or directory
ERROR: The configuration has failed.

Output of v4l2-ctl --list-devices

Integrated Camera: Integrated C (usb-0000:00:14.0-7):
	/dev/video0
	/dev/video1
	/dev/video2
	/dev/video3

Ouput of v4l2-ctl -d /dev/videoX --list-formats-ext

v4l2 device output
**I am using video2 for this command**
ioctl: VIDIOC_ENUM_FMT
	Type: Video Capture

	[0]: 'GREY' (8-bit Greyscale)
		Size: Discrete 360x360
			Interval: Discrete 0.067s (15.000 fps)
		Size: Discrete 640x360
			Interval: Discrete 0.033s (30.000 fps)

Additional info

  • Distro: Ubuntu
  • Version: Focal Fossa (20.04 LTS)
  • Version of linux-enable-ir-emitter: 4.2.1
  • How did you install linux-enable-ir-emitter: PPA

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:13 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
EmixamPPcommented, Aug 4, 2022

From what I understand, I guess that opencv is waiting for access to /dev/video2, which freezes the process. The emitter works because it just found the right driver, but because opencv is stuck, it can’t ask the user if the driver works.

I will manually create the config file for you, in order to bypass test and the file generation. Please create the file /etc/linux-enable-ir-emitter/video2, which exactly contains :

device=/dev/video2
unit=10
selector=6
size=9
control0=1
control1=3
control2=2
control3=0
control4=0
control5=0
control6=0
control7=0
control8=0

Then execute sudo linux-enable-ir-emitter boot enable. After that, everything should work like a charm !

But I don’t understand why opencv works 6 times, but not the 7th time. For many reasons, I would like to use another library than opencv.

1reaction
GeoRCodecommented, Aug 4, 2022

I’m gonna write for you the steps I made in order for you to make conclusions and stuff:

  1. I opened a terminal and installed the bash script using the “For other distro:” steps found in the README.md
  2. I continued by opening a new terminal and wrote sudo linux-enable-ir-emitter configure
  3. It showed me this (as expected):
INFO: Ensure to not use the camera during the execution.
INFO: Warning to do not kill the process !
Is the ir emitter flashing (not just turn on) ? Yes/No ?
  1. I answered ‘no’ to the question
  2. Then it showed me this:
can't get debug descriptor: Resource temporarily unavailable
ERROR: Impossible to reset the control.
INFO: Please keep this debug in case of issue :
DEBUG: unit: 9, selector: 10, control: 0 8 0 187 187 187 187 187
Is the ir emitter flashing (not just turn on) ? Yes/No ?
  1. I continued answering ‘no’ to the question 6 more times
  2. Then, no more questions appeared on console and the emitter actually began to flash
  3. I let it run for 5-6 hours with nothing new on the console log, then killed the process
  4. I searched for anything created on the supposed driver folder (/etc/linux-enable-ir-emitter) but it was empty
  5. I searched in the other folders created by the installation in the whole system but there was nothing new
  6. I tested the camera + emitter using ffplay /dev/video2 and/or sudo howdy test. It worked as intended
  7. I powered off the whole pc. Then I powered on again, went to Windows, on the lock screen I performed a reboot and then I went to Ubuntu
  8. The camera works, the emitter doesn’t

Hopefully this help you understand my process

Read more comments on GitHub >

github_iconTop Results From Across the Web

openCV program compile error "libopencv_core.so.2.4 ...
You haven't put the shared library in a location where the loader can find it. look inside the /usr/local/opencv and /usr/local/opencv2 folders and...
Read more >
"libopencv_core.so.3.2: cannot open shared object file: No ...
After I had compiled and built the lastest OpenCV from source, ... My error: error while loading shared libraries: libopencv_dnn.so.3.4: cannot open shared ......
Read more >
error while loading shared libraries: libopencv_core.so.2.4
error while loading shared libraries: libopencv_core.so.2.4: cannot open shared. i added a file in : /etc/ld.config.so.d/. and named it : opencv.conf.
Read more >
libopencv_core.so.3.1: cannot open shared object file
error while loading shared libraries: libopencv_core.so.3.1: cannot open shared object file: No such file or directory.
Read more >
[Solved] cannot open shared object file Error in Ubuntu
One quick way to fix this “error while loading shared libraries” automatically is to use ldconfig. All you need to do is to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found