# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.cmd_ss, self.cmd_es, self.out_ann, data)
self.bit_width = float(self.samplerate) / float(self.options['bitrate'])
self.bitpos = (self.bit_width / 100.0) * self.options['sample_point']
- def report(self):
- pass
-
# Generic helper for CAN bit annotations.
def putg(self, ss, es, data):
left, right = int(self.bitpos), int(self.bit_width - self.bitpos)
if key == srd.SRD_CONF_SAMPLERATE:
self.samplerate = value
- def report(self):
- pass
-
def putx(self, data):
# Annotation for a single DCF77 bit.
self.put(self.ss_bit, self.es_bit, self.out_ann, data)
def start(self):
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.ss, self.es, self.out_ann, data)
def start(self):
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def decode(self, ss, es, data):
cmd, data = data
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def decode(self, ss, es, data):
for (self.samplenum, pins) in data:
self.out_bitrate = self.register(srd.OUTPUT_META,
meta=(int, 'Bitrate', 'Bitrate from Start bit to Stop bit'))
- def report(self):
- pass
-
def putx(self, data):
self.put(self.startsample, self.samplenum, self.out_ann, data)
def start(self):
self.out_proto = []
- def report(self):
- pass
-
# Grab I2C packets into a local cache, until an I2C STOP condition
# packet comes along. At some point before that STOP condition, there
# will have been an ADDRESS READ or ADDRESS WRITE which contains the
if self.options['direction'] not in ('both', 'read', 'write'):
raise Exception('Invalid direction (valid: read/write/both).')
- def report(self):
- pass
-
# Grab I2C packets into a local cache, until an I2C STOP condition
# packet comes along. At some point before that STOP condition, there
# will have been an ADDRESS READ or ADDRESS WRITE which contains the
# of '-' means 'stdout'.
self.f = self.file_open(self.options['filename'])
- def report(self):
- pass
-
# TODO: Lots of hard-coded fields in here.
def write_wav_header(self):
# Chunk descriptor
self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def advance_state_machine(self, tms):
self.oldstate = self.state
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def handle_reg_bypass(self, cmd, bits):
# TODO
self.put(self.ss, self.es, self.out_ann, [0, ['BYPASS: ' + bits]])
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putb(self, data):
self.put(self.ss_block, self.es_block, self.out_ann, data)
def start(self):
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.ss, self.es, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.ss_block, self.es_block, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.ss, self.es, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
# Simplification, most annotations span exactly one SPI byte/packet.
self.put(self.ss, self.es, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.ss, self.es, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
# Helper for annotations which span exactly one I2C packet.
self.put(self.ss, self.es, self.out_ann, data)
'(%2.1fus-%2.1fus) should be inside (7.3us, 10.0us).'
% (time_min*1000000, time_max*1000000)]])
- def report(self):
- pass
-
def decode(self, ss, es, data):
if self.samplerate is None:
raise Exception("Cannot decode without samplerate.")
self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
# Helper function for most annotations.
self.put(self.beg, self.end, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.ss_block, self.es_block, self.out_ann, data)
self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putpb(self, data):
self.put(self.ss_item, self.es_item, self.out_proto, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.ss, self.es, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def putx(self, data):
self.put(self.cmd_ss, self.cmd_es, self.out_ann, data)
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def handle_11bits(self):
s = "".join(str(i) for i in self.bits[:2])
self.dac_select = s = dacs[int(s, 2)]
# self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def decode(self, ss, es, data):
for (samplenum, s) in data:
# The width of one UART bit in number of samples.
self.bit_width = float(self.samplerate) / float(self.options['baudrate'])
- def report(self):
- pass
-
# Return true if we reached the middle of the desired bit, false otherwise.
def reached_bit(self, rxtx, bitnum):
# bitpos is the samplenumber which is in the middle of the
self.f_rx = self.file_open(self.options['filename_rx'])
self.f_tx = self.file_open(self.options['filename_tx'])
- def report(self):
- pass
-
def decode(self, ss, es, data):
ptype, rxtx, pdata = data
self.out_proto = self.register(srd.OUTPUT_PYTHON)
self.out_ann = self.register(srd.OUTPUT_ANN)
- def report(self):
- pass
-
def handle_packet(self):
packet = ''
for (bit, ss, es) in self.bits:
self.bitwidth = float(self.samplerate) / float(self.bitrate)
self.halfbit = int(self.bitwidth / 2)
- def report(self):
- pass
-
def putpx(self, data):
self.put(self.samplenum, self.samplenum, self.out_proto, data)