CorefluxMQTTcSharpAPI 1.3.2
dotnet add package CorefluxMQTTcSharpAPI --version 1.3.2
NuGet\Install-Package CorefluxMQTTcSharpAPI -Version 1.3.2
<PackageReference Include="CorefluxMQTTcSharpAPI" Version="1.3.2" />
<PackageVersion Include="CorefluxMQTTcSharpAPI" Version="1.3.2" />
<PackageReference Include="CorefluxMQTTcSharpAPI" />
paket add CorefluxMQTTcSharpAPI --version 1.3.2
#r "nuget: CorefluxMQTTcSharpAPI, 1.3.2"
#addin nuget:?package=CorefluxMQTTcSharpAPI&version=1.3.2
#tool nuget:?package=CorefluxMQTTcSharpAPI&version=1.3.2
Coreflux C# API
This nuget package is resposible for all integration with C# and Coreflux.
Coreflux Start / Stop Asset
Usage
Add the necessary namespaces in your project
using Coreflux.API;
Get all installed assets @ our Coreflux Hub and if they are stopped Start them
Coreflux.API.Client API = new Coreflux.API.Client("localhost", Coreflux.API.Client.Version.LegacyHTTPS); var InstalledAssets = API.GetInstances(); foreach(var inst in InstalledAssets) { if(inst.status== Coreflux.API.DataModels.InstanceStatus.Stopped) { API.StartInstance(inst.code); } }
Get all installed assets @ our Coreflux Hub and if they are started / stop them
Coreflux.API.Client API = new Coreflux.API.Client("localhost", Coreflux.API.Client.Version.LegacyHTTPS); var InstalledAssets = API.GetInstances(); foreach(var inst in InstalledAssets) { if(inst.status== Coreflux.API.DataModels.InstanceStatus.Started) { API.StopInstance(inst.code); } }
Coreflux MQTT Managed client
The MQTT namespace enables MQTT communication within your development. There is already in place an MQTT Managed client.
Usage
Add the necessary namespaces in your project
using Coreflux.API.Networking.MQTT;
Call the managed mqtt client from Coreflux
MQTTController.Start("127.0.0.1", 1883);
//using IP with normal TCP/IP socket
MQTTController.Start("cloud.coreflux.org", 1883);
//using dns with normal TCP/IP socket
MQTTController.Start("cloud.coreflux.org:8080/mqtt", 8080, "", "", false, true);
//using dns , without username "", no password , no TLS and with websocket
- Connect the events
MQTTController.NewPayload += this.MQTTController_NewPayload;
//Provides a standard reception of subscribed topics
This is asynchronous usage
- Subscribe
string payload=MQTTController.GetData("mytopic/teste");
// provides the payload of a topic directly from the cache of the managed mqtt client
This is synchronous usage
- Publish
MQTTController.SetData("mytopic/teste", "payload", 0, false);
// Publishes the value to the topic with the payload . In this case without retain(false) and QOS 0.
System Compatibility
- Windows 11 ( tested) , 10, IoT , 7
- Linux ( Ubuntu , Raspian, Debian,etc..)
- Android (Phones,SmartTVs)
- IOs
- macOS
Protocols
- MQTT 3.1 / 3.1.1 /5.00
Nuget
There is a nuget package available Coreflux Nuget
Author
http://coreflux.org - Coreflux the most advanced industrial IOT platform!
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
.NETStandard 2.0
- MQTTnet (>= 3.0.16)
- Newtonsoft.Json (>= 13.0.2-beta1)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on CorefluxMQTTcSharpAPI:
Package | Downloads |
---|---|
SLServiceEngRef Package Description |
repositories
This package is not used by any popular repositories.
Version | Downloads | Last updated | |
---|---|---|---|
1.3.2 | 1,652 | 8/30/2022 | |
1.3.1.9 | 976 | 8/23/2022 | |
1.3.1.8 | 1,327 | 5/23/2022 | |
1.3.1.7 | 515 | 5/23/2022 | |
1.3.1.6 | 523 | 5/19/2022 | |
1.3.1.4 | 1,011 | 5/16/2022 | |
1.3.1.1 | 811 | 4/27/2022 | |
1.3.1 | 1,499 | 4/26/2022 | |
1.3.0.3 | 657 | 4/25/2022 | |
1.3.0 | 802 | 4/3/2022 | |
1.2.0.2 | 1,331 | 11/15/2021 | |
1.2.0.1 | 425 | 11/15/2021 | |
1.2.0 | 539 | 10/24/2021 | |
1.1.0.3 | 813 | 10/8/2021 | |
1.1.0.1 | 479 | 10/8/2021 | |
1.0.0.1 | 534 | 11/27/2020 | |
1.0.0 | 529 | 11/17/2020 |