Author Topic: NOW OPEN SOURCE!!! swill's plate building tool [builder.swillkb.com]  (Read 2721765 times)

0 Members and 1 Guest are viewing this topic.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3356
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: NOW OPEN SOURCE!!! swill's plate building tool [builder.swillkb.com]
« Reply #2200 on: Tue, 12 March 2019, 11:54:19 »
Yes I found my mistake, the key is stepped. I forgot to add that into KLE.


Code: [Select]
["¨\n`","!\n1","\"\n2","£\n3","$\n4","%\n5","^\n6","&\n7","*\n8","(\n9",")\n0","_\n-","+\n=",{w:2},"Backspace"],
[{w:1.5},"Tab","Q","W","E","R","T","Y","U","I","O","P","{\n[","}\n]",{x:0.25,w:1.25,h:2,w2:1.5,h2:1,x2:-0.25},"Enter"],
[{w:1.25,w2:1.75,l:true},"Caps Lock",{x:0.5},"A","S","D","F","G","H","J","K","L",":\n;","@\n'","~\n#"],
[{w:1.25},"Shift","|\n\\","Z","X","C","V","B","N","M","<\n,",">\n.","?\n/",{w:2.75},"Shift"],
[{w:1.5},"Ctrl","Win",{w:1.5},"Alt",{a:7,w:7},"",{a:4,w:1.5},"Win","Menu",{w:1.5},"Ctrl"]

I'll make final verifications but it seems OK now.
Show Image


Thanks Swill !

Ah, ok.  Good catch.   :thumb:

Offline Primuds

  • Posts: 1
  • Location: Singapore
Re: NOW OPEN SOURCE!!! swill's plate building tool [builder.swillkb.com]
« Reply #2201 on: Thu, 14 March 2019, 07:21:14 »
Hi Geekhack,
I am a fairly new guy to the custom keyboard scene, but I am really interested in making my own custom. As such, I have used Swillkb's tool to make a plate for a 75% layout. I am planning on using a kbd75 PCB with a 3d printed case as I wanted to have in-switch and underglow lighting. However, I am unsure if the cutouts on the rendering tool will line up correctly with a 75% layout pcb like the kbd75 or xd84. I think most boards use standardized spacing between switches, but is anybody aware if I will run into any issues? I would really appreciate if anybody has any feedback.  Thank you! ;D

Offline ctrl

  • Posts: 247
  • Location: UmeŚ, Sweden
Re: NOW OPEN SOURCE!!! swill's plate building tool [builder.swillkb.com]
« Reply #2202 on: Thu, 14 March 2019, 07:34:12 »
Thank you very much!

Another question, when opened up in LibreCad and saved in the 2007 file format, the measurements are actually 94.92mm by 285.37 instead of 95.252 mm by 285.752 mm on the swillkb website. This is when creating a pok3r plate. What is the correct measurement?

I would have to look into that one.  It could be that kerf is messing with my calculation on the site, but I would expect it to be consistent in terms of how the two numbers are different in both dimensions, so that doesn't seem like it would be the case.   

Are you use custom polygons at all?  Do any of them overlap the outer edge of the plate?  I am wondering if I am not updating the bounds correctly (how I calculate the width and height) after the final operations (ie: cut | add) on the custom polygons.  I will have to dig into this a bit.  Anything special you were doing?

Were you able to find out what's causing this? I'm running into the same thing right now actually. I first noticed it when I uploaded the dxf file I exported from swillkb to bigbluesaw.

I'm totally messing about with custom polygons. I'm attempting a half-plate so I've cut away all alphas including the numerical row. As well as using superellipse to round corners. (See my other question in the previous comment.)

I'd like to know more about this because I'm hesitant to have plates cut for a sackful of gold if there's something messing up the measurements.

Can you link me what you are trying to do so I can review?  I don't believe I have applied kerf to the custom polygons, so if you are going to be doing anything that is pressure fit into a custom polygon, you may want to do a small test before you do a full build.

