?? parse.pl
字號:
#!/usr/bin/perl# Short perl script to produce a useful kernel code for the testing of the # winbond_9967cf driver for linux.# It require as input the data processed by sniff2mod by David Gouchard # (david@fairesuvre.fr, http://www.laas.fr/~gauchard) Thanks David!!!# Use:# cat sniff2mod_data | ./parse.pl# by Raffaele Spangaro <keatch@f2s.com># http://www.keatch.f2.comprint "short reg_value;\n\n";while (<>) { chomp; @values=split(/,/,$_); $values[3] =~ /W9968_SET_REG/ && printf("if(w9967cf_reg_set(cam->dev,%s,%s)<0) return -1;\n",$values[5],$values[4]); $values[3] =~ /W9968_GET_REG/ && printf("if(w9967cf_reg_get(cam->dev,%s,®_value)<0) return -1;\n",$values[5]); if ($values[0] =~ /(usb_set)/ ) { $_ = $values[2]; s/\)\);//g; printf("if(usb_set_interface(cam->dev,0,%s)<0) return -1;\n",$_); }}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -