Fix incorrect behaviour of "platformio serialports monitor" in pair with @PySerial 3.0

This commit is contained in:
Ivan Kravets
2015-12-05 23:30:42 +02:00
parent 16abaccf96
commit 2345eb3bb7
2 changed files with 7 additions and 4 deletions

View File

@ -14,6 +14,8 @@ PlatformIO 2.0
* Removed prompt with "auto-uploading" from `platformio init <http://docs.platformio.org/en/latest/userguide/cmd_init.html>`__
command and added ``--enable-auto-uploading`` option
(`issue #352 <https://github.com/platformio/platformio/issues/352>`_)
* Fixed incorrect behaviour of `platformio serialports monitor <http://docs.platformio.org/en/latest/userguide/cmd_serialports.html#platformio-serialports-monitor>`__
in pair with PySerial 3.0
2.4.1 (2015-12-01)
~~~~~~~~~~~~~~~~~~

View File

@ -57,10 +57,10 @@ if int(PYSERIAL_VERSION[0]) == 3:
help="Enable RTS/CTS flow control, default=Off")
@click.option("--xonxoff", is_flag=True,
help="Enable software flow control, default=Off")
@click.option("--rts", default="0", type=click.Choice(["0", "1"]),
help="Set initial RTS line state, default=0")
@click.option("--dtr", default="0", type=click.Choice(["0", "1"]),
help="Set initial DTR line state, default=0")
@click.option("--rts", default=None, type=click.Choice(["0", "1"]),
help="Set initial RTS line state")
@click.option("--dtr", default=None, type=click.Choice(["0", "1"]),
help="Set initial DTR line state")
@click.option("--encoding", default="UTF-8",
help="Set the encoding for the serial port (e.g. hexlify, "
"Latin1, UTF-8), default: UTF-8")
@ -101,6 +101,7 @@ if int(PYSERIAL_VERSION[0]) == 3:
sys.argv.extend([k, str(v)])
try:
print kwargs
miniterm.main( # pylint: disable=E1123
default_port=kwargs['port'],
default_baudrate=kwargs['baud'],