Merge branch 'master' into add_a_true_telegram_object

This commit is contained in:
Hans Erik van Elburg 2019-11-25 20:30:35 +01:00
commit 95bab6a51a
3 changed files with 6 additions and 2 deletions

View File

@ -1,6 +1,10 @@
Change Log
----------
**0.14** (2019-10-08)
- Changed serial reading to reduce CPU usage (`pull request #37 <https://github.com/ndokter/dsmr_parser/pull/37>`_).
**0.13** (2019-03-04)
- Fix DSMR v5.0 serial settings which were not used (`pull request #33 <https://github.com/ndokter/dsmr_parser/pull/33>`_).

View File

@ -32,7 +32,7 @@ class SerialReader(object):
"""
with serial.Serial(**self.serial_settings) as serial_handle:
while True:
data = serial_handle.readline()
data = serial_handle.read(max(1, min(1024, serial_handle.in_waiting)))
self.telegram_buffer.append(data.decode('ascii'))
for telegram in self.telegram_buffer.get_all():

View File

@ -6,7 +6,7 @@ setup(
author='Nigel Dokter',
author_email='nigel@nldr.net',
url='https://github.com/ndokter/dsmr_parser',
version='0.13',
version='0.14',
packages=find_packages(),
install_requires=[
'pyserial>=3,<4',