]> sigrok.org Git - libsigrokdecode.git/blobdiff - decoders/i2cdemux/pd.py
license: remove FSF postal address from boiler plate license text
[libsigrokdecode.git] / decoders / i2cdemux / pd.py
index dd773b54359155ceaf2fc13750e9de7774e8499c..d28763b2f55a32c9a37b743da3cc997b2f7f6086 100644 (file)
 ## GNU General Public License for more details.
 ##
 ## You should have received a copy of the GNU General Public License
-## along with this program; if not, write to the Free Software
-## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+## along with this program; if not, see <http://www.gnu.org/licenses/>.
 ##
 
 import sigrokdecode as srd
 
 class Decoder(srd.Decoder):
-    api_version = 1
+    api_version = 2
     id = 'i2cdemux'
     name = 'I²C demux'
     longname = 'I²C demultiplexer'
@@ -29,9 +28,8 @@ class Decoder(srd.Decoder):
     license = 'gplv2+'
     inputs = ['i2c']
     outputs = [] # TODO: Only known at run-time.
-    annotations = []
 
-    def __init__(self, **kwargs):
+    def __init__(self):
         self.packets = [] # Local cache of I²C packets
         self.slaves = [] # List of known slave addresses
         self.stream = -1 # Current output stream
@@ -76,4 +74,3 @@ class Decoder(srd.Decoder):
             self.stream = -1
         else:
             pass # Do nothing, only add the I²C packet to our cache.
-