Skip to content

embj-org/ejkmer-builder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

EJ Kmer Builder

EJ Kmer Builder is a demonstration tool that showcases how to integrate the EJ Builder SDK for automated embedded testing. This tool manages the build and deployment process for the k-mer algorithm benchmark project across different embedded hardware platforms.

It was built as part of the EJ Guide series that can be found here.

What It Does

This builder application demonstrates what is possible with EJ and the EJ Builder SDK features including:

  • Cross-compilation management: Automatically builds k-mer applications for ARM64 targets
  • Remote deployment: Handles secure file transfer to embedded devices via SCP
  • Job cancellation: Properly cleans up remote processes when jobs are cancelled

Installation

From Git

cargo install --git https://github.com/embj-org/ejkmer-builder

From Source

git clone https://github.com/embj-org/ejkmer-builder.git
cd ejkmer-builder
cargo install --path .

Prerequisites

Before using this builder, ensure you have:

  • Rust toolchain: Latest stable version
  • AArch64 cross-compiler: For ARM64 target support
  • SSH access: To your target embedded devices
  • CMake: For building the k-mer applications
  • EJ framework: Either EJB standalone or EJD dispatcher setup

Usage

The builder is typically invoked by EJ framework components (EJB), but can be used directly:

# When called by EJ, receives these arguments:
# ejkmer-builder <action> <config_path> <board_name> <board_config_name> <socket_path>

# The application automatically determines whether to build or run based on the action parameter

Integration with EJ Guides

This project serves as the primary example in EJ Guide 02 - Builder SDK, demonstrating:

  1. Migration from shell scripts: Shows how to convert basic deployment scripts to robust SDK-based tools
  2. Job cancellation handling: Demonstrates proper cleanup when tests are interrupted
  3. Production deployment patterns: Illustrates best practices for embedded test automation

Comparison with Shell Scripts

This Rust-based builder provides several advantages over simple shell scripts:

  • Cleans up remote processes when jobs are cancelled
  • Clear error messages and proper exit codes
  • You get to write code in Rust

And some incoveniences:

  • Requires compilation step
  • Need familiarity with Rust ecosystem
  • You get to write code in Rust

Related Projects

Contributing

Contributions are welcome! This project serves as a reference implementation for the EJ Builder SDK, so improvements that demonstrate best practices or additional SDK features are particularly valuable.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Support

For questions about this builder or the EJ framework:

About

A CLI demo tool that uses the EJ Builder SDK. Check out https://embj-org.github.io/ej to learn more

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages