From 34fd4465da41bff4d1bffbe14bf80ac60cbc6a74 Mon Sep 17 00:00:00 2001 From: Piotr Dobrowolski Date: Tue, 22 Oct 2019 16:15:12 +0200 Subject: [PATCH] totally legit internal fork --- cli.py | 85 +++++++++++++++++++++++++++++++++++++++++- py9b/transport/base.py | 7 ++-- 2 files changed, 87 insertions(+), 5 deletions(-) diff --git a/cli.py b/cli.py index 5781226..1698519 100644 --- a/cli.py +++ b/cli.py @@ -2,7 +2,8 @@ import click from py9b.link.base import LinkTimeoutException from py9b.transport.base import BaseTransport as BT -from py9b.command.regio import ReadRegs +from py9b.transport.packet import BasePacket as PKT +from py9b.command.regio import ReadRegs, WriteRegs class Connection: def __init__(self, transport, link, address): @@ -64,6 +65,14 @@ class Connection: def cli(ctx, transport, link, address): ctx.obj = Connection(transport, link, address) +@cli.command() +@click.pass_context +def dong(ctx): + with ctx.obj as tran: + #tran.execute(WriteRegs(BT.ESC, 0x1e, "