Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
58 lines (46 sloc) 1.45 KB

Grove Button modules

Version: 1.0.0-preview3


Grove Button is connected as followed on Netduino3:


Grove Button Mainboard with base shield
Yellow wire Socket D7

Example of code:

using System.Threading;
using Bauland.Grove;
using Bauland.Pins;
using GHIElectronics.TinyCLR.Devices.Gpio;

namespace TestButton
    internal static class Program
        private static GpioPin _led;

        private static void Main()
            _led = GpioController.GetDefault().OpenPin(Netduino3.GpioPin.Led);

            // Button Grove module is connected as follow:
            // * yellow wire on D7
            // on a base shield connected on Netduino3 

            Button btn=new Button(Netduino3.GpioPin.D7);
            btn.ButtonPressed += Btn_ButtonPressed;
            btn.ButtonReleased += Btn_ButtonReleased;
            while (true)

        private static void Btn_ButtonReleased()

        private static void Btn_ButtonPressed()