public PortEnvoi(MidiManager m, MainActivity act) { manager = m; activity = act; texte = (TextView)activity.FindViewById <TextView>(Resource.Id.textViewDevice); manager.RegisterDeviceCallback(this, new Android.OS.Handler()); MidiDeviceInfo[] infos = manager.GetDevices(); foreach (MidiDeviceInfo info in infos) { onDeviceAdded(info); } manager.OpenDevice(portInfo, this, null); }