Engee documentation
Notebook

Custom Block Libraries

In this example, we will analyze the possibilities of creating and using custom block libraries.

First, let's create the Engee library file.

image.png

Then open it. It is important to take into account that each subsystem created in this case will be perceived as a separate block of our user library. If a subsystem without input and output ports contains a set of subsystems, then such a subsystem will be perceived as a subcategory of our library.

In this example, the task is to create a block that will allow dividing by a given constant. The figures below show the internal structure of this unit and the parameters of its mask.

image_2.png image_3.png

After completing the library creation process, we can save it and upload it to the Library tab in the model editor.

image.png

After that, our blocks will appear in the Library tab, and we will be able to apply them in any model.

image_2.png

Let's create a test model and reduce the input signal by half due to our block. To do this, add the sinusoid block and our division by constant block.
image.png
The results of our test model show that the block has reduced the amplitude of the input signal by half.

image_2.png

Conclusion

In this example, we looked at the possibilities of creating and using custom libraries in everyday work with models.

Blocks used in example