正在安装 CP210x 驱动程序?

正在安装 CP210x 驱动程序?

编辑:我刚刚在终端中运行了 lsmod,并列出了以下内容

cp210x                 24576  0 

所以也许它已经安装好了,我不需要做任何事情/有其他东西阻止 GPS 与程序通信?是否需要做任何特殊的事情才能让它与 Wine 一起工作?


我是 Linux/Ubuntu 的新手,所以很抱歉,这有点愚蠢。我有一个用于寻宝的 GPS(http://www.b4adventure.com/geomatejr/),要使用它,您需要 Silas Labs 的 CP210x 驱动程序。我看到有一个 Linux 驱动程序,并认为它可以工作,但是,我对“构建说明”感到困惑。它没有要复制到终端的确切代码(或没有方便的安装包 :) )。

说明书内容如下:

  1. 制作(你的 cp210x 驱动程序)
  2. cp cp210x.ko 到/lib/modules/<kernel-version>/kernel/drivers/usb/serial
  3. insmod /lib/modules/<kernel-version/kernel/drivers/usb/serial/usbserial.ko
  4. insmod cp210x.ko

现在,下载的内容有四个文件,发行说明(见上文)、cp210x.c、cp210x_gpio_example.c 和 Makefile。我假设第一步使用 Makefile,但我对代码/Ubuntu 了解不够多,不知道我应该输入什么/做什么。

Makefile 包含以下内容:

obj-m = cp210x.o
KVERSION = $(shell uname -r)
all:
    make -C /lib/modules/$(KVERSION)/build M=$(PWD) modules
clean:
    make -C /lib/modules/$(KVERSION)/build M=$(PWD) clean

KVERSION 应该是 4.4.0-87-generic(lib/modules 文件夹中的最新/最高数字)吗?然后 PWD 我的密码,也许?我不想通过在终端中随机输入代码来破坏东西,所以我很感激一些指导!非常非常感谢分步帮助!!!


modinfo usbserial # get info on this kernel module
filename:       /lib/modules/4.4.0-87-generic/kernel/drivers/usb/serial/usbserial.ko
license:        GPL
description:    USB Serial Driver core
author:         Greg Kroah-Hartman <[email protected]>
srcversion:     AB3F1BFEDF75B5D214FAAD2
depends:        
intree:         Y
vermagic:       4.4.0-87-generic SMP mod_unload modversions 
parm:           vendor:User specified USB idVendor (ushort)
parm:           product:User specified USB idProduct (ushort)
modinfo cp210x # get info on this kernel module
filename:       /lib/modules/4.4.0-87-generic/kernel/drivers/usb/serial/cp210x.ko
license:        GPL
description:    Silicon Labs CP210x RS232 serial adaptor driver
srcversion:     2943505BFE400A2778D74E5
alias:          usb:v413Cp9500d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v3195pF281d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v3195pF280d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v3195pF190d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v2626pEA60d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0701d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0700d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0602d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0601d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0600d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0404d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0403d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0402d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0401d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0400d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0303d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0302d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0301d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0300d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0203d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0202d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0201d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0200d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1FB9p0100d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1E29p0501d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1E29p0102d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1D6Fp0010d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1BE3p07A6d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1BA4p0002d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1B1Cp1C00d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1ADBp0001d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v19CFp3000d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1901p0196d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1901p0195d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1901p0194d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1901p0193d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1901p0190d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v18EFpE025d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v18EFpE00Fd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1843p0200d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v17F4pAAAAd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v17A8p0005d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v17A8p0001d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v16DCp0015d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v16DCp0012d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v16DCp0011d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v16DCp0010d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v16D6p0001d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v16C0p09B1d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v16C0p09B0d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v166Ap0101d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v166Ap0401d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v166Ap0305d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v166Ap0304d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v166Ap0303d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v166Ap0301d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v166Ap0201d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v1555p0004d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v13ADp9999d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v12B8pEC62d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v12B8pEC60d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10CEpEA6Ad*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C5pEA61d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pF004d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pF003d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pF002d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pF001d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pEA71d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pEA70d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pEA61d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4pEA60d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8A2Ad*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8998d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8977d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8962d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8946d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p88A5d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p88A4d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8857d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8856d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8665d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8664d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p85F8d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p85EBd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p85EAd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p84B6d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8477d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8470d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p846Ed*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8418d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8411d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p83D8d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p83A8d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8382d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8341d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p82F9d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p82F4d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8293d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8281d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p826Bd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p822Bd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8218d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81F2d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81E8d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81E7d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81E2d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81D7d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81C8d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81ADd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81ACd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81A9d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p81A6d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p819Fd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p818Bd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p815Fd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p815Ed*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8156d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v2405p0003d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p814Bd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p814Ad*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p813Fd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p813Dd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8115d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p80F6d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p80DDd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p80CAd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p80C4d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p807Ad*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p806Fd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8066d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8054d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8053d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p804Ed*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p8044d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p803Bd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p800Ad*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p1601d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p1101d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10C4p0F91d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10B5pAC70d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10ABp10C5d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v10A6pAA26d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0FDEpCA05d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0FCFp1006d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0FCFp1004d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0FCFp1003d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0BEDp1101d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0BEDp1100d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0908p01FFd*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v08FDp000Ad*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v08E6p5501d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0846p1100d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0745p1000d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0489pE003d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0489pE000d*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v0471p066Ad*dc*dsc*dp*ic*isc*ip*in*
alias:          usb:v045Bp0053d*dc*dsc*dp*ic*isc*ip*in*
depends:        usbserial
intree:         Y
vermagic:       4.4.0-87-generic SMP mod_unload modversions 

答案1

在 Ubuntu 17.10 中,这些内核模块已经存在。要查看它们是否存在于您的 14.04 系统中,请terminal执行以下操作...

ls -al /lib/modules/"$(uname -r)"/kernel/drivers/usb/serial/usbserial.ko

ls -al /lib/modules/"$(uname -r)"/kernel/drivers/usb/serial/cp210x.ko

或者

modinfo usbserial # get info on this kernel module

modinfo cp210x # get info on this kernel module

要手动加载它们,以便您可以尝试从 Ubuntu 访问,请执行以下操作:

sudo modprobe usbserial # load this kernel module

sudo modprobe cp210x # load this kernel module

这些模块是否允许 Wine 程序访问该设备尚不清楚。不过,Ubuntu 很可能允许访问。

如果这两个文件不存在,那么您需要自己编译源代码。假设Linux-3-x-x-VCP-Driver-Source.zip您的桌面上存在一个名为的文件。

注意:由于采用手动安装方法,每次通过软件更新程序更新内核时都必须执行此操作。

Files(Nautilus) 窗口中,右键单击Linux-3-x-x-VCP-Driver-Source.zip您下载的文件,然后选择extract here。您将得到一个名为 的文件夹Linux-3-x-x-VCP-Driver-Source

terminal...

cd ~/Desktop # change directory to Desktop

cd Linux-3-x-x-VCP-Driver-Source # change directory to the cp210x folder, adjust name if necessary

make # compile the source code

cp cp210x.ko to /lib/modules/"$(uname -r)"/kernel/drivers/usb/serial/ # copy the file to the system area

sudo modprobe usbserial # load this kernel module

sudo modprobe cp210x # load this kernel module

相关内容