/// <summary> /// Execution entry point. /// </summary> public static void Main() { int width, height, bpp, orientation; Microsoft.SPOT.Hardware.HardwareProvider hwProvider = Microsoft.SPOT.Hardware.HardwareProvider.HwProvider; hwProvider.GetLCDMetrics(out width, out height, out bpp, out orientation); // allocate one bitmap to be used as drawing canvas MyTouchScreen myTouchScreen = new MyTouchScreen(new TouchScreen.ActiveRectangle[] { new TouchScreen.ActiveRectangle(10, 20, 100, 100, null) }, new Bitmap(width, height)); // Touch notifications are not turned on by default. You need to // explicitly inform the Touch engine that you want touch events to // be pumped to your direction, and you want to work with the rest // of the architecture. Microsoft.SPOT.Touch.Touch.Initialize(myTouchScreen); // Start the application. myTouchScreen.Run(myTouchScreen); }
/// <summary> /// Execution entry point. /// </summary> public static void Main() { int width, height, bpp, orientation; Microsoft.SPOT.Hardware.HardwareProvider hwProvider = Microsoft.SPOT.Hardware.HardwareProvider.HwProvider; hwProvider.GetLCDMetrics(out width, out height, out bpp, out orientation); // allocate one bitmap to be used as drawing canvas MyTouchScreen myTouchScreen = new MyTouchScreen(new TouchScreen.ActiveRectangle[] { new TouchScreen.ActiveRectangle(10, 20, 100, 100, null) }, new Bitmap(width, height)); // Touch notifications are not turned on by default. You need to // explicitly inform the Touch engine that you want touch events to // be pumped to your direction, and you want to work with the rest // of the architecture. Microsoft.SPOT.Touch.Touch.Initialize(myTouchScreen); // Start the application. myTouchScreen.Run(myTouchScreen); }