export declare const UF2_MAGIC_START0 = 171066965;
export declare const UF2_MAGIC_START1 = 2656915799;
export declare const UF2_MAGIC_END = 179400496;
export declare const UF2_FLAG_NONE = 0;
export declare const UF2_FLAG_NOFLASH = 1;
export declare const UF2_FLAG_FILE = 4096;
export declare const UF2_FLAG_FAMILY_ID_PRESENT = 8192;
export interface UF2Block {
    flags: number;
    targetAddr: number;
    payloadSize: number;
    blockNo: number;
    numBlocks: number;
    fileSize: number;
    familyId: number;
    filename?: string;
    data: Uint8Array;
    origData?: Uint8Array;
}
export declare function parseUF2File(blocks: Uint8Array): UF2Block[];
export interface ShiftedBuffer {
    start: number;
    buf: Uint8Array;
}
export declare function uf2ToBin(blocks: Uint8Array, endAddr?: number): ShiftedBuffer;
export declare function readBytesFromUF2(blocks: UF2Block[], addr: number, length: number): Uint8Array;
export declare class UF2File {
    currBlock: Uint8Array;
    currPtr: number;
    blocks: Uint8Array[];
    ptrs: number[];
    filename: string;
    filesize: number;
    familyId: number;
    fromBlocks: UF2Block[];
    constructor(familyId?: string | number);
    static concat(fs: UF2File[]): UF2File;
    static isUF2(uf2: Uint8Array): boolean;
    static fromFile(uf2: Uint8Array): UF2File;
    finalize(): void;
    serialize(): Uint8Array;
    readBytes(addr: number, length: number): Uint8Array;
    writeBytes(addr: number, bytes: ArrayLike<number>, flags?: number): void;
    writeHex(hex: string[]): void;
}
//# sourceMappingURL=uf2.d.ts.map