-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New freecad user, trying to figure out how to input correctly #17
Comments
You are quoting the path string wrongly. Should be like this, pcb = kicad.KicadFcad('C:/Users/richa/Desktop/ODS Med/Ring_PCB/Ring_PCB.kicad_pcb') Notice the backslash changing, because otherwise it will be treated as escaped character. You can sort of disable the escapes by proceeding the quote with pcb = kicad.KicadFcad(r'C:\Users\richa\Desktop\ODS Med\Ring_PCB\Ring_PCB.kicad_pcb') |
Hi, Just to make sure if I haven't messed up anything, I have the macro installed at: Once copy paste the following code, I get the following message below.
|
You didn't download the git submodules. If you are cloning my git repo, go to git submodule update --init --recursive If you are downloading the zip archive from github, then please go to the release page and download the |
were do i need to type theese commands |
Just look at the picture above. The lower half of the window is called Make sure you use backslash for the path, e.g.
|
For a new user who doesn't know how to run Freecad Macros and how to update git submodules, the installation instruction is not clear. I have the same problem as shown in below when I tried to run the first line. Python 3.6.6 | packaged by conda-forge | (default, Jul 26 2018, 11:48:23) [MSC v.1900 64 bit (AMD64)] on win32
When execute the kicad.py in Macro window manually, it shew the similar error message at linen 18 like: |
You probably didn't clone all the submodules. You download the prepackaged fcad_pcb.zip, and extract it to your FreeCAD Macro directory. Please delete your previous clone of fcad_pcb first. When you copy the Python commands, make sure to not include any leading space. |
Exact |
Okay. Now I have figured out the problem. I should not try to execute the .py script file manually in the Macro window. To executed the script file, I had to change the default path of user local macro setting to the sub-folder fcad_pcb. All these lead to my problem. So the hints for new user are:
Thanks again for the help! |
probably the issue is related to your TO-4-4 footprint... you designed it with some geometry pads, but you also included a simple track in it, not creating a real pad. EDIT this is not enough to solve the issue, anyway I'm attaching the board with the modified fp, using the geometry pad instead of a track. |
The problem is because of the arc in side the custom pad. I have just add support for that. Please sync my repo and try again. |
@realthunder
|
Fixed. Please check. |
fix confirmed! |
This is not really an issue, but I am posting it here as a question/request. What if I want to convert to STEP a pcb with several layers, not just two, of varying dielectric thickness? Ditto for the copper weight on every layer. I guess it would be possible to import the pcb into FreeCAD two layers at a time and then align all of them in FreeCAD, but I thought it would be easier to do it all at once with your script. Also, due to lack of available documentation, I am not sure what the options 'combo' and 'fuseCoppers' do. I would like to report that, following your examples, I have used your macro successfully with FreeCAD 0.19 (development) on stock Ubuntu 16.04LTS, although you do not mention FreeCAD 0.19. |
I just added this feature. With
pcb.make(copper_thickness={None:0.05, 0:0.04, 'B.Cu':0.09}, board_thickness=1.53, combo=False, fuseCoppers=True) |
I think that @linuxcf also requested for user to have the control of thicknes of dielectric layers, not just the copper layers. It might make more sense to implement parser for the board stackup info that is present in the 5.99 file format. So even 5.1.x users could design the pcb. and then reopen it in 5.99, define the stackup, and then import the .step into FreeCad via example of stackup info in 5.99:
|
If I was not clear enough, this would require also to have separate board objects/parts (substrate, prepreg, ...) |
Can you please provide a complete kicad_pcb file with that stackup info? |
layout file: |
@MitjaNemec and @realthunder: Thank you for your hard work and information! The reason I asked the question about thicknesses is new(er) techniques of so-called substrate integrated waveguides (SIW), where, basically, you create waveguides with "soft" walls comprised of vias. The "soft" waveguides may be parallel to the layers, as in this wikipedia article, or normal to the dielectric layers, as in this article about SIW antennas. Such structures need a full 3D electromagnetics simulator and the easiest way to pass data to such a program, open-source or commercial, is a STEP file. (Unfortunately, closed-source 3D electromagnetics simulators hold a huge lead over their open-source counterparts, but that's another topic.) The interest in SIW is intensified today because you can build phased arrays inexpensively on pcbs and phased arrays can (mostly) replace mechanically-steered antennas when tracking low-Earth orbit satellites, which are proliferating today. I am writing this to show that the paradigm of pcb design is shifting from the traditional 2D to 3D. There is no reason why KiCAD cannot be on the forefront of such developments and this macro does exactly that for KiCAD. In a SIW the copper structures may span several pcb layers. If I can accurately export the copper structures to a 3D electromagnetics simulator, I can fill in the dielectrics in the padstack by hand. So, even exporting accurately the copper structures alone would be great help. I looked at the wiki page for this project, but was not able to find documentation about the 'combo' and 'fuseCopper' options. |
Tell me anything you want exactly, preferably with demo files. I'll see what I can do. |
@realthunder: Thank you so much! I will go with 'fuseCopper=True' and 'combo=False'. |
@realthunder: I made the attached pcb, using via fencing, via stitching, and teardrops (thank you, @easyw!). Stupid question: The intended copper thickness was 35μm, but FreeCAD measures 35.0001μm. I know that in practice sub-nm tolerances are meaningless, but I wonder whether this error could pile up, perhaps nonlinearly, if I had multiple layers? Just a question. I think this macro deserves much wider publicity. |
Hi, I'm having a similar issue to @Rerouter. After loading my pcb Bus.zip and issuing the basic command
I get the following message
Is this related to my pcb? |
Hi @realthunder, thank you very much. That's a great tool! |
Which net did you try? Any error message? |
@iCarletto I had best result using standolne gmesh. You can make the tracks thicker and account for this in specific conduction/resistance (thermal or electrical) |
@iCarletto also simplifed vias (#22) help a lot. |
@realthunder I'm interested in net VBUS_C (98). When I try to generate the mesh in FreeCAD using Gmsh I receive the error I tried to export the net layer as step file and to import it in Comsol (middle image), but I receive a similar error when trying to build the mesh because of some intersecting faces (lower image). If I reduce the absolute import tolerance (upper image) from the standard 1e-5 to 5e-5, it succed but as a consequence the edges of the copper layer collapse in a line and I'm not sure what happens to thickness of the layer in the center. I guess the problem of intersecing faces could be due to either the accuracy of the exported step file, or the way vias are built, but honetsly I'm using FreeCAD for the first time and I do not fully understand most of the parameters. Do you think there might some essential parameter that I'm overlooking? |
@iCarletto meshin thin hollow cylinders is a PITA. And if you wish to get accurate results you'll need to talk to PCB manufacturer regarding the via thickness it is certainly not the same as track thick thickness. And when you're there you can simplify vias and set them up for precise copper area you want |
Can this ticket be closed ? |
Hi, I am getting the following errors after using the following lines of code Error:
|
Hi,
I am a new user to freecad and I am having trouble with the syntax.
I have a file located at C:\Users\richa\Desktop\ODS Med\Ring_PCB\Ring_PCB.kicad_pcb
I want to import it so I can start milling.
When I type the following I get some error messages below. I am not sure where I messed up.
I am running on Windows 10, 64bit and running Kicad 0.18
The text was updated successfully, but these errors were encountered: