-
-
Notifications
You must be signed in to change notification settings - Fork 22
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
The webcam continues forgetting the configuration #203
Comments
Could you show me the output of By the way you, only need to configure once, then just execute |
Sorry, I totally missed the notifications somehow!! The linux-enable-ir-emitter.service effectively failed (core-dumped).
It seems that the KVM switches the identifiers, apparently |
For now I made a (very crappy) hack support service, like follows (as the configuration never changes, only (part of the) identifier:
The script: #!/usr/bin/env bash
config_dir="/etc/linux-enable-ir-emitter"
v_device=$(ls -l /dev/v4l/by-path/ | grep ":1.2-video-index0" | grep -v usbv | awk '{print $9}')
is_registered=$(ls -l "${config_dir}" | grep "${v_device}" | grep -v ".ini")
is_registered_ini=$(ls -l "${config_dir}" | grep "${v_device}.ini")
if [ "${is_registered}" = "" ]; then
cp_file=$(ls -1 /etc/linux-enable-ir-emitter | grep -v ".ini" | head -n 2 | tail -n 1)
if [ "${cp_file}" != "" ]; then
cp "${config_dir}/${cp_file}" "${config_dir}/${v_device}"
rm "${config_dir}/${cp_file}"
fi
fi
if [ "${is_registered_ini}" = "" ]; then
cp_file=$(ls -1 /etc/linux-enable-ir-emitter | grep ".ini" | head -n 2 | tail -n 1)
if [ "${cp_file}" != "" ]; then
cp "${config_dir}/${cp_file}" "${config_dir}/${v_device}.ini"
rm "${config_dir}/${cp_file}"
fi
fi |
So if I understand correctly, you think that your camera is changing its v4l path ? Hum, sounds strange because that's the point of such path; be well determined. Maybe you could try to delete all the files in /etc/linux-enable-ir-emitter, restart and reconfigure to have a fresh configuration for the current path (if you know its actual /dev/video path you can specify it with -d) and see if it works for the next restarts? In the next update, I plan to release soon(TM), I've made the tool more resilient to error if one configuration fails to apply on the linked camera. |
For some reason, I can tell you that it changes somehow. I don't know if this depends on system updates or KVM, but it definitely happens. I'll monitor the path to understand if it always changes or not. I'm not into hardware like you are at Linux level, though couldn't you add the option to recognize the webcam via vendor:product instead? That should never change by definition |
This version #211 will just ignore configuration that it cannot apply, so you could have a bunch of configuration in case of device path change. |
Hello @EmixamPP - just an update on the issue. I can confirm that - apparently - the KVM is causing the issue, changing the pci address - how cute! Exploring udev rules for another project, I managed to sort out a better solution: I've added a udev rule which aliases the device. This is the particular rule:
I got the udev filter by doing an attribute walk of the known device: As a result, I now have a stable
|
Describe the bug
I've got an IR webcam connected to the computer via a KVM. I've noticed that pretty much every time I restart the computer, the IR emitter doesn't emit light. If I configure it again via
sudo linux-enable-ir-emitter configure -m
it works again, until the next restart (or two). I've noticed that in/etc/linux-enable-ir-emitter
I have different configuration files, even if the webcam is one.I'm in a dual-boot system (Windows / Linux)
How to reproduce
Additional info
The text was updated successfully, but these errors were encountered: