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

0 Members and 1 Guest are viewing this topic.

Offline sethk_

  • Grand Master Wizard Pizza
  • * Esteemed Elder
  • Posts: 2710
  • Location: Pittsburgh, Pennsylvania
  • www.kbdhub.com
    • My webstore
Re: swill's plate building tool
« Reply #250 on: Thu, 08 January 2015, 22:45:11 »

on licensing:

isn't this enough? http://choosealicense.com/licenses/no-license/

you're protected by copyright.  anyone who uses your code without permission is in violation and liable to be sued.

i think the only weird issue would be how to handle contributions; i suspect each contribution will have it's own copyright and each contributor has legal leverage to block usage of the software.

No, I don't think that is realistic for software licensing.  I think I have to go with something more like creative commons where it is free for people for personal use, but not for commercial use.  I have to review the links that were sent to me when we were discussing this a few pages back because others did suggest some potential licenses and I have not had a chance to research them. 

As for contributions, they would be falling under the same licence.  They would not have ownership of the code but would be able to use it for non-commercial uses.  For commercial uses, they would have to contact me and we would have to work out a licensing deal of some kind.  Once I release this and get this sorted out, I will be putting the code on github and people will be able to contribute by submitting pull requests...
I don't know how copyright works, but couldn't you make a terms and agreement that you automatically agree to buy using it?
Honestly I don't know, I need to do a bunch of reading before I will know anything on this subject. I have never had to worry about this before.
I just am excited to play around with it, but it would be scummy to use it for commercial use

Offline Dihedral

  • Posts: 827
  • Location: United Kingdom
  • Mostly Harmless
Re: swill's plate building tool
« Reply #251 on: Fri, 09 January 2015, 02:04:12 »
I love what you are doing here. I am an intermediate-ish python programmer and would like to see the code if it is available but I didn't see a link to source? If you don't want to release it that's totally fine BTW.

My plan is to open source it once I get the initial launch finished.  That being said, some very valid concerns have been raised about me open sourcing the code without putting thought into the license I plan to associate with the project.  I need to be a bit careful how I open source it because I need to ensure that companies dont just gack the code and embed it in their websites for profit.  I want it to be free to use for people who are using it for non-commercial reasons and I need to figure out some sort of licensing for people who want to use it for commercial reasons.  This is obviously not my area of expertise as I completely neglected to think about this until it was brought up in this thread.  I am a little too altruistic and maybe even naive when it comes to that sort of thing, so I do need to put some thought into it before I release the code...  Make sense?

Thats a fair concern. Not a lawyer but I believe This will cover that.

Offline tbc

  • Posts: 2365
ALL zombros wanted:  dead or undead or dead-dead.

Offline Dihedral

  • Posts: 827
  • Location: United Kingdom
  • Mostly Harmless
Re: swill's plate building tool
« Reply #253 on: Fri, 09 January 2015, 11:17:29 »
https://wiki.creativecommons.org/Before_Licensing#Make_sure_the_material_is_appropriate_for_CC_licensing.

?

Dammit. I always used CC on my programs, and assumed you could do that. So, I found this that seems to apply to software but I have never heard of it before. It seems strange, but there seem to be no software equivalents to the previously linked creative commons license.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #254 on: Fri, 09 January 2015, 20:30:59 »
Alright, I have done a bunch of research on this on the train on my way home.

If I am going to "open source" the software, I can not treat any groups of people differently. This means that I can not treat commercial and noncommercial differently.

That being said, there are some interesting licenses out there that make it harder for commercial users to just gack the code for profit.

I will most likely be launching this with the AGPL license. Basically this is an open source license that allows for the code to be modified and republished, but it requires that the source code of the republished work be downloadable.

This is good for us as a community because any work that is done on the tool is required to be made available. It also makes it less likely that a company will just come along and take the code for commercial use and embed it in their app because they would then have to make their app's source code available.  This will likely be enough of a deterrent for most companies unless they are very serious.

Interestingly, this license does not restrict a company from contacting me, the author, and requesting to purchase rights to the application under a different license. That's what I read anyway. If that is the case, it still gives a serious company a way to embed the application without releasing their source assuming we can come to an agreement.

So far this seems to be the best option.

Offline Melvang

  • Exquisite Lord of Bumfluff
  • * Maker
  • Posts: 4398
  • Location: Waterloo, IA
  • Melvang's Desktop Customs
Re: swill's plate building tool
« Reply #255 on: Fri, 09 January 2015, 20:59:47 »
Alright, I have done a bunch of research on this on the train on my way home.

If I am going to "open source" the software, I can not treat any groups of people differently. This means that I can not treat commercial and noncommercial differently.

That being said, there are some interesting licenses out there that make it harder for commercial users to just gack the code for profit.

I will most likely be launching this with the AGPL license. Basically this is an open source license that allows for the code to be modified and republished, but it requires that the source code of the republished work be downloadable.

This is good for us as a community because any work that is done on the tool is required to be made available. It also makes it less likely that a company will just come along and take the code for commercial use and embed it in their app because they would then have to make their app's source code available.  This will likely be enough of a deterrent for most companies unless they are very serious.

Interestingly, this license does not restrict a company from contacting me, the author, and requesting to purchase rights to the application under a different license. That's what I read anyway. If that is the case, it still gives a serious company a way to embed the application without releasing their source assuming we can come to an agreement.

