Giter Club home page Giter Club logo

rid's Introduction

rid

This crate is meant to be shared by a client and host communicating over USB.

Currently the only host programs are tests in this repo.

To run the tests make sure to use the std feature

cargo test --features="std" <test_name>

To build and open the docs run

cargo doc --open

Test Results

RID linear offset conversion PTP Offset Error: difference in measured times and estimated times

  • horizontal: milliseconds
  • vertical: microseconds

RID linear offset conversion PTP Offset: offset calculation over time

  • Used to map current timestamps from host <-> client
  • horizontal: milliseconds
  • vertical: microseconds

RID linear offset conversion Linear offset conversion: C(t) = m * H(t) + b

  • Used to map durations/future/past times from host <-> client
  • horizontal: seconds
  • vertical: seconds

RID Packet flight time Packet flight times: host time vs flight time

  • horizontal: milliseconds
  • vertical: microseconds

Testing

HIL Testing

RID intends to build highly iterable tests and validation. This is done by placing a Teensy in the loop (Hardware In the Loop). This type of testing will consist of a host machine and Teensy connected via USB. It should always be assumed that the hardware contains the full firmware implementation but this should not be required by module or integration tests.

Module Testing

Not all Modules require HIL testing, but all modules should be tested before integration tests are performed. See docs for module list.

PTP Performance

This is a HIL and module test. The file rid/tests/ptp_performance.rs provides a host side implementation of an HIDRAW driver and PTP algorithm. The firmware lives in another repo but utilizes the same RID crate. With firmware flashed run

cargo test --features="std" ptp_performance -- --nocapture

RTNT Tests

These tests demonstrate the process of loading a system from a toml file and parsing that file into TaskNodes. This is a module test that does not involve hardware. By forcing a host to configure some nodes, the same nodes should be initialized in the Teensy. TaskManagers will output and share the proper RID packets to the remote TaskManager. The goal for these tests is to make sure nodes output data, config data and number of nodes is constant between the two TaskManagers.

cargo test --features="std" rtnt_load_panic_load_load_panic -- --nocapture

cargo test --features="std" rtnt_load_reconfigure -- --nocapture

Integration Testing

Once basic functionality for Modules has been established start integration tests. Integration tests should not be concerned with specific numerical inputs and outputs. Instead integration tests assert that the status of a system is always correct.

rid's People

Contributors

mitchelldscott avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.