-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementatation of the stream functionality #12
Implementatation of the stream functionality #12
Conversation
The interface allows generic sensors to stream samples data in double format. The interface is the same as the one defined in the stream-qt5-test astarte-platform repository Signed-off-by: Riccardo Gallo <[email protected]>
Introduce: - `color_eyre` to have a structured report handler - `tracing_subscriber` to collect scoped, structured and async-aware log data Signed-off-by: Riccardo Gallo <[email protected]>
Welcome to Codecov 🎉Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests. Thanks for integrating Codecov - We've got you covered ☂️ |
0ca718d
to
5830171
Compare
0fcd3ec
to
a6f84a6
Compare
a6f84a6
to
498dd70
Compare
d775c12
to
7c6b1b5
Compare
835921f
to
04d4e6a
Compare
04d4e6a
to
34ba2a2
Compare
I would check the other functions like |
Yes, for this one I used the original definition of the normalized sinc function, which differs from the implementation in the stream-qt5-test |
This required also the introduction of some environment variables and structures to handle the generation of the samples to be sent to Astarte. For simplicity, the math functions are the same as the ones used in the stream-qt5-test repository. Signed-off-by: Riccardo Gallo <[email protected]>
Use clap to start the application, also taking into account possible environment variables set by the user. Signed-off-by: Riccardo Gallo <[email protected]>
Now the configuration information to connect a device to Astarte are provided inside a `astarte-device-DEVICE_ID_HERE-conf` directory, in a `config.toml` file. Instead, all the information necessary to generate samples to be sent to Astarte are provided via CLI or environment variables. Also the README have been update to explain how to configure the application and build/run it. Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
Provide the Atsarte configuration via environment variables or config.toml file, prioritizing env vars Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
Give more flexibility to choose the mqtt or grpc Astarte connection configuration by using the CLI, environment variables and a config.toml file Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
34ba2a2
to
ba6c64d
Compare
e0eb289
to
6db96f7
Compare
Signed-off-by: Riccardo Gallo <[email protected]>
Now it is only possible to specify the type of connection (mqtt or grpc) through the ASTARTE_CONNECTION env variable. The application will first try to retrieve the config from env; if an error occurs, it tries to retrieve them from a config.toml (if a path has beem specified). The merge operation for the 2 sources of config has been removed. Signed-off-by: Riccardo Gallo <[email protected]>
Signed-off-by: Riccardo Gallo <[email protected]>
bc38219
to
55ebee7
Compare
This pull request introduces a Rust application that initiates an Astarte device, establishes an MQTT connection to a running Astarte instance, and sends data generated from a set of predefined mathematical functions.
Key Features:
config.toml
file, which contains the necessary information to connect the device to the Astarte instance.This work is inspired by and builds upon what has been done in the stream-qt5-test repository.
Closes #3