Closed Tumb1eweed closed 1 year ago
(I used this to run a photo import from f-spot and gphoto a couple of years ago, so it at least used to get quite far. But admittedly I haven't looked at that since then, so it may well have gotten broken.)
In general yes -- the source even contains a PTP camera 😁 However, this is many years old, and the ioctl record most probably does not work with current libusb versions and such. But it should be possible. Did you already try and it failed, or was this just a high-level question?
oh i just ask before trying, because i want to use to test transferring data through shared memory in ros2 nodes, and the publisher's data is from camera but i don't want to start a camera (no device), so I want to mock camera (mock xoictl particularly). After experiment I will tell you the result, thanks.
(I used this to run a photo import from f-spot and gphoto a couple of years ago, so it at least used to get quite far. But admittedly I haven't looked at that since then, so it may well have gotten broken.)
i forgot to ask, is this tool supporting C++?
There are no real requirements for the code that you are testing. The library itself is vala (i.e. C), so of course it works well from C++ if you want that.
No idea about ROS and the test.
I suppose that works by mmap'ing a device file and doing a few ioctl's on it. With umockdev, that should work, i.e.:
EDIT: Or, well, maybe I misunderstood this and the shared memory is just between the different processes that are being tested. In that case, we don't care about it.
This is stale and there is nothing actionable. Closing.
In general yes -- the source even contains a PTP camera :grin: However, this is many years old, and the ioctl record most probably does not work with current libusb versions and such. But it should be possible. Did you already try and it failed, or was this just a high-level question?