So far this seems to be the best option.

If my understanding of your understanding is correct, this sounds like a pretty good setup for it.
OG Kishsaver, Razer Orbweaver clears and reds with blue LEDs, and Razer Naga Epic.   "Great minds crawl in the same sewer"  Uncle Rich

Offline sethk_

  • Grand Master Wizard Pizza
  • * Esteemed Elder
  • Posts: 2710
  • Location: Pittsburgh, Pennsylvania
  • www.kbdhub.com
    • My webstore
Re: swill's plate building tool
« Reply #256 on: Fri, 09 January 2015, 21:03:03 »
Alright, I have done a bunch of research on this on the train on my way home.

If I am going to "open source" the software, I can not treat any groups of people differently. This means that I can not treat commercial and noncommercial differently.

That being said, there are some interesting licenses out there that make it harder for commercial users to just gack the code for profit.

I will most likely be launching this with the AGPL license. Basically this is an open source license that allows for the code to be modified and republished, but it requires that the source code of the republished work be downloadable.

This is good for us as a community because any work that is done on the tool is required to be made available. It also makes it less likely that a company will just come along and take the code for commercial use and embed it in their app because they would then have to make their app's source code available.  This will likely be enough of a deterrent for most companies unless they are very serious.

Interestingly, this license does not restrict a company from contacting me, the author, and requesting to purchase rights to the application under a different license. That's what I read anyway. If that is the case, it still gives a serious company a way to embed the application without releasing their source assuming we can come to an agreement.

So far this seems to be the best option.

If my understanding of your understanding is correct, this sounds like a pretty good setup for it.
That license is almost prefect for the plate builders use.

Offline tbc

  • Posts: 2365
Re: swill's plate building tool
« Reply #257 on: Fri, 09 January 2015, 21:28:41 »
http://www.freecadweb.org/wiki/index.php?title=Licence#Impact_of_the_licences

swill, did you check to see that you're not violating the freecad licenses?

it specifically mentions that gpl is valid, as is reusung lgpl.  i've only knowingly seen agpl once before and i'm not sure how it relates to those 2 mentioned ones.
ALL zombros wanted:  dead or undead or dead-dead.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #258 on: Fri, 09 January 2015, 21:28:46 »
yep, this is looking pretty good.  i finally got through the whole license and i am pretty comfortable with it.  i would hold the copyright to the code and as such would have control of the license.  by holding the copyright I would be able to add 'additional permissions' to the license if i need to.  this means that i can wave the need for a specific company to require the publishing of their code if we can come to an agreement and this license will uphold those terms.

i am pretty happy with this license.  i think i can officially say that i will be making the source available under this license.  sweet!  one less thing to worry about...  :)

Offline tbc

  • Posts: 2365
ALL zombros wanted:  dead or undead or dead-dead.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #260 on: Fri, 09 January 2015, 21:36:15 »
http://www.freecadweb.org/wiki/index.php?title=Licence#Impact_of_the_licences

swill, did you check to see that you're not violating the freecad licenses?

it specifically mentions that gpl is valid, as is reusung lgpl.  i've only knowingly seen agpl once before and i'm not sure how it relates to those 2 mentioned ones.

No, we are good.  AGPL is basically a GPL license with one additional clause to handle code that is run on a server (like mine).  FreeCAD by design is not networked and can not be used over a network, so they only mention GPL since that is really the only aspect that applies to them.

There is provisions between the GPL licenses that basically says that they respect the authority of the other GPL type licenses (or something along those lines).  Also, I am not modifying any of those core libraries, so I do not have to worry about their licenses for the most part.  I am just using the libraries.

All things considered, this is pretty much the perfect license for this...

Edit:
FreeCAD actually goes so far as to wave some of the conditions of the license right off the top:

"Commercial developers can use FreeCAD as the groundwork for their own extension modules for special purposes and are not forced to make their modules open source."
« Last Edit: Fri, 09 January 2015, 21:38:29 by swill »

Offline sethk_

  • Grand Master Wizard Pizza
  • * Esteemed Elder
  • Posts: 2710
  • Location: Pittsburgh, Pennsylvania
  • www.kbdhub.com
    • My webstore
Re: swill's plate building tool
« Reply #261 on: Mon, 12 January 2015, 23:12:06 »
Stupid question, but will this work with making acrylic plates and other plastics? I seem to like acrylic and plastic plates better, and this would be awesome if they work.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #262 on: Mon, 12 January 2015, 23:35:10 »
Stupid question, but will this work with making acrylic plates and other plastics? I seem to like acrylic and plastic plates better, and this would be awesome if they work.

Yes it will, but I have to do some tests with my cutouts because I know the kerf with metals and plastics are different so I need to make sure that my cutouts will work with everything.  All my cutouts are drawn to cherry spec, but that does not mean that they will be perfect first shot...

Offline sethk_

  • Grand Master Wizard Pizza
  • * Esteemed Elder
  • Posts: 2710
  • Location: Pittsburgh, Pennsylvania
  • www.kbdhub.com
    • My webstore
Re: swill's plate building tool
« Reply #263 on: Tue, 13 January 2015, 00:06:25 »

Stupid question, but will this work with making acrylic plates and other plastics? I seem to like acrylic and plastic plates better, and this would be awesome if they work.

