wokwi / easyeda2kicad

Convert EasyEDA designs to KiCad EDA
https://wokwi.com/tools/easyeda2kicad
Other
287 stars 39 forks source link

Added function to convert through hole pads to via's #26

Closed coolio986 closed 4 years ago

urish commented 4 years ago

Thanks a bunch!

Can you also add a test case for this?

Test cases live in board.spec.ts and should be pretty straightforward - you just copy an example input from EasyEDA file, and the corresponding output from the KiCAD file (after you verified it's what you expected), and then use that as a basis for test. Please let me know if you need any assistance with this.

coolio986 commented 4 years ago

Yep, I well add a test soon. Was more focused on getting the code to work on my end, but I will follow up. This is an important tool, I will get it done!

urish commented 4 years ago

Thanks!

urish commented 4 years ago

Also, I see that rect/polygon pads are not supported. It seems like the way to go with rect pads would be to wrap them in a footprint, similar to how we do with hole (convertHole()). You can find an example of an EasyEDA PCB with a RECT pad in #28.

coolio986 commented 4 years ago

I have simulated this between Easyeda and Kicad. I will work on this.

urish commented 4 years ago

Thank you! Also make sure you rebase your code to latest changes from master, I have done some changes to the tests to make them simpler. Basically, now all tests call convertShape(), and pass in an easyEDA shape string. e.g.: https://github.com/wokwi/easyeda2kicad/blob/ebea970323f6244fa12b8fab898e9c6f5519bb65/src/board.spec.ts#L93

coolio986 commented 4 years ago

This is ready

urish commented 4 years ago

Thank you! Can you please rebase your branch on top of master? Otherwise, it is very hard to tell your changes (if you look at the diff you can see it contains other changes as well).

To rebase, first add this repo as upstream (if you haven't done so), using:

git remote add upstream https://github.com/wokwi/easyeda2kicad

and then fetch the upstream and rebase:

git fetch upstream
git rebase 

and follow the prompts (you may have to resolve some conflicts along the way). Perhaps there is also a way to rebase via Github UI, I'm not sure (but you can google it if you like).

Once you are happy with the result, you can force-push it to your branch by git push -f (just double-check that all your changes are there before you force-push)

Please let me know if you have any questions!

coolio986 commented 4 years ago

Done

urish commented 4 years ago

Did you push the changes? I can't see any updates to list of commits in the pull request

coolio986 commented 4 years ago

Yes I pushed as requested. I followed the instructions as instructed, and all commands completed successfully.

urish commented 4 years ago

It seems like I might have been wrong with the commands, as I still see the unrelated commits in the PR. If you are interested, we can try to set up an online session to look at it together, or I can try to check with a friend who is a git master (wrote this great book) to see if he could chime in here. What works best for you?

coolio986 commented 4 years ago

I think what would work best is for me to re clone your repository from the latest and re apply my changes so you can see what is changed.

urish commented 4 years ago

Alright, do you need any help with that?