delorie.com/archives/browse.cgi   search  
Mail Archives: geda-user/2012/07/31/17:32:31

X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f
X-Recipient: geda-user AT delorie DOT com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=20120113;
h=mime-version:sender:in-reply-to:references:date
:x-google-sender-auth:message-id:subject:from:to:content-type;
bh=9chBp0xGWRfJ9dAt9h6pbGqW3Ye9nO4gSggkKJ4FpV4=;
b=t6Vnsly5bIMZguFAYToOOt795V6F0QZ1iRboUiP7gYf6aw0Gti9rdHL1dWaFmiwOfI
1+Z5WGboxyEUGaEF45ZMMr5tL4UsdLBpsWYcG7h85MtA99Z9K+doOJa+1DOsiv8IaYQ3
q2QarfPR4NeVeNricd1xMuGCG6Wlm9i1p7dEvKfNIuWezmHVjYEdy/y+m5uPRaWNGlew
LaaP0483Dzaav/OSpk8+GqxJOCDA+a1i6tSUnqZdGVPD6PQLL0b7qvfoqZQhFOV2HxTJ
bXfl39whBfIILRqJc4fNpbHCrwby9ce57fzvdOOYxBH0mRvnQo0BO/MhWGo+HnEnY7cK
IVXg==
MIME-Version: 1.0
Sender: silicon DOT on DOT inspiration AT gmail DOT com
In-Reply-To: <20120731204618.4ab9835b@wind.levalinux.org>
References: <CAKakQccB1G9rJWZc6WekqV8H0hA81j0RssMOUMGk4+_jKW6+0w AT mail DOT gmail DOT com>
<20120731204618 DOT 4ab9835b AT wind DOT levalinux DOT org>
Date: Wed, 1 Aug 2012 07:31:55 +1000
X-Google-Sender-Auth: WX0q8B2v-WHdOAMcxFIagB2R7JU
Message-ID: <CAKakQcdTFHm7nLiAYhg+9LJRVX2GiY67gc0gWaFwjBpXpCKHCw@mail.gmail.com>
Subject: Re: [geda-user] I've updated footgen to work with nanometer base units
From: Stephen Ecob <stephen DOT ecob AT sioi DOT com DOT au>
To: geda-user AT delorie DOT com
Reply-To: geda-user AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: geda-user AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

--f46d0437454755aaab04c626e820
Content-Type: text/plain; charset=ISO-8859-1

On Wed, Aug 1, 2012 at 4:46 AM, Kovacs Levente <leventelist AT gmail DOT com> wrote:
> On Tue, 31 Jul 2012 12:42:53 +1000
> Stephen Ecob <stephen DOT ecob AT sioi DOT com DOT au> wrote:
>
>> For those of you who use Darrell Harmon's very useful "footgen"
>> script, here's an updated version.
>> The changes are:
>>
>> # Changed fundamental units from centimils to nanometers
>>
>> # Changed flags from integers to strings (as per newer format)
>
> Hurray! Thanks for doing that! I use it to generate my footprints. Does the
> file format changed? If I put there something without units... will it be
> interpreted as nm or centimils?

You're welcome!
You guessed it, distances specified with no unit will now be
interpreted as nm instead of cmil.
That doesn't seem to be a problem for the distributed footprintdata
file as all distances have units specified (as far as I can see).
I can't easily change the code to interpret numbers without units as
nanometers as that causes others unit-less numbers such as "number of
pins" to be multiplied by 254000 :(

Attached is a further update that corrects some additional hard coded
distances that I failed to spot earlier.

Stephen Ecob
Silicon On Inspiration
Sydney Australia
www.sioi.com.au
Spartan 6 LX25 with 2GB DDR3 DIMM for $299:
http://www.sioi.com.au/shop/product_info.php/cPath/24/products_id/55

--f46d0437454755aaab04c626e820
Content-Type: application/octet-stream; name="footgen.py"
Content-Disposition: attachment; filename="footgen.py"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_h5bi3uay1

