Skip to content

Commit cfc13da

Browse files
committed
Adding more logs to Oculus demo
1 parent c3f206d commit cfc13da

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed

Project/OculusDemo/FormMain.cs

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,46 @@ unsafe public void OnHidEvent(object aSender, SharpLib.Hid.Event aHidEvent)
192192
{
193193
// Print our controller states in our console
194194
Console.SetCursorPosition(Console.WindowLeft, position);
195+
//Console.Clear();
196+
string blank = " ";
195197
Console.WriteLine(ctrl.Dump());
198+
if (isDownForward)
199+
{
200+
Console.WriteLine("Up");
201+
}
202+
else
203+
{
204+
Console.WriteLine(blank);
205+
}
206+
207+
if (isDownBackward)
208+
{
209+
Console.WriteLine("Down");
210+
}
211+
else
212+
{
213+
Console.WriteLine(blank);
214+
}
215+
216+
217+
if (isDownLeft)
218+
{
219+
Console.WriteLine("Left");
220+
}
221+
else
222+
{
223+
Console.WriteLine(blank);
224+
}
225+
226+
if (isDownRight)
227+
{
228+
Console.WriteLine("Right");
229+
}
230+
else
231+
{
232+
Console.WriteLine(blank);
233+
}
234+
196235
iStopWatch.Restart();
197236
}
198237

@@ -349,6 +388,8 @@ unsafe public void OnHidEvent(object aSender, SharpLib.Hid.Event aHidEvent)
349388
}
350389
}
351390

391+
392+
352393
iMutex.ReleaseMutex();
353394

354395
}

0 commit comments

Comments
 (0)