Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

During normal programming using Encapsulated Functions, such as F_AutoProgram, the Code Data Buffer is used to program the target device.

...

  • For custom modifications the Write Buffer can be used to write to the target device(s) without disturbing the Code Data Buffer. To modify the Write Buffer, use the function F_Put_Byte_to_Buffer. When using FlashPro-ARM, the one target will be modified, when using GangPro-ARM, all six targets will be written with the same data. Sequential Functions, such as F_Copy_Buffer_to_Flash can be used to write this buffer to target(s).

  • Additionally the GangPro-ARM library also has six Gang Write Buffers, where different custom data can be written to each of the six targets per adapter using the function F_Put_Byte_to_Gang_Buffer. Each target can be provided different data for the same address, i.e. calibration or serialization data. Use Sequential Functions, such as F_Copy_Gang_Buffer_to_Flash to write these buffers to targets.

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

...

2. F_ReadCodeFile_BaseAddr

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

...

3. F_AppendCodeFile
Anchor
F_AppendCodeFile
F_AppendCodeFile

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

...

  • FALSE (0) : failed

  • TRUE (1) : succeeded

  • STATUS_OPEN_FILE_ERROR (535): could not open file

  • STATUS_FILE_NAME_ERROR (536): format not supported

  • STATUS_MAX FILE_COUNT (557): total number of files exceeds MAX_FILE_INDEX (20)

  • STATUS_DUPLICATE_FILE PATH (558): appending already existing file

  • FPA_UNMATCHED_RESULTS (-1 or 0xFFFFFFFF) : Result of operation inconsistent across all selected FPAs, refer to F_ Multi API-DLL Functions | F_LastStatus

  • FPA_INVALID_NO (-2 or 0xFFFFFFFE) : FPA not opened with Multi API-DLL Functions | F_OpenInstancesAndFPAs or index out of range

4. F_AppendCodeFile_BaseAddr

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

...

  • FALSE (0) : failed

  • TRUE (1) : succeeded

  • STATUS_OPEN_FILE_ERROR (535): could not open file

  • STATUS_FILE_NAME_ERROR (536): format not supported

  • STATUS_MAX FILE_COUNT (557): total number of files exceeds MAX_FILE_INDEX (20)

  • STATUS_DUPLICATE_FILE PATH (558): appending already existing file

  • FPA_UNMATCHED_RESULTS (-1 or 0xFFFFFFFF) : Result of operation inconsistent across all selected FPAs, refer to Multi API-DLL Functions | F_LastStatus

  • FPA_INVALID_NO (-2 or 0xFFFFFFFE) : FPA not opened with Multi API-DLL Functions | F_OpenInstancesAndFPAs or index out of range

5. F_Get_CodeCS

...

Code Block
languagecpp
INT_X F_Get_CodeCS( INT_X dest )

Input

INT_X dest : choose operation

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

6. F_Clr_Code_Buffer

...

Select FPA to perform operation on using F Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

7. F_Put_Byte_to_Code_Buffer
Anchor
F_Put_Byte_to_Code_Buffer
F_Put_Byte_to_Code_Buffer

...

Code Block
INT_X  F_Put_Byte_to_Code_Buffer( INT_X addr, BYTE data );

Input

INT_X addr : valid flash address for target MCU

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

8. F_Get_Byte_from_Code_Buffer

...

Code Block
languagecpp
INT_X  F_Get_Byte_from_Code_Buffer( INT_X addr );

Input

INT_X addr : valid flash address for target MCU

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

9. F_Put_Byte_to_Buffer

...

Write byte to Write Buffer from FlashPro-ARM buffer https://elprotronic.atlassian.net/wiki/spaces/FPGPARM/pages/57704798/Data + Buffer +Functions#FlashProFunctions | FlashPro-ARM-buffers and GangPro-ARM buffer https://elprotronic.atlassian.net/wiki/spaces/FPGPARM/pages/57704798/Data + Buffer +Functions#GangProFunctions | GangPro-ARM-buffers.

Syntax

Code Block
languagecpp
INT_X  F_Put_Byte_to_Buffer( INT_X  addr, BYTE data );	

Input

INT_X addr : valid flash address for target MCU

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

  • FALSE (0) : failed

  • TRUE (1) : succeededFPA

  • STATUS_TXBUF_UNMATCHEDSIZE_RESULTS (-1 or 0xFFFFFFFF) : Result of operation inconsistent across all selected FPAs, refer to F_LastStatusFPA_INVALID_NO (-2 or ERROR (559): Temporary buffer full (4k), program contents with F_Copy_Buffer_to_Flash. This buffer is flushed when F_Open_Target_Device is called, or when addr is set to -1. Call F_Put_Byte_to_Buffer(-1, 0xFF); to flush buffer.

  • FPA_UNMATCHED_RESULTS (-1 or 0xFFFFFFFF) : Result of operation inconsistent across all selected FPAs, refer to Multi API-DLL Functions | F_LastStatus

  • FPA_INVALID_NO (-2 or 0xFFFFFFFE) : FPA not opened with Multi API-DLL Functions | F_OpenInstancesAndFPAs or index out of rangeout of range

Example

Insert excerpt
Custom Buffer Write and Verify - FlashPro-ARM
Custom Buffer Write and Verify - FlashPro-ARM

10. F_Get_Byte_from_Buffer (FlashPro-ARM only)

...

Code Block
languagecpp
INT_X  F_Get_Byte_from_Buffer( INT_X addr );

Input

INT_X addr : valid flash address for target MCU

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

11. F_Put_Byte_to_Gang_Buffer (GangPro-ARM only)
Anchor
F_Put_Byte_to_Gang_Buffer
F_Put_Byte_to_Gang_Buffer

General Description

Write byte to Gang Write Buffer from GangPro-ARM buffer https://elprotronic.atlassian.net/wiki/spaces/FPGPARM/pages/57704798/Data+Buffer+Functions#GangPro-ARM-buffers. This function will set one byte of data in a dedicated buffer for specified Gang target MCU (1 to 6). Use in combination with F_Copy_Gang_Buffer_to_Flash to actually write data to targets.

...

Select FPA to perform operation on using on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

Example

Insert excerpt
Custom Buffer Write and Verify - GangPro-ARM
Custom Buffer Write and Verify - GangPro-ARM

12. F_Get_Byte_from_Gang_Buffer (GangPro-ARM only)

...

BYTE target_no : MCU target number 1 to 6

INT_X addr : valid flash address for target MCU

...

Select FPA to perform operation on using Multi API-DLL Functions | F_Set_FPA_index, index 1 to 64. Use index 0 to perform operation on all FPAs (if results differ, use Multi API-DLL Functions | F_LastStatus to get individual results).

Output

INT_X : result of operation

Example

Refer to Data Buffer Functions | F_Put_Byte_to_Gang_Buffer