public override void Entry() { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.Write("Demo Start", 0, 0); Thread.Sleep(1000); MainHandle.Context.CurrentState = new MainState(MainHandle); }
private void PrintLastDate() { ReadData(); if (_Data != null) { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("The last date save in the SDCard : " + _Data.LastDate.ToString()); } }
public override void Entry() { //To do at the start (subscribe events...) ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("Hello World !"); Thread.Sleep(1000); StartListen(); //start timer and interface (button Home, back and joystick) Timer.Tick += Timer_Tick; }
public override void Entry() { StartListen(); ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("Press and move the joystick."); _x = MainHandle.Display_N18.Width / 2; _y = MainHandle.Display_N18.Height / 2; Draw(); }
public override void Entry() { StartListen(); ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("Size Display : " + ConsoleDisplayN18.Screen.Width + "x" + ConsoleDisplayN18.Screen.Height); ConsoleDisplayN18.WriteLine("Line 2"); ConsoleDisplayN18.WriteLine("Line 3"); ConsoleDisplayN18.WriteLine("Line 4"); ConsoleDisplayN18.WriteLine("Line 5"); ConsoleDisplayN18.WriteLine("0123456789X123........456789X123456___________789X12345"); ConsoleDisplayN18.WriteLine("Line 9\nLine 10\nLine 11\nLine 12\nLine 13"); }
public override void Entry() { if (_Tunes == null) { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("The module Tunes is not connected.You have to connect in the socket 3 and in the Gadgeteer's designer(don't forget to recompile the project)."); Thread.Sleep(2000); MainHandle.Context.GoBack(); } else { StartListen(); } }
public override void Entry() { StartListen(); ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("About this DEMO Gadgeteer"); ConsoleDisplayN18.WriteLine("Mainboard :"); ConsoleDisplayN18.WriteLine(MainHandle.MotherCard.MainboardName); ConsoleDisplayN18.WriteLine(MainHandle.MotherCard.MainboardVersion); ConsoleDisplayN18.WriteLine("Framework :"); ConsoleDisplayN18.WriteLine(SystemInfo.Version.ToString()); ConsoleDisplayN18.WriteLine("Logiciel :"); ConsoleDisplayN18.WriteLine(Assembly.GetExecutingAssembly().GetName().Name); ConsoleDisplayN18.WriteLine(Assembly.GetExecutingAssembly().GetName().Version.ToString()); }
public override void Exit() { //To do at the end (desubscribe events...) if (MainHandle.SdCard.IsCardMounted) { //save date _Data = new ExampleData(); _Data.LastDate = DateTime.Now; SaveData(); } else { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("Sorry I cannot save the date."); Thread.Sleep(1000); } StopListen();//Stop timer and interface }
public override void Entry() { if (MainHandle.LED_Strip == null) { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("The module Led Strip is not connected.You have to connect in the socket 3 and in the Gadgeteer's designer(don't forget to recompile the project)."); Thread.Sleep(2000); MainHandle.Context.GoBack(); } else { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("Demo led strip !"); StartListen(); //start timer and interface (button Home, back and joystick) MainHandle.LED_Strip.TurnAllLedsOn(); Thread.Sleep(1000); Timer.Tick += Timer_Tick; } }
private bool IsMountSdCard() { bool result = false; if (!MainHandle.SdCard.IsCardInserted) { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("Insert the SDCard."); ConsoleDisplayN18.WriteLine("After press Joystick."); } else { if (!MainHandle.SdCard.IsCardMounted) { MainHandle.SdCard.MountSDCard(); } result = true; } return(result); }
public override void Entry() { ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine(Error.Message + " " + Error.StackTrace); }
public override void Entry() { StartListen(); ConsoleDisplayN18.Clear(); ConsoleDisplayN18.WriteLine("Press the joystick to turn on/off the button's led."); }