IyEvdXNyL2Jpbi9weXRob24KIyBwYWNrYWdlLnB5CiMgQ29weXJpZ2h0IChDKSAyMDA1LTIwMDcg
RGFycmVsbCBIYXJtb24KIyBHZW5lcmF0ZXMgZm9vdHByaW50cyBmb3IgUENCIGZyb20gdGV4dCBk
ZXNjcmlwdGlvbgojIFRoZSBHUEwgYXBwbGllcyBvbmx5IHRvIHRoZSBweXRob24gc2NyaXB0cy4K
IyB0aGUgb3V0cHV0IG9mIHRoZSBwcm9ncmFtIGFuZCB0aGUgZm9vdHByaW50IGRlZmluaXRpb24g
ZmlsZXM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MF0sXAogICAgICAgICAgICBb
IndpZHRoIiwwXSxcCiAgICAgICAgICAgIFsiaGVpZ2h0IiwwXSxcCiAgICAgICAgICAgIFsicmVm
ZGVzeCIsMF0sXAogICAgICAgICAgICBbInJlZmRlc3kiLDBdLFwKICAgICAgICAgICAgWyJza2V3
IiwwXSxcCiAgICAgICAgICAgIFsicmVjdCIsMF0sXAogICAgICAgICAgICBbImRyaWxsIiwwXV0K
CiMgQkdBIHJvdyBuYW1lcyAyMCB0b3RhbApyb3duYW1lID0gWydBJywgJ0InLCAnQycsICdEJywg
J0UnLCAnRicsICdHJywgJ0gnLCAnSicsXAogICAgICAgICAgICdLJywgJ0wnLCAnTScsICdOJywg
J1AnLCAnUicsICdUJywgJ1UnLCAnVicsICdXJywgJ1knXQoKIyBnZW5lcmF0ZSBiYWxsIG5hbWUg
ZnJvbSByb3cgYW5kIGNvbHVtbiAoZm9yIEJHQSkKZGVmIGJhbGxuYW1lKGNvbCwgcm93KToKICAg
IGJhbGwgPSAiIgogICAgIyBjYW4gaGFuZGxlIHVwIHRvIGJhbGwgWVkKICAgIHdoaWxlIHJvdz4y
MDoKICAgICAgICBiYWxsPXJvd25hbWVbKHJvdy8yMCkgLSAxXQogICAgICAgIHJvdyA9IHJvdyUy
MAogICAgcmV0dXJuIGJhbGwrcm93bmFtZVtyb3ctMV0rc3RyKGNvbCkKCiMgZmluZCBYIGFuZCBZ
IHBvc2l0aW9uIG9mIGJhbGwgZnJvbSBuYW1lCmRlZiBiYWxscG9zKGJhbGxfbmFtZSk6CiAgICBj
b2wgPSAiIgogICAgcm93ID0gMAogICAgZm9yIGNoYXIgaW4gYmFsbF9uYW1lOgogICAgICAgIGlm
IGNoYXIuaXNkaWdpdCgpOgogICAgICAgICAgICBjb2wgPSBjb2wrY2hhcgogICAgICAgIGlmIGNo
YXIuaXNhbHBoYSgpOgogICAgICAgICAgICByb3cgPSByb3cgKiAyMAogICAgICAgICAgICBjb3Vu
dCA9IDEKICAgICAgICAgICAgZ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ICBwcmludCAiIgogICAgcmV0dXJuICIiICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAKCmRlZiBpbnF1b3Rlcyhvcmlnc3RyaW5nKToKICAgIHF1b3RlcG9z
ID0gcmUuc2VhcmNoKCJcIi4qXCIiLCBvcmlnc3RyaW5nKQogICAgaWYgcXVvdGVwb3M6CiAgICAg
ICAgcmV0dXJuIG9yaWdzdHJpbmdbcXVvdGVwb3Muc3RhcnQoKSsxOnF1b3RlcG9zLmVuZCgpLTFd
CiAgICByZXR1cm4gIiIKCiMgY29udmVydCB2YWx1ZXMgZnJvbSBzb3VyY2UgdW5pdHMgaW50byBu
YW5vbWV0ZXJzCmRlZiBzdHIycGNidW5pdHMoZGlzdCk6CiAgICBudW1iZXIgPSByZS5zZWFyY2go
J1stPzAtOVwuXSsnLCBkaXN0KQogICAgaWYgbnVtYmVyOgogICAgICAgIHZhbCA9IGZsb2F0KG51
bWJlci5ncm91cCgpKQogICAgZWxzZToKICAgICAgICByZXR1cm4gMAogICAgaWYgZGlzdFtudW1i
ZXIuZW5kKCk6XS5maW5kKCJtbSIpIT0tMToKICAgICAgICByZXR1cm4gaW50KDAuNSArIDEwMDAw
MDAgKiB2YWwpCiAgICBlbGlmIGRpc3RbbnVtYmVyLmVuZCgpOl0uZmluZCgibWlsIikhPS0xOgog
ICAgICAgIHJldHVybiBpbnQoMC41ICsgdmFsICogMjUuNCAqIDEwMDApCiAgICBlbGlmIGRpc3Rb
bnVtYmVyLmVuZCgpOl0uZmluZCgiaW4iKSE9LTE6CiAgICAgICAgcmV0dXJuIGludCgwLjUgKyB2
YWwgKiAyNS40ICogMTAwMDAwMCkKICAgIHJldHVybiBpbnQoMC41ICsgdmFsKQoKaW1wb3J0IHN5
cwojaW1wb3J0IHN0cmluZwppbXBvcnQgcmUKCiMgb3BlbiBpbnB1d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xpbmUuZmluZChhdHRyaWJ1dGVbMF0pIT0tMToKICAgICAgICAgICAgYXR0cmli
dXRlWzFdPWlucXVvdGVzKGxpbmUpCiAgICAgICAgICAgIGlmIG5vdCBhdHRyaWJ1dGVbMV06CiAg
ICAgICAgICAgICAgICBhdHRyaWJ1dGVbMV09c3RyMnBjYnVuaXRzKGxpbmUpCiAgICAgICAgICAg
IHZhbGlkbGluZSA9IDEKICAgICAgICAgICAgYnJlYWsKICAgIGlmIGF0dHJpYnV0ZVswXSA9PSAi
cGFydCI6CiAgICAgICAgZmlsZW5hbWUgPSBmaW5kYXR0cihhdHRyaWJ1dGVzLCJlbGVtZW50ZGly
IikrIi8iK2ZpbmRhdHRyKGF0dHJpYnV0ZXMsInBhcnQiKQogICAgICAgIHByaW50ICJnZW5lcmF0
ZWQgJXMiICUgZmlsZW5hbWUKICAgICAgICBvdXRwdXRfZmlsZSA9IG9wZW4oZmlsZW5hbWUsICJ3
IikKICAgICAgICBvdXRwdXRfZmlsZS53cml0ZShnZW5wYXJ0KGF0dHJpYnV0ZXMpKQogICAgICAg
IG91dHB1dF9maWxlLmNsb3NlKCkKICAgICAgICB2YWxpZGxpbmUgPSAxCiAgICBpZiBub3QgdmFs
aWRsaW5lOgogICAgICAgIHByaW50ICJJZ25vcmluZyBnYXJiYWdlIGF0IGxpbmUgJWQgOiVzIiAl
IChsaW5lbnVtLCBsaW5lKQoJCQkKcHJpbnQgIiVkIGxpbmVzIHJlYWQiICUgbGluZW51bQpzeXMu
ZXhpdCgwKQo=
--f46d0437454755aaab04c626e820--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019