pysigrok  0.4.0
Python bindings for libsigrok
Public Member Functions | Static Public Attributes | Properties | List of all members
sigrok.core.classes.Session Class Reference

A sigrok session. More...

Inherits sigrok.core.classes._object.

Public Member Functions

def add_device (self, device)
 Add a device to this session. More...
 
def remove_devices (self)
 Remove all devices from this session. More...
 
def add_datafeed_callback (self, callback)
 Add a datafeed callback to this session. More...
 
def remove_datafeed_callbacks (self)
 Remove all datafeed callbacks from this session. More...
 
def start (self)
 Start the session. More...
 
def run (self)
 Run the session event loop. More...
 
def stop (self)
 Stop the session. More...
 
def is_running (self)
 Return whether the session is running. More...
 
def set_stopped_callback (self, callback)
 Set callback to be invoked on session stop. More...
 
def context (self)
 Get the context. More...
 

Static Public Attributes

tuple trigger
 

Properties

 devices
 

Detailed Description

A sigrok session.

Member Function Documentation

def sigrok.core.classes.Session.add_device (   self,
  device 
)

Add a device to this session.

Parameters
deviceDevice to add.

References sigrok.core.classes.Session.context().

+ Here is the call graph for this function:

def sigrok.core.classes.Session.remove_devices (   self)

Remove all devices from this session.

def sigrok.core.classes.Session.add_datafeed_callback (   self,
  callback 
)

Add a datafeed callback to this session.

Parameters
callbackCallback of the form callback(Device, Packet).
def sigrok.core.classes.Session.remove_datafeed_callbacks (   self)

Remove all datafeed callbacks from this session.

def sigrok.core.classes.Session.start (   self)

Start the session.

def sigrok.core.classes.Session.run (   self)

Run the session event loop.

def sigrok.core.classes.Session.stop (   self)

Stop the session.

References sigrok.core.classes.Packet._payload_header(), sigrok.core.classes.Packet._payload_logic(), sigrok.core.classes.Packet._payload_meta(), sigrok.core.classes.Channel.type, sigrok.core.classes.TriggerMatch.type, and sigrok.core.classes.Packet.type.

+ Here is the call graph for this function:

def sigrok.core.classes.Session.is_running (   self)

Return whether the session is running.

References sigrok.core.classes.Packet._payload_analog(), sigrok.core.classes.Channel.type, sigrok.core.classes.TriggerMatch.type, and sigrok.core.classes.Packet.type.

+ Here is the call graph for this function:

def sigrok.core.classes.Session.set_stopped_callback (   self,
  callback 
)

Set callback to be invoked on session stop.

def sigrok.core.classes.Session.context (   self)

Get the context.

Referenced by sigrok.core.classes.Session.add_device().

+ Here is the caller graph for this function:


The documentation for this class was generated from the following file: