Work In Progress: Native CADSTAR Importer

Not really, 23 years progress since then. Modern PCs are much more powerful than a Sun workstation.
Crazy expensive, so PCB layout was only done by an elite

In future I hope to also reverse engineer the .pcb format, but that will take a lot longer and the brief time I spent looking at it, I didn’t even know where to start.

I have some pre-2000 designs if that would help (wonder if it might be in an older / more simple format).

BTW, the mifa_simple/SampDesign/CC2511_USB_Dongle_1_3 design imported successfully. I visually compared the top layer with Cadstar viewer and it looks good. Gave up before figuring out how to view the other layers with Cadstar’s viewer.

I’ve marked it in red below:

Thanks! Do let me know if you notice any differences.

I’d say even 23 years later Cadstar is pretty poor for a commercial package. In my opinion, KiCad is superior in usability terms even though Cadstar might have a few more high end features.

Yes that would be useful if you can share. I don’t plan on doing anything for the .pcb format for a few months as trying to get .cpa and .csa converter finished and accurate.

Cadstar’s visibility setings are not intuitive unfortunately. They are under View->Colours. Inside the Colours window you can set the visibility of individual items (components, areas, vias, etc) but also if you click the “Layers…” button you can then set visibility of items on specific layers.

Yes, it takes at least 4 clicks to enable visibility of a specific item and 5 clicks to enable visibility of a layer (in KiCad 1 for both!). And yes, this horrible interface is also in the paid CADSTAR Design Editor…

This is one of the many reasons for my decision to write the Cadstar importer.

On a separate note, I’ve been quietly making progress on the schematic importer. I’m working every spare minute I get and am trying really hard to get it in before feature freeze (only a few days left!).

1 Like

I tried to import an old CadStar design, but I get an error. It works in the CadStar viewer.
Unfortunately I can’t send you the file, as it is the property of my company.

kicad_error

Thanks for the report! The reason for this is reassignments in route widths which at the moment the CADSTAR importer doesn’t know about. I will fix during feature freeze.

If possible, would you be able to remove these reassignments and check if other elements of your design can still be imported?

To do this, you’d need access to CADSTAR Design Editor. In the design editor, go to Design tab -> Assignments -> Routes and delete any reassignment rows, as per below picture.

If you could re-export the design after the above changes and try again, that would be great!

I’m trying to check if there are any other critical issues to fix.

@Qbort
Sorry, I only have the CadStar viewer, no Editor.

@rrascher Ok since you can’t send me the design due to confidentiality, the only alternative I can think of is to open the file in a text editor (e.g. notepad++) and search for (ROUTEREASSIGN

You should get to see sections like the one below:

   (ROUTECODE W19 "LIVE" 127000
    (NECKWIDTH 50800)
    (MINWIDTH 25400)
    (MAXWIDTH 1270000)
    (ROUTEREASSIGN LAY6 127000
     (NECKWIDTH 50800)
     (MINWIDTH 30000)
     (MAXWIDTH 1270000)
    )
    (ROUTEREASSIGN LAY24 127000
     (NECKWIDTH 80000)
     (MINWIDTH 60000)
     (MAXWIDTH 1270000)
    )
   )

Please delete any (ROUTEREASSIGN [...] ) sections ensuring you also delete the closing brackets. The result would be something like below (for every ROUTECODE section:

   (ROUTECODE W19 "LIVE" 127000
    (NECKWIDTH 50800)
    (MINWIDTH 25400)
    (MAXWIDTH 1270000)
   )

I’m just trying to find out whether there might be other errors in the import that maybe I should fix at the same time.

1 Like

Ok, I’ve removed all the ROUTEREASSIGN section, and loaded the board again.
It still loads fine in the CadStar viewer, but in KiCAD I get an different error message
now.
kicad_error_I

Damn… I must say I have no idea what TRUNK might refer to in CADSTAR. I know you can’t share the whole file but might you be able to share just the lines in the file where the text (TRUNK is present?

Please include all the lines between the opening and closing brackets of the section.

@Qbort
I have extracted the section of the board file, where TRUNK appears.
Hope this might help.
trunk.txt (75.6 KB)

@Qbort
I’ve done some further investigations. I deleted all the TRUNK statements, and
tried to import in KiCAD again. Now I get another error message.
kicad_error_II

Hi,

@Qbort TRUNK relates to a CADSTAR feature called … Trunk routing. A way to route several tracks together by using vias patterns … The best to avoid this error at import would be to ‘remove’ the TRUNK (a kind of ungroup). But as @rrascher has only a viewer, the only way is to work in the CPA file.
If I remember well tracks that are routed as TRUNK are correctly described in CPA, the TRUNK statement are here to keep them as a TRUNK during reimport into CADSTAR. So by ignoring all TRUNK entries during import, you should obtain a correct result.

Hope that can help…

2 Likes

In Kicad, is there a concept of a virtual bus or some other way to identify a group of nets (maybe a tag, label, or property that can be assigned to otherwise unrelated nets)? If so, then it would seem like this would fit into that. Even if it isn’t useful right now, is there a chance it would be useful in the future?

Extrapolating, would TRUNKREF be the reference net that the others are routed “against”?

Excellent, thank you for this.

This will be related to the TRUNK statements.

This is indeed very helpful information! Thank you very much for sharing. I will fix this issue as you suggest, just ignoring the TRUNK (and TRUNKREF) entries for the time being.

I will do this after feature freeze though (i.e. after 30th September), since I’m dedicating as much of my spare time as possible at completing the CADSTAR schematic importer before feature freeze. I only have a few days left but hopefully should be able to complete it in time so that it can be a feature of KiCad v6. Progress so far can be seen here: https://gitlab.com/kicad/code/kicad/-/merge_requests/410

I don’t believe so but could be wrong.

The only thing we have is a netclass

1 Like

Thanks for that - I forgot about net classes. In that case, will look to add any TRUNKREF elements to a netclass.

I only just noticed that someone made a post in the official KiCad blog about this feature. I feel very honoured :blush:

The schematic importer is almost complete. Hopefully it will be merged in the next few days.

2 Likes

UPDATE!

The schematic importer was now merged into the master branch. This should trickle into nightly builds over the next few days. Thanks a lot to @craftyjon for spending the time to do the final review before merging!

Please report any import issues you find in this post.

I am also working on a Project importer similar to that found in the Eagle importer.

7 Likes

Another addition:

CADSTAR Project importer added to KiCad Project Manager (see MR 433)

image

4 Likes