I am going through the documentation and cannot find any help about this. Where is the documentation about how to make a driver understand which devices it should open and service? I do know there is a directory with rules files, but it seems incomplete as far as making a real determination.
The Toupcam driver is set up to be the driver for vendor id "0547" according to the rules files. That driver does work for my Solomark camera (product id b123) which makes sense since it was shipped with a disk of Toupcam drivers for PC and Mac systems.
The Mallincam camera I have (DS16C) that I am trying to generate a driver for also uses vendor id 0547. How does the Toupcam driver distinguish the camera product ids that it should not open?
Note the Toupcam driver also will not recognize my Orion Starshoot which is 0547:a004.
I did see that there is a rule for one product id in the 0547 vendor id within the qhyccd rules - product id 1002.
But this question is why and how does the Toupcam driver determine that it should ignore some of the cameras/ids in that vendor range?
I can not provide a complete answer, but as far as I can tell you are one the right path.
A udev rule with the Vendor ID, Product ID, sometimes the serial port number, and the mode is needed. Then a Symlink created.
This script, intended for creating consistent rules for a serial GPS, may offer a little insight. github.com/rlancaste/AstroPi3/blob/master/udevRuleScript.sh
Edit: udevadm monitor may provide more detailed information on the camera when it's connected as well.
There is no list of the productid's that are served by this driver. In reading your comment above, I do see the MODE="0666" on this file. Is it possible that this is what the driver or something in either linux or the astroberry software is using to eliminate other cameras form this driver? Is it possible to read the mode value from a camera? How would I get that value for a Mallincam camera having the camera plugged into a computer?