Texas-instruments TMS320C6000 User Manual Page 43

  • Download
  • Add to my manuals
  • Print
  • Page
    / 62
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 42
FLASH_checksum
6-3
FLASH API Module
6.2 FLASH API Reference
Returns checksum of specified Flash data
FLASH_checksum
Function Uint32 FLASH_checksum(
Uint32 locator,
Uint32 length
);
Arguments locator Addressing and page information for location in Flash
memory.
C6711 DSK
- FLASH_START_ADDR
- FLASH_PAGE_ADDR(x) :(x)– page number
- 32-bit FLASH address
length Length in bytes of data to be read. This is limited by the
size of the Flash memory.
Return Value Uint32 Returns the value of the specified checksum
Description Returns the checksum of the specified Flash data. Checksum calculated
by byte by byte addition.
Note: This function does not affect unspecified segments of Flash. For
example, altering the lower half of a page of Flash memory does not
change the value of the upper half page.
C6711 DSK
- locator contains 32-bit address of Flash location
-FLASH_START_ADDR is 0x9000000
- Flash address range: 0x90000000 to 0x90020000
- FLASH_PAGE_SIZE = 0x80: 128 bytes
- Page number range x: 0 to 1023
-FLASH_PAGE_ADDR(x) = FLASH_START_ADDR +
x*FLASH_PAGE_SIZE )
Note: On 5x boards, 16-bit addressing is used and page information is
included in the upper half-word of the address argument.
Example To get the checksum of page 0 and 1, use:
Uint32 startAddr = FLASH_PAGE_ADDR(0);
Uint32 length = FLASH_PAGE_SIZE * 2;
Uint32 checksum;
checksum = FLASH_checksum(startAddr,length);
Page view 42
1 2 ... 38 39 40 41 42 43 44 45 46 47 48 ... 61 62

Comments to this Manuals

No comments