-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rs2_get_optoin(options:0xad811f08, option:Exposure): get_xu(id=3) failed last error: resource temporarily unavailable #7861
Comments
Hi @mbobinger All of the reset methods that you referenced (hardware_reset, USB port reset and computer reboot) are valid. There are some circumstances though where a hardware_reset or USB port reset do not correct a problem. So a computer reboot like the one in your script above is a dependable method of recovery from unforseen problems that might manifest. It may be worth testing though whether a hardware_reset of the camera only instead of a full reboot of the Pi can provide a level of reliability that is satisfactory to you. This could be done by adding exception handling to your script that initiates hardware_reset if an error in general is detected (not a specific error). The Python wrapper example script python-tutorial-1-depth.py linked to below has an example of error handling code. |
@MartyG-RealSense thank you for your reply. Upon start we run a mystartupscript.desktop file in /home/pi/.config/autostart with a simple command line:
For troubleshooting, I'd like to generate a logfile for the .desktop script. Is there anything else I can log in the actual counter.py file where all the processing and streaming of the intelrealsense happens? Thank you! |
Assuming that you are using ordinary Python for your counter.py script and not running it within the RealSense pyrealsense2 wrapper, the official Python documentation for logfile creation may be helpful: https://docs.python.org/3/howto/logging.html#logging-to-a-file If you have the camera plugged into a USB hub then I would recommend trying to boot the Pi with the camera plugged directly into the Pi's USB port if you have a vacant port available, as USB hubs may sometimes cause power-related issues for a RealSense camera during boot-up. |
Hi @mbobinger Do you require further assistance with this case, please? Thanks! |
@MartyG-RealSense thank you marty all good for now, the hardware reset option helps me a lot. Please close the thread if you like. |
That's great to hear @mbobinger - thanks for the update! I will close the case now. |
Camera model: D435i
Firmware version: 05.12.06.00
Firmware Update ID: 020423022673
System: Raspberry Pi4 - 4GB
Framework: Python3.6
Error message: rs2_get_option(options:0xad811f08, option:Exposure): get_xu(id=3) failed last error: resource temporarily unavailable
Dear Realsense-fellows,
I've been using the D435i-intel cams on my RPI4 for months and I haven't had many issues besides sometimes I couldn't set the power state, in that cases a sudo reboot or unplugging and replugging of the USB cam would fix the issue. However, in almost all cases I cannot access the installations because they are remote.
Since yesterday I am facing a new problem: the error mentioned above. I've done some basic homework and searched for the issue and came across following threads:
C++ fix: #2161 (comment)
Python fix: #5428
C++ USB reset: https://github.com/themancalledjakob/usbreset
So I've tread the Python fix (thread 5428) and applied some simple prints for the devices, the only plugged in intel cam was also recognized. However, after that reset I still needed a sudo reboot to be able to access the device again.
So currently I am wondering what is kind of the best practice and most robust way to handle such errors?
I have thought about following code, which I tested in principle and it works (It tries to initialize the cam for 5 times and if it fails the RPI will be rebooted):
The text was updated successfully, but these errors were encountered: