serial_getdevicename() 개인적인 메소드

private serial_getdevicename ( RJCP.IO.Ports.Native.Unix.SafeSerialHandle handle ) : IntPtr
handle RJCP.IO.Ports.Native.Unix.SafeSerialHandle
리턴 IntPtr
예제 #1
0
        public string serial_getdevicename(SafeSerialHandle handle)
        {
            IntPtr deviceName = UnsafeNativeMethods.serial_getdevicename(handle);

            errno = Marshal.GetLastWin32Error();
            if (deviceName.Equals(IntPtr.Zero))
            {
                return(null);
            }
            return(Marshal.PtrToStringAnsi(deviceName));
        }