Beispiel #1
0
 /// <summary>
 /// Raises the <see cref="SDCardUnmounted"/> event.
 /// </summary>
 /// <param name="sender">The <see cref="SDCard"/> object that raised the event.</param>
 protected virtual void OnSDCardUnmountedEvent(SDCard sender)
 {
     if (_OnSDCardUnmounted == null)
     {
         _OnSDCardUnmounted = new SDCardUnmountedEventHandler(OnSDCardUnmountedEvent);
     }
     if (Program.CheckAndInvoke(SDCardUnmounted, _OnSDCardUnmounted, sender))
     {
         SDCardUnmounted(sender);
     }
 }
Beispiel #2
0
        private void OnUnmounted(SDCard sender, EventArgs e)
        {
            if (this.onUnmounted == null)
            {
                this.onUnmounted = this.OnUnmounted;
            }

            if (Program.CheckAndInvoke(this.Unmounted, this.onUnmounted, sender, e))
            {
                this.Unmounted(sender, e);
            }
        }
Beispiel #3
0
        private void OnMounted(SDCard sender, StorageDevice device)
        {
            if (this.onMounted == null)
            {
                this.onMounted = this.OnMounted;
            }

            if (Program.CheckAndInvoke(this.Mounted, this.onMounted, sender, device))
            {
                this.Mounted(sender, device);
            }
        }
Beispiel #4
0
 /// <summary>
 /// Raises the <see cref="SDCardMounted"/> event.
 /// </summary>
 /// <param name="sender">The <see cref="SDCard"/> object that raised the event.</param>
 /// <param name="SDCard">A storage device that can be used to access the SD non-volatile memory card.</param>
 protected virtual void OnSDCardMountedEvent(SDCard sender, StorageDevice SDCard)
 {
     if (_OnSDCardMounted == null)
     {
         _OnSDCardMounted = new SDCardMountedEventHandler(OnSDCardMountedEvent);
     }
     Thread.Sleep(1000);
     if (Program.CheckAndInvoke(SDCardMounted, _OnSDCardMounted, sender, SDCard))
     {
         SDCardMounted(sender, SDCard);
     }
 }
        public DataManager(Gadgeteer.Modules.GHIElectronics.SDCard _sdCard, Graphics _graphics)
        {
            sdCard     = _sdCard;
            graphics   = _graphics;
            sd_mounted = false;

            /*
             * Se añaden los eventos asociados a la tarjeta SD
             */

            sdCard.SDCardMounted   += new SDCard.SDCardMountedEventHandler(sdCard_SDCardMounted);
            sdCard.SDCardUnmounted += new SDCard.SDCardUnmountedEventHandler(sdCard_SDCardUnmounted);

            //Verifica el estado de la SD

            checkSDStatus();
        }
Beispiel #6
0
 public EditorForm(ref GHI.Glide.Display.Window window, ref Gadgeteer.Modules.GHIElectronics.SDCard sdCard, ref Gadgeteer.Modules.GHIElectronics.DisplayTE35 displayTE35) : base(ref window)
 {
     this.sdCard      = sdCard;
     this.displayTE35 = displayTE35;
 }
Beispiel #7
0
 public SDCard(GHIE.SDCard card)
 {
     sdCard = card;
 }