void Loop10Ms() { /* get all the buttons */ FillBtns(ref _btns); /* on button1 press read talon configs */ if (_btns[1] && !_btnsLast[2]) { Debug.Print("read talon"); TalonSRXConfiguration read_talon; _talon.GetAllConfigs(out read_talon); Debug.Print(read_talon.ToString("_talon")); } /* on button2 press read victor configs */ else if (_btns[2] && !_btnsLast[2]) { Debug.Print("read victor"); VictorSPXConfiguration read_victor; _victor.GetAllConfigs(out read_victor); Debug.Print(read_victor.ToString("_victor")); } /* on button3 press read pigeon configs */ else if (_btns[3] && !_btnsLast[3]) { Debug.Print("read pigeon"); PigeonIMUConfiguration read_pigeon; _pigeon.GetAllConfigs(out read_pigeon); Debug.Print(read_pigeon.ToString("_pigeon")); } /* on button4 press read canifier configs */ else if (_btns[4] && !_btnsLast[4]) { Debug.Print("read canifier"); CANifierConfiguration read_canifier; _canifier.GetAllConfigs(out read_canifier); Debug.Print(read_canifier.ToString("_canifier")); } /* on button5 press set custom configs */ else if (_btns[5] && !_btnsLast[5]) { Debug.Print("custom config start"); _talon.ConfigAllSettings(_custom_configs._talon); _victor.ConfigAllSettings(_custom_configs._victor); _pigeon.ConfigAllSettings(_custom_configs._pigeon); _canifier.ConfigAllSettings(_custom_configs._canifier); Debug.Print("custom config finish"); } /* on button6 press set factory default */ else if (_btns[6] && !_btnsLast[6]) { Debug.Print("factory default start"); _talon.ConfigFactoryDefault(); _victor.ConfigFactoryDefault(); _pigeon.ConfigFactoryDefault(); _canifier.ConfigFactoryDefault(); Debug.Print("factory default finish"); } /* set last presses */ _btnsLast = (bool[])_btns.Clone(); }