Texas Instruments MSP430 manual FN0007/ EraseFile, FN0008/ EraseCheck

Page 27

PRGS430.DLL—Description

Note: For some MSP430 family members, e.g., MSP430F2xxx devices, portions of flash information memory are factory preprogrammed with calibration data. Depending on which method is used for erasing the flash memory, this calibration data may be erased. Should the calibration data be conserved, it must be read out prior to the information memory erase or a flash erase method that does not affect the calibration data memory locations must be used. See the respective device data sheet for further information on preprogrammed calibration data memory locations.

/FN0007/ EraseFile

long int EraseFile(char* lpszFileName, long int iFileType, long int Flags, char* lpszProjectIni)

EraseFile() erases all addresses used in the specified file.

iFileType:

 

 

FILETYPE_AUTO

(0x00)

− Autodetection of file type (Intel-hex or

 

TI-TXT)

FILETYPE_TI_TXT

(0x01)

− File type is TI-TXT

FILETYPE_INTEL_HEX(0x02) − File type is Intel-hex

Flags:

DISABLE_TI_MEM_PROTECT (0x01)

If this bit is set, the memory protection setting device.cfg is ignored.

lpszProjectIni: name of the {project}.ini file, if protection settings from this file shall be used. If there is no protection, replace lpszProjectIni with NULL.

Example:

lFuncReturn = EraseFile(”text.txt”, long:0, long:0,

NULL)

Note: For some MSP430 family members, e.g. MSP430F2xxx devices, portions of flash information memory are factory preprogrammed with calibration data. Depending on which method is used for erasing the flash memory, this calibration data may be erased. Should the calibration data be conserved, it must be read out prior to the information memory erase or a flash erase method that does not affect the calibration data memory locations must be used. See the respective device data sheet for further information on preprogrammed calibration data memory locations.

/FN0008/ EraseCheck

long int EraseCheck(long int wStart, long int wLength)

Performs an erase check of an area of the target memory

wStart: Start address of the memory area. Allowed values : 0x0000−0xFFFE (see memory map of the corresponding device).

wLength: Size of the area. Allowed values : 0x0000−0xFFFE (see memory map of the corresponding device)

The function EraseCheck() simply uses PatternCheck(), with 0xFFFF as pattern.

EraseCheck(long int wStart, long int wLength)

{

return PatternCheck(wStart, wLength, 0xFFFF);

}

Example:

lFuncReturn = EraseCheck(long:0xF000, long:0x1000)

Operation 2-15

Image 27
Contents User’s Guide Evaluation BOARD/KIT Important Notice EVM Warnings and Restrictions Page About This Manual Read This FirstFCC Warning Contents Tables FiguresInstallation and Setup −1. ADT430 Program Icons Installing the SoftwareMSP−PRGS430 Installing the HardwarePage Operation Software/Hardware Layers of the PRGS430 Environment Programming MSP430 Devices With the GUI Basic Procedure−1. MSP430 Function Buttons and Descriptions Description of the MSP-PRGS430 GUIOperation2-5 −2. Communication Error Box Error Messages−5. Data Error −2. Error Messages Use of a Project.ini File Content of PRGS430.ini FileGeneral Definitions Command Line OptionsExample Return Values/Error Codes in .ini File FN0003/ SetDeviceType PRGS430.DLL-DescriptionFN0001/ InitCom FN0002/ ReleaseComFN0004/ InitTarget FN0005/ ReleaseTargetFN0006/ Erase FN0008/ EraseCheck FN0007/ EraseFileFN0009/ EraseCheckFile FN00010/ PatternCheckFN00011/ VerifyData FN00012/ VerifyFile FN00013/ VerifyFileRangeFN0014/ ProgramData Pgmwitherasecheck FN0015/ ProgramFileFN0016/ BlowFuse FN0017/ SetVccFN0018/ ReadOutData FN0019/ ReadOutFile FN0020/ ResetFN0023/ GetDeviceCfgInfo FN0022/ SetNotificationWndFN0024/ AccessSFR Status Return Value Comment Return Values/Error Codes From PRGS430.DLLPage Hardware Basic Hints Specifications−1 -Pin Sub-D at Programming Adapter Programming Adapter Target Connector Signals−2. Target Connector Signal Functions Location of Components − MSP-PRGS430 MSP-PRGS430 Circuit DiagramsInterconnection of MSP-PRGS430 to OTP/EPROM-Based Interconnection of MSP−PRGS430 to Flash-Based MSP430 Devices Page Hex Object Format Figure A−1. Intel-Hex Object Format Intel-Hex Object FormatTI-TXT File Format Page Schematics Page Schematics B-3 Page Important Notice
Related manuals
Manual 138 pages 30.24 Kb