LocalArmbandInterface.cs 946 B

12345678910111213141516171819202122232425262728
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using System.Runtime.InteropServices;
  7. namespace SketchAssistantWPF
  8. {
  9. class LocalArmbandInterface
  10. {
  11. [DllImport (@"../Debug/StaticLibMotors.dll", EntryPoint = "?setupArmband@ArmbandInterface@@QAAHXZ",
  12. CallingConvention = CallingConvention.Cdecl)]
  13. public static extern int setupArmband();
  14. [DllImport(@"../Debug/StaticLibMotors.dll", EntryPoint = "?startVibrate@ArmbandInterface@@QAAXHM@Z",
  15. CallingConvention = CallingConvention.Cdecl)]
  16. public static extern void startVibrate(int motorNumber, float intensity);
  17. [DllImport(@"../Debug/StaticLibMotors.dll", EntryPoint = "?stopVibrate@ArmbandInterface@@QAAXH@Z",
  18. CallingConvention = CallingConvention.Cdecl)]
  19. public static extern void stopVibration(int motorNumber);
  20. //public void Vibrate()
  21. }
  22. }