static void set_all_relays(bool value) { Array relays = Enum.GetValues(typeof(Relays)); foreach (uint relay in relays) { NIUtils.Write_SingleDIO(relay, value); } }
static void write_SingleDIO(Relays relay, bool value) { NIUtils.Write_SingleDIO((uint)relay, value); }