class iox.FpgaUploader

class FpgaUploader {
    // enums

    enum {
        AtomSize           = 4,
        BlockSize          = 64,
        TimerInterval      = 100,
        StatusCheckCount   = 5,
        StillWaitingFactor = 1000 / TimerInterval,
    };

    enum State;
    bitflag enum Status;
    enum UsbControlReqCode;
    enum UsbControlReqType;

    // events

    event m_onUpdateCompleted(bool result);

    // construction

    construct(doc.PluginHost* pluginHost);

    // methods

    void cancel();

    bool errorcode update(
        io.UsbDevice* device,
        string_t fileName,
        size_t baseIndex
    );
};