public EEPROMStream(LokiBootloaderHost host, byte slaveAddress, long length) { this.host = host; this.slaveAddress = slaveAddress; this.length = length; this.readBuf = new byte[PAGE_SIZE]; this.readBufPosition = this.readBuf.Length; }
public void GetHidDevice() { CyHidDevice device = usbHIDDevices[VID, PID] as CyHidDevice; if (device != null) { channel = new HIDCommunicationsChannel(device); host = new LokiBootloaderHost(channel); host.EnterBootloader(); this.UseWaitCursor = true; readEEPROMWorker.RunWorkerAsync(); } else { OnDetach(); } }