Loading Library Files

In BlinkScript, Library Files enable you to share common functions and code snippets. This means you can reuse common functions across multiple kernels and projects without having to rewrite them.

To access Library Files in your BlinkScript Node:

1.   In BlinkScript Node Properties, click on the Library Files tab.
2.   Click the folder icon to choose the .blib file to import.
3.   Click Add.

The .blib file (and location) will now appear in the kernel’s loaded Library Files. This list also contains information on the file status:

OK - the file is found and loaded.

File Not Found - no file at the specified path.

Compilation Error - the file contains compilation errors.

4.   Call these functions in your main kernel by writing the function in your kernel source (similar to calling any inbuilt function).

Note:  Documentation for Library Files functions can be added to the tab menu of the BlinkScript editor. Type with a ‘///’ comment before the function to add documentation.

Note:  Errors in Library Files are caught by the BlinkScript Editor’s error handling.