Meadow.Foundation.Sensors.Distance.Mb10x0
Mb10x0 | |
---|---|
Status | |
Source code | GitHub |
Datasheet(s) | GitHub |
NuGet package |
Mb10x0 sensor;
public MeadowApp()
{
Console.WriteLine("Initialize hardware...");
sensor = new Mb10x0(Device, Device.SerialPortNames.Com4);
while (true)
{
sensor.ReadSerial();
Thread.Sleep(500);
}
}
Sample project(s) available on GitHub
|
Code Example
Mb10x0 sensor;
public override Task Initialize()
{
Console.WriteLine("Initialize...");
sensor = new Mb10x0(Device, Device.SerialPortNames.Com4);
return Task.CompletedTask;
}
public override Task Run()
{
while (true)
{
sensor.ReadSerial();
Thread.Sleep(500);
}
return Task.CompletedTask;
}