Main Site Documentation

How can I verify if my USB Host socket (3) is working?


The camera I got from GHI doesn’t seem to work at all. I tried the USB host and it also doesn’t seem to work.

I get the error

when I run the sample GadgeteerCamera app.

I created another small app that just has the USB host and the drive connected event wired up. It never fires.

I verified that the camera works when plugged it directly into the USB client. I also verified that the USB host works when I plugged it directly into the USB client. I’m able to use the camera and browse the files on the USB drive as verification.

Socket 3 just doesn’t seem to work. Is there any way to verify if this is a board issue? I don’t have a spare board to test.

I updated the firmware when I received the kit (1/13).

Below is program.cs and program.generated.cs. I’ve also attached a picture of my hardware configuration.

using System;
using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Presentation;
using Microsoft.SPOT.Presentation.Controls;
using Microsoft.SPOT.Presentation.Media;
using Microsoft.SPOT.Touch;

using Gadgeteer.Networking;
using GT = Gadgeteer;
using GTM = Gadgeteer.Modules;
using Gadgeteer.Modules.GHIElectronics;

namespace GadgeteerCamera
    public partial class Program
        // This method is run when the mainboard is powered up or reset.   
        void ProgramStarted()
            Modules added in the Program.gadgeteer designer view are used by typing 
            their name followed by a period, e.g.  button.  or  camera.
            Many modules generate useful events. Type +=<tab><tab> to add a handler to an event, e.g.:
                button.ButtonPressed +=<tab><tab>
            If you want to do something periodically, use a GT.Timer and handle its Tick event, e.g.:
                GT.Timer timer = new GT.Timer(1000); // every second (1000ms)
                timer.Tick +=<tab><tab>

            button.ButtonPressed += button_ButtonPressed;
            camera.PictureCaptured += camera_PictureCaptured;

            // Use Debug.Print to show messages in Visual Studio's "Output" window during debugging.
            Debug.Print("Program Started");

        void camera_PictureCaptured(Camera sender, GT.Picture picture)
            display.SimpleGraphics.DisplayImage(picture, 5, 5);

        void button_ButtonPressed(Button sender, Button.ButtonState state)

// <auto-generated>
//     This code was generated by the Gadgeteer Designer.
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>

using Gadgeteer;
using GTM = Gadgeteer.Modules;

namespace GadgeteerCamera
    public partial class Program : Gadgeteer.Program
        // GTM.Module defintions
		Gadgeteer.Modules.GHIElectronics.Display_T35 display;
		Gadgeteer.Modules.GHIElectronics.Button button;
		Gadgeteer.Modules.GHIElectronics.Camera camera;

		public static void Main()
			//Important to initialize the Mainboard first
            Mainboard = new GHIElectronics.Gadgeteer.FEZSpider();			

            Program program = new Program();
            program.Run(); // Starts Dispatcher

        private void InitializeModules()
			// Initialize GTM.Modules and event handlers here.		
			camera = new GTM.GHIElectronics.Camera(3);
			display = new GTM.GHIElectronics.Display_T35(14, 13, 12, 10);
			button = new GTM.GHIElectronics.Button(11);