Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

General Concept

This feature allows to build standalone libraries from eHS over Schematic Editor to protect your IP.

Usage

There are 2 ways to use the eHS export Protected Block feature. The first is simply to use the UI, and the second is more automation oriented, using scripts.

...

It will create the protected block in the current model.Image Removed

...

eHS export Protected Block feature as a script

...

To facilitate the automation of the eHS export Protected Block feature, the Matlab Function that generates the protected block can be called manually inside a script to create a locked library file containing multiple different eHS Protected Blocks. Within the eFPGASIM product, this function is called: generateProtectedBlock.

The generateProtectedBlock function takes in input the Original eHS Block to export and the location where to output the resulting eHS Protected Block. The generateProtectedBlock function can be called multiple times, pointing to the same output file path, in order to create a library of many eHS Protected Blocks.

...

Matlab Function takes 4 inputs:

  1. The file path of the Simulink Model in which the Original Block to be exported is located

  2. The Block Path of the eHS Block to be exported

  3. The output file path in which the eHS Protected Block is to be created

  4. The name of the eHS Protected Block to be created

Behavior

  • If the output library does not exist, the script will automatically create it.

  • If the output library exists,

    • If the block already exists, it will be overwritten.

    • If the block does not exist, it will be added and properly positioned into the library after the last one.

Example

Take this model for example, an eHS Block situated on the desktop:Image Removed

...

We want to create a library block called machineLibrary in which this eHS Block will be exported as a eHS Protected Block. The generateProtectedBlock function should be called with the following parameters:

Code Block
>> generateProtectedBlock('C:\Users\admin\Desktop\originalModel', ...
                                             'untitled/eHS SE SFunction Drivers', ...
                                             'C:\Users\admin\Desktop\machinesLibrary', ...
                                             'My PMSM Protected Block');

IMPORTANT: Use backslashes ( '\' ) for the file path and forward slashes ( '/' ) for the block path.

...

Now machinesLibrary.slx will contain two eHS Protected Blocks: "My PMSM Protected Block" and "My Other PMSM Protected Block" for the user to use.Image Removed.

...

User Interface

Protected block are using an embedded UI in order to be used standalone.

...

The block may come with multiple setups (Hardware/firmware choice).

This way, you can choose the appropriate one for your own usage. The protected block creator is responsible to describe each setup to its client using the protected model.

In the previous example, Setup 1 matches its name in the Schematic Editor

...

The block can be loaded for any setup and will provide its associated build report in the dedicated tab section.