Understanding Constraints

So I am trying out Bricscad to see about switching to it for a all in one solution on Linux for 2D and 3D, and running into an issue. I am attempting to utilize constraints to create what I would refer to as 'connectors' in other software to use for schematics. An example schematic in my field looks like this:

http://www.usitt.org/assets/1/27/SundayInTheParkWithGeorge_SystemDiagram.pdf

So in creating this, which is called a signal flow diagram, cables are represented by single lines, and equipment can be blocks. As you can see a single equipment block can have multiple inputs and outputs associated with it where multiple lines connect to it. What I am looking to do is utilize constraints (Probably writing some basic tools in LISP, already worked out drawing the blocks in lisp) so that once I make a connection with a piece of equipment, it stays connected to that block in that location. Later on I will be looking at how to move the connection point easily but that is later on.

As of right now for the lines themselves polylines actually work rather well but I can also use lines with constraints to keep horizontal and vertical lines, eventually will be using arcs for corners etc. All that is fine, but if I try to use a conincident constraint it tries to pull a corner of the block to the point, and if I provide as part of the block a small line perpendicular to the block, the coincident constraint doesn't seem to work. On the commandline I get no feedback after picking the second point which I would expect with the command completing correctly, but I can move the block and the line is unchanged to match the new position of the block. I have also tried colinear however I can't use colinear between a line and a block apparently?

Is there something I am missing or a better way to handle this? I attached a simple drawing to demonstrate this with two blocks, one with a connection line perpendicular to the rectangle as part of the block, and one without, but can't find a way to get this to work with either.

Thanks very munch for the time and help.

Comments

  • Interesting thing...

    If I use a group instead of a block, I can get it to work so long as I provide a line to coincident constrain to as part of the group. This may work for me as very often the device won't be identical so using a block isn't a necessity persay but will depend on what I can code as I am hoping to code some LISP to keep track of inventory used in the diagram (Equipment etc.).

    Still would love to hear other thoughts on how to accomplish this other ways of course, very easily I could be missing something.

  • What you seem to be looking for are smart connectors, similar to what you might get in an application like Visio? 2D constraints aren't a good match to achieve this functionality. As you've identified, you can't constrain to a block (must be a line/circle/arc/ellipse/polyline). Also you would need to fix all your blocks to stop them moving, rather than the connector line. Neither of these requirements would stop you from producing your drawing with constraints, but it would be rather laborious to do so, and modifications could be equally difficult.

    Having produced a few P&IDs & Electrical Schematics in my time I would suggest the KISS approach. two key things to look at:

    • Templates. Schematics tend to be highly repetitive. Often the only difference between drawings are tag references & line labelling. Using a template allows you to quickly re-use existing designs.

    • The STRETCH command is your friend. This unassuming command is extremely powerful to manipulate entities. If you're not familiar with it, then it is worth spending some time to get to know.

    Blocks are useful for repetitive data (e.g. switches), and to hold related text fields. You can use FIND to search and replace text quickly on your drawings.

    Regards,
    Jason Bourhill
    CAD Concepts

  • @Jason Bourhill said:
    What you seem to be looking for are smart connectors, similar to what you might get in an application like Visio? 2D constraints aren't a good match to achieve this functionality. As you've identified, you can't constrain to a block (must be a line/circle/arc/ellipse/polyline). Also you would need to fix all your blocks to stop them moving, rather than the connector line. Neither of these requirements would stop you from producing your drawing with constraints, but it would be rather laborious to do so, and modifications could be equally difficult.

    Having produced a few P&IDs & Electrical Schematics in my time I would suggest the KISS approach. two key things to look at:

    • Templates. Schematics tend to be highly repetitive. Often the only difference between drawings are tag references & line labelling. Using a template allows you to quickly re-use existing designs.

    • The STRETCH command is your friend. This unassuming command is extremely powerful to manipulate entities. If you're not familiar with it, then it is worth spending some time to get to know.

    Blocks are useful for repetitive data (e.g. switches), and to hold related text fields. You can use FIND to search and replace text quickly on your drawings.

    Regards,
    Jason Bourhill
    CAD Concepts

    Jason

    Thanks for the reply, I somehow missed it all those months ago and just noticed the notification recently. You are correct, smart connectors in Visio are an analog to what I am looking to create. You are also correct in that there is often a lot of reuse available, but in my case not always. Because the schematics I am trying to create are audio/video system designs for different clients and each client I design from the ground up as a consultant for their needs, there isn't a huge amount of reuse between clients. On the flip side where I teach at for theatrical usage there certainly can be, but as I am teaching I also need my students to understand how to create from the ground up as well, part of why I am looking at this is in fact to give them access to a toolset that is at least somewhat more affordable for this purpose as they move forward and they are only going to have so much reuse available to them as well as they move from theater to theater to get work.

    I will look into the STRETCH tool though for this purpose, haven't tried it yet so I am curious to see what it can do. And yes I am using Blocks for pieces of equipment where the symbols might be identical but the text content is very different. If you want more information on what I am doing the USITT Sound Graphics Guidelines http://www.usitt.org/assets/1/27/Sound_Guildelines_2008.pdf are what I tell my students to base all their work off of. Not officially standards, despite what the document title may say, but they are starting guidelines for their work.

    Fixing the blocks wouldn't be ideal for my case as half the time the block is what might need to move to create a cleaner layout for us, but for modifying just the connector line itself you are correct in that I would need to fix the block.

This discussion has been closed.