Yes it will, but I have to do some tests with my cutouts because I know the kerf with metals and plastics are different so I need to make sure that my cutouts will work with everything.  All my cutouts are drawn to cherry spec, but that does not mean that they will be perfect first shot...
Ok, thanks!

Offline MOZ

  • KING OF THE NEWBIES
  • * Maker
  • Posts: 3981
  • Location: Jo'burg
  • Busy making stuff
Re: swill's plate building tool
« Reply #264 on: Tue, 13 January 2015, 12:08:51 »
Stupid question, but will this work with making acrylic plates and other plastics? I seem to like acrylic and plastic plates better, and this would be awesome if they work.

Yes it will, but I have to do some tests with my cutouts because I know the kerf with metals and plastics are different so I need to make sure that my cutouts will work with everything.  All my cutouts are drawn to cherry spec, but that does not mean that they will be perfect first shot...

I've mentioned common acrylic kerf for the thickness used somewhere in the start of the thread. My experience, has been that using the Cherry spec results in slightly loose cutouts, and slight compenstion in CAD is required.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #265 on: Tue, 13 January 2015, 13:41:18 »
Stupid question, but will this work with making acrylic plates and other plastics? I seem to like acrylic and plastic plates better, and this would be awesome if they work.

Yes it will, but I have to do some tests with my cutouts because I know the kerf with metals and plastics are different so I need to make sure that my cutouts will work with everything.  All my cutouts are drawn to cherry spec, but that does not mean that they will be perfect first shot...

I've mentioned common acrylic kerf for the thickness used somewhere in the start of the thread. My experience, has been that using the Cherry spec results in slightly loose cutouts, and slight compenstion in CAD is required.

Ya, I need to figure out how to automate that modification to the cutouts so I can have someone specify their material and it will adjust the tolerances according to what the expected kerf will be.  I have not done that yet and I need to think about how I am going to handle that...

Offline Beelzebro

  • Posts: 17
Re: swill's plate building tool
« Reply #266 on: Tue, 13 January 2015, 13:56:08 »
just swinging by this thread to say this is a brilliant idea and would be a really helpful tool for a lot of people including myself. i'll keep an eye on this thread, good luck with the development! sorry i don't have anything useful to contribute as i know nothing about CAD...

Offline p3lim

  • Posts: 106
  • Location: Norway

Offline Dihedral

  • Posts: 827
  • Location: United Kingdom
  • Mostly Harmless

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #269 on: Wed, 14 January 2015, 11:34:30 »
Someone posted this on reddit today:

https://www.reddit.com/r/MechanicalKeyboards/comments/2seon0/i_wrote_a_script_that_makes_a_keyboard_plate_in/

This could be swill, I guess....

Interestingly, this is not actually me...  haha...

Apparently someone else is working on this too...

Offline sethk_

  • Grand Master Wizard Pizza
  • * Esteemed Elder
  • Posts: 2710
  • Location: Pittsburgh, Pennsylvania
  • www.kbdhub.com
    • My webstore
Re: swill's plate building tool
« Reply #270 on: Wed, 14 January 2015, 13:29:08 »

Someone posted this on reddit today:

https://www.reddit.com/r/MechanicalKeyboards/comments/2seon0/i_wrote_a_script_that_makes_a_keyboard_plate_in/

This could be swill, I guess....

Interestingly, this is not actually me...  haha...

Apparently someone else is working on this too...
I hVent checked it out, but yours probably has better support and more options.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #271 on: Wed, 14 January 2015, 17:37:01 »
Just a quick update since I have not given you guys an update in a little while.  I got put a little behind because my server got hacked and was basically getting bot farmed.  Teaches me for having a short dictionary word as my root password.  Anyway, I am rebuilding my server environment and I am writing documentation for it at the same time (figured I would take this opportunity to make sure the setup is easily reproducible).

More delays and more work, but I am slowly making progress.  I also have not had as much time the last couple days because our nights have been a bit tough with the baby and I have been exhausted.  Hopefully I can get the server rebuilt tonight and I can start working on fun stuff again.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #272 on: Wed, 14 January 2015, 23:51:23 »
One more minor update tonight.  I am now back where I was before the hack.  I am back up and running with a much cleaner and more secure server.  :)

I will finally be able to get back to the fun stuff.  Cheers...

Offline smellz

  • Posts: 17
  • Location: Ontario Canada
Re: swill's plate building tool
« Reply #273 on: Thu, 15 January 2015, 15:18:00 »
Someone posted this on reddit today:

https://www.reddit.com/r/MechanicalKeyboards/comments/2seon0/i_wrote_a_script_that_makes_a_keyboard_plate_in/

Hi everyone, I'm the author of this reddit post.
I had been toying with the idea for a while, but unfortunately never saw this thread. I had a lot of spare time during my Christmas break, so I did some research and wrote some python code.
My script will probably be annoying to use for most people, but it works. Some things are wrong with it (such as the cherry stab holes) but I'll be making a few improvements to it shortly.
Please let me know if you have any questions.
Thanks.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #274 on: Thu, 15 January 2015, 15:24:32 »
Someone posted this on reddit today:

https://www.reddit.com/r/MechanicalKeyboards/comments/2seon0/i_wrote_a_script_that_makes_a_keyboard_plate_in/

