From: Bert Vermeulen Date: Tue, 2 Apr 2013 11:59:54 +0000 (+0200) Subject: Revert "hantek-dso-extract: use 2xxx or 5xxx for firmware blobs" X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=58c70ebbae210c4e961996d855d1102654f9171c;p=sigrok-util.git Revert "hantek-dso-extract: use 2xxx or 5xxx for firmware blobs" This reverts commit aba15c6379086057921e760758cb96ac7cdec744. These are identical in the 2xxx and 5xxx series -- except for the USB ProductID embedded in the firmware blobs, and we do need the devices to come back with the ProductID identifying the model. --- diff --git a/firmware/hantek-dso-extract.py b/firmware/hantek-dso-extract.py index faa7712..e99236b 100755 --- a/firmware/hantek-dso-extract.py +++ b/firmware/hantek-dso-extract.py @@ -29,9 +29,12 @@ import parsepe def find_model(filename): filename = os.path.split(filename)[-1] - m = re.search('^dso([25])[a-z0-9]+1.sys$', filename, re.I) + m = re.search('^dso([a-z0-9]+)1.sys$', filename, re.I) if m: - model = m.group(1) + 'xxx' + model = m.group(1).upper() + model = model.replace('X86', '').replace('AMD64', '').replace('IA64', '') + if model == '520A': + model = '5200A' else: model = 'unknown'