From 8ce3c0c770ef95f9b994eabb8e46faafd8703c28 Mon Sep 17 00:00:00 2001 From: Chris Liechti Date: Sat, 27 Aug 2016 23:54:51 +0200 Subject: parity: new PARITY_IGNORE setting (posix/win32) see #154 for discussion --- serial/serialutil.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'serial/serialutil.py') diff --git a/serial/serialutil.py b/serial/serialutil.py index 474b4c2..c2bd774 100644 --- a/serial/serialutil.py +++ b/serial/serialutil.py @@ -79,7 +79,7 @@ CR = to_bytes([13]) LF = to_bytes([10]) -PARITY_NONE, PARITY_EVEN, PARITY_ODD, PARITY_MARK, PARITY_SPACE = 'N', 'E', 'O', 'M', 'S' +PARITY_NONE, PARITY_EVEN, PARITY_ODD, PARITY_MARK, PARITY_SPACE, PARITY_IGNORE = 'N', 'E', 'O', 'M', 'S', 'X' STOPBITS_ONE, STOPBITS_ONE_POINT_FIVE, STOPBITS_TWO = (1, 1.5, 2) FIVEBITS, SIXBITS, SEVENBITS, EIGHTBITS = (5, 6, 7, 8) @@ -116,7 +116,7 @@ class SerialBase(io.RawIOBase): 576000, 921600, 1000000, 1152000, 1500000, 2000000, 2500000, 3000000, 3500000, 4000000) BYTESIZES = (FIVEBITS, SIXBITS, SEVENBITS, EIGHTBITS) - PARITIES = (PARITY_NONE, PARITY_EVEN, PARITY_ODD, PARITY_MARK, PARITY_SPACE) + PARITIES = (PARITY_NONE, PARITY_EVEN, PARITY_ODD, PARITY_MARK, PARITY_SPACE, PARITY_IGNORE) STOPBITS = (STOPBITS_ONE, STOPBITS_ONE_POINT_FIVE, STOPBITS_TWO) def __init__(self, -- cgit v1.2.1