BRLibToHelp - Generate CHM Help Files for Your B&R Automation Libraries

Hello B&R Automation Community! :waving_hand:

I’m excited to share a tool I’ve developed to help with documentation: BRLibToHelp - an application that automatically generates CHM help files from your Automation Studio libraries.
This tool follow the guidelines from the Automation Help here Creating help documentation for user libraries

:bullseye: What Problem Does It Solve?

If you’ve ever created custom libraries in Automation Studio, you know that proper documentation is essential but can be time-consuming to create manually. This tool automates the entire process by:

  • Parsing your library files (.fun, .typ, .var) automatically

  • Generating HTML documentation for all functions, function blocks, data types, and constants

  • Compiling a CHM help file ready for integration with Automation Studio

  • Enabling F1 context-sensitive help - just like native B&R libraries!

:sparkles: Key Features

:open_book: Complete Documentation Coverage

  • :white_check_mark: IEC and ANSI C libraries

  • :white_check_mark: Functions and Function Blocks

  • :white_check_mark: Data Types (Structures, Enumerations)

  • :white_check_mark: Constants and Variables

  • :white_check_mark: Input/Output parameters with descriptions

:wrench: F1 Integration

The generated CHM files work seamlessly with Automation Studio’s F1 help system. Place the CHM in your library’s Help/ folder, and users can press F1 on a selected function or function block in the logical view.

:counterclockwise_arrows_button: Full Source Access & Easy Rebuilds

All HTML source files are generated in the build folder, giving you complete control. Edit the documentation directly, add custom content, and rebuild the CHM file anytime using the included batch file - no need to regenerate from scratch!

:briefcase: Use Cases

This tool is perfect for:

  • Engineering teams maintaining internal function libraries

  • Anyone who wants professional documentation without the manual effort

:link: Try It Out & Share Your Feedback!

Want to give it a try? You can find the complete project on GitHub:

:right_arrow: https://github.com/br-automation-community/BRLibToHelp

I’m actively looking for feedback to improve the tool! Whether you have suggestions, found a bug, or just want to share your experience - your input is greatly appreciated. Feel free to:

  • :star: Star the repository if you find it useful

  • :bug: Open an issue if you encounter any problems

  • :light_bulb: Suggest new features or improvements

  • :handshake: Contribute to the project

Looking forward to hearing from you! :blush:

Regards,
Florent

16 Likes

Looking for feedback from BRCommunity :slight_smile:

1 Like

Very nice :clap:

The most helpful thing would probably be a command-line interface or a mention of how to call the script without UI
→ CI/CD

1 Like

Thanks for the feedback!
Currently there is no command-line interface, but it’s a good point! I will create an issue to implement a simple command-line interface!

2 Likes

Hi,

New version 1.0.0 is out, available here including CLI.

Regards,
Florent

3 Likes

Hi, thank you for this tool! It works really well and easy, good job!
I cant imagine how much afford it takes but it would be really nice to do a code analyses with AI to create a time diagram and a machinestate diagram. For example: My Maschine has the State NotReady, Ready, Done and Error. Which variables have to change to reach another maschinestate.

Regards, Oli

I think this should be adressed as feature in this topic:

This python script is for generating a .chm file

Hi @Oliver_Thran

Thanks for the feedback and suggestion!

To be honest, parsing the source code to detect CASE statement from ST programming language could be pretty easy but the complexe thing is to handle all the programming languages available. Also it can be pretty complexe depending on how the user implemented the machine state in the function / function block.

From my side, I always try to follow PLCOpen recommendations:

And to document the executing part of the function block, I often do it by hand or using little script to generate Mermaid diagram and edit it by hand.

I agree that it could be a crazy feature but seems too complexe to implement.
But if someone has an idea of implementation feel free to implement it and submit a pullrequest on the repo!

Regards,
Florent

2 Likes

I’m not entirely convinced that this functionality belongs in AS or the AS Code extension, given its reliance on third-party executables and DLLs. While these dependencies are bundled into the executable for this project, they remain mandatory and add complexity.

CHM files feel outdated as a documentation format for code or applications. Instead, I’d advocate for an AS Code extension that generates Markdown documentation directly from a library. This approach aligns better with modern practices—it would allow documentation to live seamlessly in a Git repository alongside the source code, which is how I’d prefer to document my own libraries.

Let me know your thoughts!

Best regards,
Florent