Thursday, March 21, 2013

Install pySerial on Ubuntu

To check if pySerial installed, open Python Shell, type the command:

>>>import serial

if error message returned, means pySerial not installed.

pySerial not installed
pySerial not installed with error

- To install pySerial on Ubuntu, download and unpack pyserial, open Terminal and change to the unpacked folder.

- To install for Python 2.x, type the command:

$sudo python setup.py install


- To install for Python 3.x, type the command:

$sudo python3 setup.py install

(To install the module for all users on the system, administrator rights (root) is required, run with sudo.)


pySerial installed
import serial with pySerial installed


2 comments: