HEFreadBlock

Syntax:

    HEFreadBlock(buffer(), Flash_row, count)

Command availability:

Available on specific Microchip PIC microcontrollers only. Check your datasheet.

Explanation:

Buffer() is the destination byte array (must be sufficiently large)
Flash_row is the HEFM relative location (i.e. the row number)
Count is the number of bytes to be retrieved

HEFreadBlock reads information from the HEFM on chips that support this feature. buffer is a byte array of length equal to count. Reading starts at the beginning of given row number.

Example:

    #chip 16F1509, 8
    'The following example reads a byte vector
    'from row 0 of the HEFM of the 16F1509
    dim data(32)
    HEFreadBlock(data,0,HEFLASH_ROWSIZE)