Hi everyone, I'm the author of this reddit post.
I had been toying with the idea for a while, but unfortunately never saw this thread. I had a lot of spare time during my Christmas break, so I did some research and wrote some python code.
My script will probably be annoying to use for most people, but it works. Some things are wrong with it (such as the cherry stab holes) but I'll be making a few improvements to it shortly.
Please let me know if you have any questions.
Thanks.

Thanks for jumping into this conversation.  I am sure the two of us can give valuable feedback to each other.  :)  The guys who have been contributing to this thread have added a lot of very interesting insight that will probably help both of us.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #275 on: Sun, 18 January 2015, 23:01:13 »
Alright, so this update has been a long time in coming.  I have been slowly chugging away at this, but the problem that I could not draw two CAD drawings at the same time really threw a wrench into my plans of having this available as a web application.

I am happy to announce that I have solved the problem and I now have a working application which can handle drawing more than one CAD at a time.

I will attach a flow diagram at the end, but here is the basic idea:
- On my server I have a Tornado application which acts as my webserver.  It basically hosts the website.
- When new drawing requests come in, the Tornado server will automatically spin up a new LXC container (which is basically running the exact same Tornado application) as a worker for that request and the parent server directs the LXC worker to actually draw the CAD.
- When the CAD is finished being drawn, the LXC worker will upload all the files into an AWS S3 bucket and will return to the parent server the metadata and where to find the files in S3.
- When the client requests to download the CAD files, the request is sent directly to S3 and the files are retrieved from S3 without ever actually hitting my server.
- In addition, if subsequent requests are made for the exact same layout (including holes, padding, etc, etc...) the server will see that the CAD has already been drawn, and it will return the request directly referencing the existing S3 files for that drawing.  For a cache hit, the two have to be identical, so even if legends on the layout changes (which does not affect the resulting CAD), it will miss the cache and redraw from scratch.
- Once an LXC worker has finished doing its work, it will automatically be destroyed.

That is basically it.  Here is a graphic to illustrate what I specified above...

87791-0

Offline heedpantsnow

  • * Esteemed Elder
  • Posts: 3692
  • Location: Orlando, FL
  • Old enough to know better
Re: swill's plate building tool
« Reply #276 on: Sun, 18 January 2015, 23:18:05 »
Niiiice. Efficient way to save cycles/storage. I can't wait to try it out!
I'm back.

Espresso machine overhaul: https://geekhack.org/index.php?topic=78261.0

Carbon Fiber keyboard base: https://geekhack.org/index.php?topic=54825

Offline Dihedral

  • Posts: 827
  • Location: United Kingdom
  • Mostly Harmless
Re: swill's plate building tool
« Reply #277 on: Mon, 19 January 2015, 02:04:02 »
Alright, so this update has been a long time in coming.  I have been slowly chugging away at this, but the problem that I could not draw two CAD drawings at the same time really threw a wrench into my plans of having this available as a web application.

I am happy to announce that I have solved the problem and I now have a working application which can handle drawing more than one CAD at a time.

I will attach a flow diagram at the end, but here is the basic idea:
- On my server I have a Tornado application which acts as my webserver.  It basically hosts the website.
- When new drawing requests come in, the Tornado server will automatically spin up a new LXC container (which is basically running the exact same Tornado application) as a worker for that request and the parent server directs the LXC worker to actually draw the CAD.
- When the CAD is finished being drawn, the LXC worker will upload all the files into an AWS S3 bucket and will return to the parent server the metadata and where to find the files in S3.
- When the client requests to download the CAD files, the request is sent directly to S3 and the files are retrieved from S3 without ever actually hitting my server.
- In addition, if subsequent requests are made for the exact same layout (including holes, padding, etc, etc...) the server will see that the CAD has already been drawn, and it will return the request directly referencing the existing S3 files for that drawing.  For a cache hit, the two have to be identical, so even if legends on the layout changes (which does not affect the resulting CAD), it will miss the cache and redraw from scratch.
- Once an LXC worker has finished doing its work, it will automatically be destroyed.

That is basically it.  Here is a graphic to illustrate what I specified above...

(Attachment Link)

Nice job! Very efficient. ETA for a release?

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #278 on: Mon, 19 January 2015, 06:32:41 »
Alright, so this update has been a long time in coming.  I have been slowly chugging away at this, but the problem that I could not draw two CAD drawings at the same time really threw a wrench into my plans of having this available as a web application.

I am happy to announce that I have solved the problem and I now have a working application which can handle drawing more than one CAD at a time.

I will attach a flow diagram at the end, but here is the basic idea:
- On my server I have a Tornado application which acts as my webserver.  It basically hosts the website.
- When new drawing requests come in, the Tornado server will automatically spin up a new LXC container (which is basically running the exact same Tornado application) as a worker for that request and the parent server directs the LXC worker to actually draw the CAD.
- When the CAD is finished being drawn, the LXC worker will upload all the files into an AWS S3 bucket and will return to the parent server the metadata and where to find the files in S3.
- When the client requests to download the CAD files, the request is sent directly to S3 and the files are retrieved from S3 without ever actually hitting my server.
- In addition, if subsequent requests are made for the exact same layout (including holes, padding, etc, etc...) the server will see that the CAD has already been drawn, and it will return the request directly referencing the existing S3 files for that drawing.  For a cache hit, the two have to be identical, so even if legends on the layout changes (which does not affect the resulting CAD), it will miss the cache and redraw from scratch.
- Once an LXC worker has finished doing its work, it will automatically be destroyed.

That is basically it.  Here is a graphic to illustrate what I specified above...

(Attachment Link)

Nice job! Very efficient. ETA for a release?
Soon™. I still have a lot of little things to take care of, so hopefully I can get through them quickly.  The next couple months are a bit crazy around here because my wife is finishing osteo school.  I have the baby a lot so she can study, so my time is pretty limited right now. As long as I don't hit any more show stoppers like this I should be able to get this out the door in the next couple weeks.

Sorry for the delays and all the #hype. I am excited about this too, but it has been slower progress than I was hoping.

Offline heedpantsnow

  • * Esteemed Elder
  • Posts: 3692
  • Location: Orlando, FL
  • Old enough to know better
Re: swill's plate building tool
« Reply #279 on: Mon, 19 January 2015, 07:46:46 »

Alright, so this update has been a long time in coming.  I have been slowly chugging away at this, but the problem that I could not draw two CAD drawings at the same time really threw a wrench into my plans of having this available as a web application.

I am happy to announce that I have solved the problem and I now have a working application which can handle drawing more than one CAD at a time.

I will attach a flow diagram at the end, but here is the basic idea:
- On my server I have a Tornado application which acts as my webserver.  It basically hosts the website.
- When new drawing requests come in, the Tornado server will automatically spin up a new LXC container (which is basically running the exact same Tornado application) as a worker for that request and the parent server directs the LXC worker to actually draw the CAD.
- When the CAD is finished being drawn, the LXC worker will upload all the files into an AWS S3 bucket and will return to the parent server the metadata and where to find the files in S3.
- When the client requests to download the CAD files, the request is sent directly to S3 and the files are retrieved from S3 without ever actually hitting my server.
- In addition, if subsequent requests are made for the exact same layout (including holes, padding, etc, etc...) the server will see that the CAD has already been drawn, and it will return the request directly referencing the existing S3 files for that drawing.  For a cache hit, the two have to be identical, so even if legends on the layout changes (which does not affect the resulting CAD), it will miss the cache and redraw from scratch.
- Once an LXC worker has finished doing its work, it will automatically be destroyed.

That is basically it.  Here is a graphic to illustrate what I specified above...

(Attachment Link)

Nice job! Very efficient. ETA for a release?
Soon. I still have a lot of little things to take care of, so hopefully I can get through them quickly.  The next couple months are a bit crazy around here because my wife is finishing osteo school.  I have the baby a lot so she can study, so my time is pretty limited right now. As long as I don't hit any more show stoppers like this I should be able to get this out the door in the next couple weeks.

Sorry for the delays and all the #hype. I am excited about this too, but it has been slower progress than I was hoping.

Bro, pretty much every project any of us does around here (including me) hits unforeseen snags and delays. I think it's awesome that you saw a need, said "I can do that", and got 'er done.
I'm back.

Espresso machine overhaul: https://geekhack.org/index.php?topic=78261.0

Carbon Fiber keyboard base: https://geekhack.org/index.php?topic=54825

Offline tjweir

  • * Exquisite Elder
  • Posts: 1039
  • Location: Toronto
Re: swill's plate building tool
« Reply #280 on: Mon, 19 January 2015, 08:36:20 »
I am happy to announce that I have solved the problem and I now have a working application which can handle drawing more than one CAD at a time.

Awesome, happy to help test it out if need be.

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #281 on: Mon, 19 January 2015, 08:45:33 »

Alright, so this update has been a long time in coming.  I have been slowly chugging away at this, but the problem that I could not draw two CAD drawings at the same time really threw a wrench into my plans of having this available as a web application.

I am happy to announce that I have solved the problem and I now have a working application which can handle drawing more than one CAD at a time.

I will attach a flow diagram at the end, but here is the basic idea:
- On my server I have a Tornado application which acts as my webserver.  It basically hosts the website.
- When new drawing requests come in, the Tornado server will automatically spin up a new LXC container (which is basically running the exact same Tornado application) as a worker for that request and the parent server directs the LXC worker to actually draw the CAD.
- When the CAD is finished being drawn, the LXC worker will upload all the files into an AWS S3 bucket and will return to the parent server the metadata and where to find the files in S3.
- When the client requests to download the CAD files, the request is sent directly to S3 and the files are retrieved from S3 without ever actually hitting my server.
- In addition, if subsequent requests are made for the exact same layout (including holes, padding, etc, etc...) the server will see that the CAD has already been drawn, and it will return the request directly referencing the existing S3 files for that drawing.  For a cache hit, the two have to be identical, so even if legends on the layout changes (which does not affect the resulting CAD), it will miss the cache and redraw from scratch.
- Once an LXC worker has finished doing its work, it will automatically be destroyed.

That is basically it.  Here is a graphic to illustrate what I specified above...

(Attachment Link)

Nice job! Very efficient. ETA for a release?
Soon. I still have a lot of little things to take care of, so hopefully I can get through them quickly.  The next couple months are a bit crazy around here because my wife is finishing osteo school.  I have the baby a lot so she can study, so my time is pretty limited right now. As long as I don't hit any more show stoppers like this I should be able to get this out the door in the next couple weeks.

