pyserial for Python 2.7.2

前端 未结 8 1966
甜味超标
甜味超标 2021-02-03 12:33

I\'m new to Python. According to the internets I was looking for the module pyserial after receiving this error:

ImportError: No module named serial


        
相关标签:
8条回答
  • 2021-02-03 12:50

    pyserial comes now with a precomilied(?) Windows .exe installer: https://pypi.python.org/pypi/pyserial

    0 讨论(0)
  • 2021-02-03 12:53

    pySerial can be installed from PyPI:

    python -m pip install pyserial
    

    NOTE : Using the python/python3 executable of the desired version (2.7/3.x).

    0 讨论(0)
  • 2021-02-03 12:59

    From http://www.instructables.com/id/The-Arduino-Internet-Gizmo/step19/Installing-the-software/

    Install pySerial as follows:

    Download pySerial from http://pypi.python.org/pypi/pyserial - click on pyserial-2.6.tar.gz to download the library.

    Run 7-Zip (Start -> All Programs -> 7-Zip -> 7-Zip File Manager).

    Open the pyserial-2.6.tar.gz file with 7-Zip (File -> Open).

    Double click the "dist" folder.

    Single click on the "pyserial-2.6.tar" file and click the "Extract" button at the top of the window. When asked where to put the file, specify c:\Python27\Lib\site-packages\pyserial-2.6

    Exit from 7-Zip

    Now that you have downloaded pySerial, install it:

    Open a command window (Start -> All Programs -> Accessories -> Command Prompt) and type into the command line: cd c:\Python27\Lib\site-packages\pyserial-2.6

    Install pySerial by typing this command (including the path): c:\Python27\python.exe setup.py install

    0 讨论(0)
  • 2021-02-03 13:00

    please just go to http://www.lfd.uci.edu/~gohlke/pythonlibs/#pyserial and download the 64 bit installer and that's it!

    0 讨论(0)
  • 2021-02-03 13:01

    reviving an old thread but pyserial v3.4 is now available for windows/mac/linux via the conda package manager on the conda-forge channel (the base conda channel has v2.7)

    To install this package with conda run:
    conda install -c conda-forge pyserial

    0 讨论(0)
  • 2021-02-03 13:05

    understood that this question is for Windows, but since it comes up first in a Google search let me add an alternative (to pip) for Debian:

    sudo apt-get install python-serial

    0 讨论(0)
提交回复
热议问题