File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -72,8 +72,12 @@ var motor = technicMediumHub.A.GetDevice<TechnicXLargeLinearMotor>();
7272
7373await motor .SetupNotificationAsync (motor .ModeIndexAbsolutePosition , true );
7474
75- // once upon a time later
75+ // observe using System.Reactive
76+ var disposable = motor .AbsolutePositionObservable .Subscribe (x => Console .WriteLine (x .SI ));
77+ // ... once finished observing (do not call immediately afterwards ;))
78+ disposable .Dispose ();
7679
80+ // OR manually observe it
7781Console .WriteLine (motor .AbsolutePosition );
7882````
7983
@@ -155,7 +159,7 @@ using (var kernel = new BluetoothKernel(poweredUpBluetoothAdapter, bluetoothAddr
155159 - .. other hubs depend on availability of hardware / contributions
156160 - Devices
157161 - [X] Technic Medium Hub - Rgb Light
158- - [ ] Technic Medium Hub - Current
162+ - [X ] Technic Medium Hub - Current
159163 - [ ] Technic Medium Hub - Voltage
160164 - [ ] Technic Medium Hub - Temperature Sensor 1
161165 - [ ] Technic Medium Hub - Temperature Sensor 2
You can’t perform that action at this time.
0 commit comments