If you can give me a feel for what you are doing I can try to support.  Cheers...

I solved the inner cutout by doing it in LibreCAD instead. It was faster that way. However, it appears swillkb doesn't want to return correct plate measurements. Something happens that alter them, like merlin64 also wrote: "when opened up in LibreCad and saved in the 2007 file format, the measurements are actually 94.92mm by 285.37 instead of 95.252 mm by 285.752 mm on the swillkb website."
« Last Edit: Thu, 14 March 2019, 07:41:36 by ctrl »

Offline Slavfot

  • Posts: 52
  • Location: Sweden
Re: NOW OPEN SOURCE!!! swill's plate building tool [builder.swillkb.com]
« Reply #2203 on: Sun, 17 March 2019, 13:12:37 »
Hi!
I'm really impressed with your tool and have used it alot!
I'm a CAD user professionally and use solidworks to design keyboards on my spare time.
I''m wondering how you can get the x and y coordinates for each switch cutout from the KLE raw data?
I would like to import the raw data from KLE to an excel document that i can use with a table driven variable pattern in Solidworks.
In the excel document i would like to get X coordinates in one column and Y coordinates in the next column. And also the rotation data in columns.
Is there any way you could help me with this or at least point me in the right direction of achieving this?
I'm no programmer but i can copy paste and edit code and I'm always interested in learning new stuff.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3356
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: NOW OPEN SOURCE!!! swill's plate building tool [builder.swillkb.com]
« Reply #2204 on: Sun, 17 March 2019, 17:08:12 »
Hi!
I'm really impressed with your tool and have used it alot!
I'm a CAD user professionally and use solidworks to design keyboards on my spare time.
I''m wondering how you can get the x and y coordinates for each switch cutout from the KLE raw data?
I would like to import the raw data from KLE to an excel document that i can use with a table driven variable pattern in Solidworks.
In the excel document i would like to get X coordinates in one column and Y coordinates in the next column. And also the rotation data in columns.
Is there any way you could help me with this or at least point me in the right direction of achieving this?
I'm no programmer but i can copy paste and edit code and I'm always interested in learning new stuff.
This is absolutely possible, but you will have to get into the open source code a bit to do it. Everything you are looking for is already calculated and stored in the main KAD object.

I am not at a computer right now, but when I have a free few minutes I could write you a program to get you started.

If you want to start looking at it, review the 'Draw()' function in this file. It is the main sequence of operations to build the keyboard. https://github.com/swill/kad/blob/master/kad.go

You care mainly about the state of the KAD.Layout object after the ParseLayout() and maybe the DrawLayout() functions. Parse layout builds all they Key objects and fills in the details about rotations and such. DrawLayout() handles things like absolutely positioned keys and such which may be relevant for you.

Keep in mind that I have a static (I think 10mm) zone which I call the DMZ which is empty space outside the final drawing so the edges are not right against the edge of the artboard (or whatever it is called). Depending on if you want the X and Y to be relative to the top left of the workspace/artboard, then you will likely have to subtract the DMZ values from the coords you have for each switch. Hope that makes sense.

Have a look at the code and get a feel for what you need. If you can send me a few details about what the format of the output you need is, I should be able to get you going with some initial code anyway.

Cheers...

Sent from my ONEPLUS A5000 using Tapatalk


Offline Slavfot

  • Posts: 52
  • Location: Sweden
Re: NOW OPEN SOURCE!!! swill's plate building tool [builder.swillkb.com]
« Reply #2205 on: Mon, 25 March 2019, 06:54:47 »
The coordinates i want should be relative to the top left corner like in KLE.
And i want the coordinate and rotation to be relative to the center of the switch, like in my picture.
I use an sacrificial extrude feature that is being copied with the variable driven table pattern.
This sacrifical feature is being copied and then deleted after all the switch holes have been copied with the pattern.
In the picture you can see the excel document that my CAD program drives the pattern from.
It needs to have every switch on a separate row and the x, y and rotation in columns next to it