chiark / gitweb /
allow tol in desc
authorian <ian>
Mon, 19 Apr 2004 00:04:02 +0000 (00:04 +0000)
committerian <ian>
Mon, 19 Apr 2004 00:04:02 +0000 (00:04 +0000)
farnell/farnell-resistor-convert.pl

index 8c95ed37014617295a54a163fc744130b34c6d24..61e5373eb75d7e206f9223ad1e0143d98abf1f4f 100755 (executable)
@@ -16,7 +16,8 @@ if (@ARGV>=2) {
     while (<STDIN>) {
        if (m/^Avail\s/) {
            undef $value;
-       } elsif (m/^Description\s+\[$kind (\d[0-9MKR]+)\]\s+RESISTOR/) {
+       } elsif (
+ m/^Description\s+\[$kind (\d[0-9MKR]+)(?:\s[0-9.]+\%)?\]\s+RESISTOR/) {
            $value= lc $1;
        } elsif (m/^Description\s+(\S.*)/) {
            print "#  $1\n";