transport: Change transport api to allow for wait_for_card/connect/disconnect
This way, we can re-use the same transport parameters for several cards for a future batch mode Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
This commit is contained in:
@@ -23,6 +23,25 @@
|
||||
|
||||
class LinkBase(object):
|
||||
|
||||
def wait_for_card(self, timeout=None, newcardonly=False):
|
||||
"""wait_for_card(): Wait for a card and connect to it
|
||||
|
||||
timeout : Maximum wait time (None=no timeout)
|
||||
newcardonly : Should we wait for a new card, or an already
|
||||
inserted one ?
|
||||
"""
|
||||
pass
|
||||
|
||||
def connect(self):
|
||||
"""connect(): Connect to a card immediately
|
||||
"""
|
||||
pass
|
||||
|
||||
def disconnect(self):
|
||||
"""disconnect(): Disconnect from card
|
||||
"""
|
||||
pass
|
||||
|
||||
def reset_card(self):
|
||||
"""reset_card(): Resets the card (power down/up)
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user