kernel - /dev/video0 : invalid argument -


Why I am not able to read this file. I tried to read this file with the cat:

  cat / dev / video0   

but it says

 < Code> cat: / dev / video0: invalid argument   

Similarly, if I try to use DD:

  dd if = / Dev / video0 ~ / vid   

It is still not able to read it.

Note that video0 is the tool file for my webcam.

I think the show function may be incorrect for the device node "video 0" created in your device is.

Give an example below

  static DEVICE_ATTR (video 0, S_IRUGO | S_UUSR | S_IUGRP | S_Iwoth, video0_show, video0_store); Static ssize_t video0_show (structural device * dev, struct device_attribute * attr, char * buf); Static ssize_t video0_store (structural device * dev, struct device_attribute * attr, char * buf, size_t count);   

When you cat the device node "Video 0" on the runtime, it calls the "video0_show" function to print something. The error message "cat: / dev / video0: invalid argument" means that the argument for the video0_show function is incorrect. You should debug the driver.

Comments

Popular posts from this blog

excel vba - How to delete Solver(SOLVER.XLAM) code -

github - Teamcity & Git - PR merge builds - anyway to get HEAD commit hash? -

ios - Replace text in UITextView run slowly -