unsafe public static int WriteTRXEEPROMUshort(uint offset, ushort buf) { byte[] temp = BitConverter.GetBytes(buf); fixed(byte *ptr = &temp[0]) return(USBHIDAPI.WriteEEPROM((ushort)offset, 2, ptr)); }
unsafe public static int WriteTRXEEPROMFloat(uint offset, float val) { byte[] temp = BitConverter.GetBytes(val); fixed(byte *ptr = &temp[0]) return(USBHIDAPI.WriteEEPROM((ushort)offset, 4, ptr)); }
unsafe public static int WriteEEPROM(ushort addr, byte num_bytes, byte[] buf) { fixed(byte *ptr = &buf[0]) return(USBHIDAPI.WriteEEPROM(addr, (byte)num_bytes, ptr)); }
unsafe public static int WriteEEPROM(ushort addr, byte[] buf) // up to 32 bytes { fixed(byte *ptr = &buf[0]) return(USBHIDAPI.WriteEEPROM(addr, (byte)buf.Length, ptr)); }
unsafe public static int WriteTRXEEPROMByte(uint offset, byte buf) { return(USBHIDAPI.WriteEEPROM((ushort)offset, 1, &buf)); }