Sorry for the delays and all the #hype. I am excited about this too, but it has been slower progress than I was hoping.

Bro, pretty much every project any of us does around here (including me) hits unforeseen snags and delays. I think it's awesome that you saw a need, said "I can do that", and got 'er done.

haha, ya...  i need to get this launched soon so i can start on my actual build projects.  :P

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #282 on: Mon, 19 January 2015, 10:43:39 »
Random question...

Should a switch opening be rotated if (height > width)?  I am going to be doing this for vertical keys (with or without stabilizers).  Also, does the direction the switch is rotated matter?  I know for normal switch opens it doesn't, but for ones with stabilizers, that may be a different story.  I am currently planning to rotate clockwise, but I could change that...

Offline jdcarpe

  • * Curator
  • Posts: 8852
  • Location: Odessa, TX
  • Live long, and prosper.
Re: swill's plate building tool
« Reply #283 on: Mon, 19 January 2015, 10:57:01 »
Random question...

Should a switch opening be rotated if (height > width)?  I am going to be doing this for vertical keys (with or without stabilizers).  Also, does the direction the switch is rotated matter?  I know for normal switch opens it doesn't, but for ones with stabilizers, that may be a different story.  I am currently planning to rotate clockwise, but I could change that...

Different keyboards (PCBs) do it different ways. I don't know that there is a best practice on which way to orient the stabilizer holes. :(

Also, some PCBs have the vertical switch aligned to the orientation of the stabilizer, and some keep the switch aligned with all the other switches in direction.
KMAC :: LZ-GH :: WASD CODE :: WASD v2 :: GH60 :: Alps64 :: JD45 :: IBM Model M :: IBM 4704 "Pingmaster"

http://jd40.info :: http://jd45.info


in memoriam

"When I was a kid, I used to take things apart and never put them back together."

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #284 on: Mon, 19 January 2015, 12:49:53 »
Different keyboards (PCBs) do it different ways. I don't know that there is a best practice on which way to orient the stabilizer holes. :(

Ok, I will add a way for the orientation to be overridden on a switch by switch bases so we can orient the stabilizers however we need to.

Also, some PCBs have the vertical switch aligned to the orientation of the stabilizer, and some keep the switch aligned with all the other switches in direction.

I didn't actually understand this.  can you give me a little better description of this so I can figure out how to deal with it.

Thx for your help.  :)

Offline Dihedral

  • Posts: 827
  • Location: United Kingdom
  • Mostly Harmless
Re: swill's plate building tool
« Reply #285 on: Mon, 19 January 2015, 13:00:07 »
Different keyboards (PCBs) do it different ways. I don't know that there is a best practice on which way to orient the stabilizer holes. :(

Ok, I will add a way for the orientation to be overridden on a switch by switch bases so we can orient the stabilizers however we need to.

Also, some PCBs have the vertical switch aligned to the orientation of the stabilizer, and some keep the switch aligned with all the other switches in direction.

I didn't actually understand this.  can you give me a little better description of this so I can figure out how to deal with it.

Thx for your help.  :)
Diagram:



Offline jdcarpe

  • * Curator
  • Posts: 8852
  • Location: Odessa, TX
  • Live long, and prosper.
Re: swill's plate building tool
« Reply #286 on: Mon, 19 January 2015, 13:08:08 »
Different keyboards (PCBs) do it different ways. I don't know that there is a best practice on which way to orient the stabilizer holes. :(

Ok, I will add a way for the orientation to be overridden on a switch by switch bases so we can orient the stabilizers however we need to.

Also, some PCBs have the vertical switch aligned to the orientation of the stabilizer, and some keep the switch aligned with all the other switches in direction.

I didn't actually understand this.  can you give me a little better description of this so I can figure out how to deal with it.

Thx for your help.  :)
Diagram:


Show Image


Exactly. Thanks for illustrating my text. :)
KMAC :: LZ-GH :: WASD CODE :: WASD v2 :: GH60 :: Alps64 :: JD45 :: IBM Model M :: IBM 4704 "Pingmaster"

http://jd40.info :: http://jd45.info


in memoriam

"When I was a kid, I used to take things apart and never put them back together."

Offline Dihedral

  • Posts: 827
  • Location: United Kingdom
  • Mostly Harmless
Re: swill's plate building tool
« Reply #287 on: Mon, 19 January 2015, 13:11:14 »
Different keyboards (PCBs) do it different ways. I don't know that there is a best practice on which way to orient the stabilizer holes. :(

Ok, I will add a way for the orientation to be overridden on a switch by switch bases so we can orient the stabilizers however we need to.

Also, some PCBs have the vertical switch aligned to the orientation of the stabilizer, and some keep the switch aligned with all the other switches in direction.

I didn't actually understand this.  can you give me a little better description of this so I can figure out how to deal with it.

Thx for your help.  :)
Diagram:


Show Image


Exactly. Thanks for illustrating my text. :)

Any chance to whip out the ol' paint.net :)

Offline smellz

  • Posts: 17
  • Location: Ontario Canada
Re: swill's plate building tool
« Reply #288 on: Mon, 19 January 2015, 13:15:51 »
With my tool, users can specify that a switch should be rotated by 90 degrees by putting !r! in the key's label in the layout editor.
I figured it would be an important option if they're using H cut outs with cherry stabilizers or if they are using Alps-like switches.

