kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #23068
Re: PATCH: Set SMD attribute in footprint wizard
Hi Miguel,
I'm new to bazaar and that's the reason I started by just submitting patch
files but for any further feature addition I'll send a branch for review.
Yes the purpose of this function was to perform a ceil. Either of these
implementations is good for me given that they have the same complexity and
the same result.
Cheers,
Mikael Arguedas
On Fri, Feb 12, 2016 at 1:31 AM, Miguel Angel Ajo Pelayo <
majopela@xxxxxxxxxx> wrote:
> Hi, Mikael, I haven’t fully looked at the patch, it would be easier if you
> can send a branch for review via launchpad.
>
> But, Could you explain those changes:
>
> === modified file 'pcbnew/scripting/plugins/qfp_wizard.py'
> --- pcbnew/scripting/plugins/qfp_wizard.py 2016-02-11 15:02:37 +0000
> +++ pcbnew/scripting/plugins/qfp_wizard.py 2016-02-12 03:39:11 +0000
> @@ -113,6 +113,8 @@
> self.draw.SetLayer(pcbnew.F_CrtYd)
> sizex = (lim_x + cmargin) * 2 + pad_length
> sizey = (lim_y + cmargin) * 2 + pad_length
> + sizex = (int(sizex/100000)+1)*100000
> + sizey = (int(sizey/100000)+1)*100000
>
>
> --- pcbnew/scripting/plugins/zip_wizard.py 2016-02-11 15:02:37 +0000
> +++ pcbnew/scripting/plugins/zip_wizard.py 2016-02-12 03:31:52 +0000
> @@ -106,6 +106,8 @@
> thick = self.draw.GetLineThickness()
> sizex = (pin1posX + cmarginx) * 2 + pad_Hsize + thick
> sizey = (pin1posY + cmarginy) * 2 + pad_Vsize + thick
> + sizex = (int(sizex/100000)+1)*100000
> + sizey = (int(sizey/100000)+1)*100000
>
>
>
> The semantics for size x/y seem very different. :)
>
> Also, are you trying to round here?
> + sizex = (int(sizex/100000)+1)*100000
> + sizey = (int(sizey/100000)+1)*100000
>
> Wouldn’t it be better like
> sizex = (int((sizex+(100000-1))/100000))*100000
> (if you were trying to do a ceil?)
>
>
> Cheers,
> Miguel Ángel
>
>
> On 12 Feb 2016, at 05:03, Mikael Arguedas <mikael.arguedas@xxxxxxxxx>
> wrote:
>
> Hi guys,
>
> Here is the updated patch including changes from
> https://lists.launchpad.net/kicad-developers/msg23059.html
> This patch fixes the following KLC violations in the generated footprints:
> - fixes the text size as specified in rule 6.9
> - rounds the courtyard position on a 0.05mm grid as specified in rule 6.6
> - set the attribute for SMD components as specified in rule 10.5
>
> Cheers,
> Mikael Arguedas
>
> On Thu, Feb 11, 2016 at 6:54 PM, Mikael Arguedas <
> mikael.arguedas@xxxxxxxxx> wrote:
>
>> Hi guys,
>>
>> Sorry for spamming.
>> This patch sets the footprint attibute to SMD if needed. This allows the
>> generated footprints to comply with KLC rule 10.5.
>>
>> Cheers,
>> Mikael Arguedas
>>
>
> <fixWizards.patch>_______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to : kicad-developers@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help : https://help.launchpad.net/ListHelp
>
>
>
Follow ups
References