BAS and BWS Reference Manual

Welcome to the Barracuda App Server (BAS) and the Barracuda Embedded Web Server (BWS) reference manual.

BAS and BWS are C code libraries designed for seamless OEM integration, making them ideal components for embedded applications, including firmware.

How to Use This Manual:

  1. Using Ready-to-Use Products: Refer to the general documentation if you are using a product based on these libraries.
  2. OEM Integration: Consult the integration guide if you are an OEM planning to integrate these libraries into your program.

Note: To sync the left pane navigator with the content you're viewing, click the Sync button () at the top of the navigator after following links within the documentation.

Quick References

Development Process

With BWS, application development is primarily done in C or C++. With BAS, you have the option to leverage the built-in Lua engine and move application-level logic into a higher-level language. This allows you to separate low-level, performance-critical code from higher-level behavior, configuration, and integration logic, setting the stage for a more flexible and productive development workflow.

Using Lua in Professional Products

Lua is battle-tested in professional systems such as game engines, industrial automation, and networking. The consensus among developers? It's ideal for application logic (aka business logic), orchestration, and customization, pairing seamlessly with stricter languages like C, C++, or Rust for core performance and safety. Successful products thrive on this hybrid: Lua handles high-level behaviors, including (IoT) networking, while low-level code ensures performance.

This split is a smart evolution for embedded system development. Lua scripts handle high-level tasks such as configuration, web interfaces, MQTT integrations, and other IoT protocols, as well as custom embedded business logic. Benefits include rapid prototyping (days vs. weeks in C), cost savings, and accessibility for non-C experts.

Best Practices for Success

Lua’s flexibility is a strength, and with a small amount of discipline it leads to robust, maintainable systems:

  1. Plan for Lua - C Integration: Assign a dedicated C engineer to design and maintain the Lua-to-C bindings.
  2. Document APIs Rigorously: Define inputs/outputs/errors clearly, preferably in a separate document.
  3. Validate at Boundaries: Check network/module data early to localize issues.
  4. Keep Logic Lean: Use small, single-purpose Lua modules/scripts; offload compute-intensive parts to the C core.
  5. Dynamic Typing Works Well With Proper Testing - Lua's flexibility accelerates embedded development, as long as clear interfaces, input validation, and solid test coverage are in place.
  6. Test Early and Often: Good test coverage turns dynamic typing into a strength. Xedge is designed to make testing straightforward and fast throughout development.

Software Bill of Materials (SBOM)

Product: Barracuda Embedded Web Server

Supplier: Real Time Logic

Included Software Components

Product: Barracuda Application Server

Supplier: Real Time Logic

Included Software Components

Optional Components (Not included by default; availability depends on configuration and deployment)

Notes