Btw, has anyone here tried my tool? I know you are all anxious to see swill's progress, but I'd like to know if mine is getting used atm.
Would there be enough people to discuss it with if I made a separate thread?

edit: I made a thread
https://geekhack.org/index.php?topic=67865.0
« Last Edit: Tue, 20 January 2015, 11:36:19 by smellz »

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #289 on: Mon, 19 January 2015, 13:25:15 »
With my tool, users can specify that a switch should be rotated by 90 degrees by putting !r! in the key's label in the layout editor.
I figured it would be an important option if they're using H cut outs with cherry stabilizers or if they are using Alps-like switches.

Btw, has anyone here tried my tool? I know you are all anxious to see swill's progress, but I'd like to know if mine is getting used atm.
Would there be enough people to discuss it with if I made a separate thread?

Thanks dude...  I have already added the ability to use a {t:<0-3>} to keys to override the switch cutout type (not yet documented feature).  I will just add additional options for people to override different features on a key by key basis.  I may change it to be {_t:<0-3>} and then use {_r:<degrees>} for rotating.  I will have to do two different rotation parameters though, one for switch and one for stabilizer so they can be rotated (or not) independently.

I think it would be a good idea to start a thread here for your tool.  I know a lot of people are eager for my tool to be ready, but my code is taking longer than I was hoping.  When you get an OP setup, link it in this thread so everyone here sees it too.  Lots of people with good ideas in this thread and I am sure a bunch will be interested in playing with your tool too.  :)

Edit: I just noticed you are from Ottawa.  I am in Montreal.  Ya Canada...  :P

Offline Melvang

  • Exquisite Lord of Bumfluff
  • * Maker
  • Posts: 4398
  • Location: Waterloo, IA
  • Melvang's Desktop Customs
Re: swill's plate building tool
« Reply #290 on: Mon, 19 January 2015, 14:08:18 »
Just wanted to throw my two cents in on the rotated switch.  All of the boards I have torn apart with costar stabs had the LED toward the wire.
OG Kishsaver, Razer Orbweaver clears and reds with blue LEDs, and Razer Naga Epic.   "Great minds crawl in the same sewer"  Uncle Rich

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #291 on: Mon, 19 January 2015, 14:15:27 »
My tool now supports vertical keys (defaults to rotating the switch and stabilizer cutout 90º CW) as well as extra vertical spacing.

Here is a standard ISO layout without any modifications to the rotations:

87863-0

I have added support for some 'hidden' options by manually editing the resulting output from the keyboard-layout-editor:
{_t:<0-3>} => change the switch cutout to use for the switch.  Useful if you want to use the H cutout + one alps switch or something like that.
{_r:<angle>} => rotate the switch cutout (does not rotate the stabilizer cutout)
{_rs:<angle>} => rotate the stabilizer cutout (does not rotate the switch cutout)

Here is a modified 50% ISO layout.  I have changed the default rotation of the switch cutout for the ISO enter as well as flipping the default stabilizer cutout the other way.  I used this code for the Enter: {x:0.25,w:1.25,h:2,w2:1.5,h2:1,x2:-0.25,_r:90,_rs:180},"Enter"

In addition I changed the switch cutout of the spacebar to have an Alps compatible switch opening using the following code: {w:6.25,_t:1},""

Here it is:

87865-1

I think that takes care of most use cases for this kind of stuff...

Offline jdcarpe

  • * Curator
  • Posts: 8852
  • Location: Odessa, TX
  • Live long, and prosper.
Re: swill's plate building tool
« Reply #292 on: Mon, 19 January 2015, 15:03:03 »
Looks good! :thumb:
KMAC :: LZ-GH :: WASD CODE :: WASD v2 :: GH60 :: Alps64 :: JD45 :: IBM Model M :: IBM 4704 "Pingmaster"

http://jd40.info :: http://jd45.info


in memoriam

"When I was a kid, I used to take things apart and never put them back together."

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #293 on: Mon, 19 January 2015, 16:09:19 »
I have one more 'feature' I want to add before I get test plates cut.  Basically, I want to add the concept of 'kerf' variable.  I would like to have a dropdown of plate materials (probably combined with thickness), which will modify the kerf for the cutout.  I am pretty sure the combination of material and thickness will dictate the kerf.  Yes???

Also, will the kerf apply to all edges of the cutout.  Yes right?

With a configurable kerf field we should be able to make the same cutouts work for all materials.  I will be getting a test plate cut (hopefully in a couple materials) which will have all of my cutouts, orientations and sizes so I can verify that everything works as expected.  I would also like to test 3-4 different kerf settings with each switch cutout as well so I can determine the best kerf settings for each material with my cutouts.

So just as an example, lets say I just have a square cutout and I have a kerf set to something stupid like .05mm.  So then my 14mm square hole will be 13.9mm square since it will have taken .05mm off each edge.  Make sense?  Anything I am not thinking about here?

Thx guys...

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #294 on: Mon, 19 January 2015, 17:22:18 »
I found this which is kind of interesting for showing some basic kerf numbers for acrylic: http://www.redtorope.com/2011/07/laser-cutter-kerf-measurement/

