Change of library between projects

Change of library between projects

tomas.ibaceta
Explorer Explorer
1,679 Views
6 Replies
Message 1 of 7

Change of library between projects

tomas.ibaceta
Explorer
Explorer

Hi! So far I have found that my preferred way to organize projects is to have a folder with the .brd, .sch, gerbers and a .lbr with specifically the components that this specific project uses. That way I can "freeze" that project and go back to it from any place without compatibility issues.

Thing is, right now I want to expand on a project without loosing the previous one, making a new version. If I just go and "copy" this folder and rename all files it works, but the components are still using the devices from the old library (as expected, it would be wayy too smart if it realized what I want it to do).

Thing is, I don't want the two versions of the same project to share the same .lib because i'm going to be switching components, and things would get messy really fast.

TLDR I want two folders with two copies of something, but each has their devices linked to different .libs, that way I can keep working one and leave the other as a completely standalone, working previous version.
What would be the smartest, quickest way to go about doing this?

Annotation 2020-05-13 185102.png

 

Reply
Reply
0 Likes
Accepted solutions (1)
1,680 Views
6 Replies
Replies (6)
Message 2 of 7

Anonymous
Not applicable

Hello @tomas.ibaceta ,

 

First thing that comes to my mind is to copy, paste and rename each file, as you did, but I believe the components of the V1 schematic would still be linked to the V0 library. After this you could use the 'replace' comand, to change the components to the new V1 library. I don't think you can replace multiple components at once, so depending on the number of components, it could take a while.

 

However, since we are talking of just another version of the same proyect, I see no harm on using a single library for all the versions. You could simply add to it the components of the new version, and leave unused the ones of previous versions.

 

That is at least the way I manage my proyects. Whenever I order a PCB, I leave untouched that file, and I create a new version for any further variation.

 

Hope it helps!

Reply
Reply
Message 3 of 7

one-of-the-robs
Advisor
Advisor
Accepted solution

I'd agree that libraries probably should be common between (versions of) projects. After all, they define the components available to you, which don't change just because you decide to use them differently.

That said, I don't think it needs to be as difficult as all that. The problem is the insistence on encoding revision information into file names. That's the wrong approach. They're already under folders with the revision in the name. If the files kept their original names within the new location, the schematic and board files only reference library names, not paths. Fixing the EPF file to the new location is a trivial job for a sed command.

Even better, stop messing around with file and folder names and make use of a proper VCS like subversion or git.

Reply
Reply
Message 4 of 7

mtl_asm
Collaborator
Collaborator

I'm pretty sure the parts used in a design are stored in the .brd and .sch file. That is why you can say, open a .brd file i made on my computer with .lbr files you don't even have. 

 

So even if you update the .lbr that was used to source parts in a design, it will not change the parts in that design unless you tell it to. 

 

If you open a file that uses an older version of a part from a library that is now newer i *believe* you get a msg asking you what to do. I could be wrong or that could be dated info but at least at some point that was the case iirc.

 

Another way it could work is to have 1 master library, but then you can take a snapshot of what is used in a design and save it using the exp-lbrs.ulp

 

this ulp allows you to extract all the libraries used in the current design and save them as a new library. then you could keep that lbr in the project folder or wherever you wish. further modifications to the master library would not affect this exported lbr taken at a certain point in time.

Reply
Reply
Message 5 of 7

Anonymous
Not applicable

I didn't know that ulp, and it is something I would use for sure.

 

Thanks a lot @mtl_asm !!

Reply
Reply
Message 6 of 7

jorge_garcia
Autodesk
Autodesk
Hi @tomas.ibaceta,

I hope you're doing well. See HELP UPDATE.

The update command has an old = new which allows you to have all of the components on the board that reference an old library to switch to reference a new library name. This can make this workflow very simple. The only caveat is it only works as long as there are no parts from the new library in the design.

I agree with @one-of-the-robs, that you would be better served with a proper version control system, but if you want to work with this approach it's doable.

Best Regards,


Jorge Garcia
​Product Support Specialist for Fusion 360 and EAGLE

Kudos are much appreciated if the information I have shared is helpful to you and/or others.

Did this resolve your issue? Please accept it "As a Solution" so others may benefit from it.
Reply
Reply
Message 7 of 7

tomas.ibaceta
Explorer
Explorer

Hi! Thanks for your answer. To be honest, it is time for me to start using a VCS.

Reply
Reply
0 Likes