For the switch openings I think it is pretty easy to do the kerf because I can just shrink the hole by <kerf>.  This can be done by just subtracting the <kerf> from each cartesian coordinate (relative to center).  It gets a little trickier with the stabilizer openings because the center of the stabilizer holes needs to stay at exactly <X> from switch center.  I will need subtract kerf from some areas and add kerf to other areas to shrink the 'opening' while still keeping the centers of each of the major components in the right place.  I will look into this tonight when my brain is not so foggy and I have a piece of paper in front of me so I can draw it...

Offline hwood34

  • underwater squad
  • * Exalted Elder
  • Posts: 5917
  • Location: USA
  • #1 CL stan
    • Keyboard Illuminati
Re: swill's plate building tool
« Reply #295 on: Mon, 19 January 2015, 17:22:29 »
If only I knew what was going on here half the time :)) Still just as excited for the release of this though :thumb:
IV KWK Info Thread & KBK Info Thread IV (out of date)

Old GBs: Gateron Switches (2015) | CF-LX R1 (2015) | CF-LX R2 (2017) | CF-LXXX (2017) | Gen.s Gem Caps (2015)

"Under no pretext should arms and ammunition be surrendered; any attempt to disarm the workers must be frustrated, by force if necessary"

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #296 on: Mon, 19 January 2015, 19:33:41 »
If only I knew what was going on here half the time :)) Still just as excited for the release of this though :thumb:
Haha. You and I both. :). In all seriousness, things are coming along and I think it is going to be pretty sweet once its ready.

Offline Melvang

  • Exquisite Lord of Bumfluff
  • * Maker
  • Posts: 4398
  • Location: Waterloo, IA
  • Melvang's Desktop Customs
Re: swill's plate building tool
« Reply #297 on: Mon, 19 January 2015, 20:33:51 »
I found this which is kind of interesting for showing some basic kerf numbers for acrylic: http://www.redtorope.com/2011/07/laser-cutter-kerf-measurement/

For the switch openings I think it is pretty easy to do the kerf because I can just shrink the hole by <kerf>.  This can be done by just subtracting the <kerf> from each cartesian coordinate (relative to center).  It gets a little trickier with the stabilizer openings because the center of the stabilizer holes needs to stay at exactly <X> from switch center.  I will need subtract kerf from some areas and add kerf to other areas to shrink the 'opening' while still keeping the centers of each of the major components in the right place.  I will look into this tonight when my brain is not so foggy and I have a piece of paper in front of me so I can draw it...

With regards to the kerf on the locations of the stab cutouts, just take half from every edge in relation to the center line.  IE if the edges are 3mm from center line, 6mm apart, and the kerf is .05mm, then your distances would be 2.975mm from center or 5.95mm from each other but location of the hole is unchanged.  This is one advantage of working from center lines as opposed to pitch.
OG Kishsaver, Razer Orbweaver clears and reds with blue LEDs, and Razer Naga Epic.   "Great minds crawl in the same sewer"  Uncle Rich

Offline swill

  • * Elevated Elder
  • Thread Starter
  • Posts: 3365
  • Location: Canada eh
  • builder & enabler
    • swillkb.com
Re: swill's plate building tool
« Reply #298 on: Mon, 19 January 2015, 20:51:21 »
I found this which is kind of interesting for showing some basic kerf numbers for acrylic: http://www.redtorope.com/2011/07/laser-cutter-kerf-measurement/

For the switch openings I think it is pretty easy to do the kerf because I can just shrink the hole by <kerf>.  This can be done by just subtracting the <kerf> from each cartesian coordinate (relative to center).  It gets a little trickier with the stabilizer openings because the center of the stabilizer holes needs to stay at exactly <X> from switch center.  I will need subtract kerf from some areas and add kerf to other areas to shrink the 'opening' while still keeping the centers of each of the major components in the right place.  I will look into this tonight when my brain is not so foggy and I have a piece of paper in front of me so I can draw it...

With regards to the kerf on the locations of the stab cutouts, just take half from every edge in relation to the center line.  IE if the edges are 3mm from center line, 6mm apart, and the kerf is .05mm, then your distances would be 2.975mm from center or 5.95mm from each other but location of the hole is unchanged.  This is one advantage of working from center lines as opposed to pitch.

Ya, this is basically how I have it setup. I am working from center lines, but it is an equation so I can use the same code for all center stem space bars.

So that brings up another question. So kerf is measured to be the width of the cut. If I am using both sides of the cut, I care about the whole kerf. Since I am only using one side of the cut, I really only care about half of the kerf. So... I am guessing that I should collect the kerf value from the UI as the real kerf (which a laser cutter will probably quote) and then divide that number by 2 to get the relative kerf associated with my (keep) side of the cut line. Yes?

I am guessing this makes the most sense from an input perspective.

Also, I am guessing I should make the plate outside edge to be the kerf size bigger than the dimensions given so once the plate is cut, its outside dimensions  are actually the right size.  Same with the mount holes. I should shrink them by 1/2 the kerf.  Basically everything I cut should be corrected for kerf.
« Last Edit: Mon, 19 January 2015, 20:54:03 by swill »

Offline neverused

  • Posts: 572
Re: swill's plate building tool
« Reply #299 on: Mon, 19 January 2015, 22:27:57 »
Accounting for kerf is like accounting for the width of a saw when cutting wood so if you want the outside edge to be cut to dimension (switch cut out), then I would imagine you'd bring in each cut by kerf/2