MityDSP Documentation Index

MityDSP::tcDspBootloader Class Reference

Static class to provide application level wrappers for reprogramming MityDSP application and bootloader FPGA and DSP images from a running application. More...

#include <core/DspBootloader.h>

List of all members.

Classes

struct  tsNotifyEvent

Public Types

enum  teState {
  eeIdle, eeParsingHexFile, eeErasingFlash, eeProgrammingFlash,
  eeProgrammingComplete
}

Public Member Functions

MBX_Handle Mailbox ()
int ReprogramApp (int anAppID, const char *apFileName)
 This routine updates the DSP application code with the contents of the file specified by the provided FileName.
int ReprogramApp (int anAppID, char *apBuffer, int anBufLen)
 This routine updates the DSP application code with the contents of the buffer provided.
int ReprogramFpga (int anAppID, const char *apFileName)
 This routine updates the FPGA image with the contents of the file specified by the provided FileName.
int ReprogramFpga (int anAppID, char *apBuffer, int anBufLen)
 This routine updates the FPGA image with the contents of the buffer provided.
int ReprogramCLUBApp (const char *apFileName)
 This routine updates the DSP Critical Link Unified bootloader code with the contents of the file specified by the provided FileName.
int ReprogramCLUBApp (char *apBuffer, int anBufLen)
 This routine updates the DSP Critical Link Unified bootloader code with the contents of the buffer provided.
int ReprogramCLUBFpga (const char *apFileName)
 This routine updates the DSP Critical Link Unified bootloader FPGA image with the contents of the file specified by the provided FileName.
int ReprogramCLUBFpga (char *apBuffer, int anBufLen)
 This routine updates the DSP Critical Link Unified bootloader FPGA image with the contents of the buffer provided.
int ReprogramBootstrapper (const char *apFileName)
 This routine updates the DSP Critical Link Unified bootloader bootstrapper image with the contents of the file specified by the provided FileName.
int ReprogramBootstrapper (char *apBuffer, int anBufLen)
 This routine updates the DSP Critical Link Unified bootloader bootstrapper image with the contents of the buffer provided.
int DecodeFileToFLASH (const char *apFileName, unsigned int anBuffSize, unsigned int anBuffOffset, bool IsDSPCode)
 This routine Decodes an Intel HEX file into a buffer and programes it to FLASH at the offset specified.
int WriteBufferToFLASH (char *apBuffer, unsigned int anBufLen, unsigned int buffsize, unsigned int buffoffset, bool IsDSPCode)
 This routine writes a bootloader GUI image file (already decoded from the normal Intel HEX format) to the specified location in FLASH.

Static Public Member Functions

static tcDspBootloaderGetInstance (void)

Detailed Description

Static class to provide application level wrappers for reprogramming MityDSP application and bootloader FPGA and DSP images from a running application.

See also:
tcDspBootloader Page

Member Enumeration Documentation

Enumerator:
eeIdle 
eeParsingHexFile 
eeErasingFlash 
eeProgrammingFlash 
eeProgrammingComplete 

Member Function Documentation

tcDspBootloader * tcDspBootloader::GetInstance ( void   )  [static]
MBX_Handle MityDSP::tcDspBootloader::Mailbox (  )  [inline]
int tcDspBootloader::ReprogramApp ( int  anAppID,
const char *  apFileName 
)

This routine updates the DSP application code with the contents of the file specified by the provided FileName.

It is assumed that the file is consistent with a file provided to the MityGUI application.

Parameters:
[in] anAppID Application index to reprogram (0 through 7)
[in] apFileName Fully qualified filename of file to reprogram
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramApp ( int  anAppID,
char *  apBuffer,
int  anBufLen 
)

This routine updates the DSP application code with the contents of the buffer provided.

It is assumed that the buffer represents the decoded hex file consistent with a file provided to the MityGUI application.

Note:
NO BYTE SWAPPING should be performed (it will be done within this method as required)
Parameters:
[in] anAppID Application index to reprogram (0 through 7)
[in] apBuffer Buffer containing decoded HEX file used by MityGUI
[in] anBufLen Length of the buffer
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramFpga ( int  anAppID,
const char *  apFileName 
)

This routine updates the FPGA image with the contents of the file specified by the provided FileName.

It is assumed that the file is consistent with a file provided to the MityGUI application.

Parameters:
[in] anAppID Application index to reprogram (1 through 8)
[in] apFileName Fully qualified filename of file to reprogram
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramFpga ( int  anAppID,
char *  apBuffer,
int  anBufLen 
)

This routine updates the FPGA image with the contents of the buffer provided.

It is assumed that the buffer represents the decoded hex file consistent with a file provided to the MityGUI application.

Parameters:
[in] anAppID Application index to reprogram (0 through 7)
[in] apBuffer Buffer containing decoded HEX file used by MityGUI
[in] anBufLen Length of the buffer
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramCLUBApp ( const char *  apFileName  ) 

This routine updates the DSP Critical Link Unified bootloader code with the contents of the file specified by the provided FileName.

It is assumed that the file is consistent with a file provided to the MityGUI application.

Parameters:
[in] apFileName Fully qualified filename of file to reprogram
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramCLUBApp ( char *  apBuffer,
int  anBufLen 
)

This routine updates the DSP Critical Link Unified bootloader code with the contents of the buffer provided.

It is assumed that the buffer is a decoded file consistent with a file provided to the MityGUI application.

Parameters:
[in] apBuffer Buffer containing decoded HEX file used by MityGUI
[in] anBufLen Length of the buffer
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramCLUBFpga ( const char *  apFileName  ) 

This routine updates the DSP Critical Link Unified bootloader FPGA image with the contents of the file specified by the provided FileName.

It is assumed that the file is consistent with a file provided to the MityGUI application.

Parameters:
[in] apFileName Fully qualified filename of file to reprogram
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramCLUBFpga ( char *  apBuffer,
int  anBufLen 
)

This routine updates the DSP Critical Link Unified bootloader FPGA image with the contents of the buffer provided.

It is assumed that the buffer is consistent with a file provided to the MityGUI application.

Parameters:
[in] apBuffer Buffer containing decoded HEX file used by MityGUI
[in] anBufLen Length of the buffer
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramBootstrapper ( const char *  apFileName  ) 

This routine updates the DSP Critical Link Unified bootloader bootstrapper image with the contents of the file specified by the provided FileName.

It is assumed that the file is consistent with a file provided to the MityGUI application.

Parameters:
[in] apFileName Fully qualified filename of file to reprogram
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::ReprogramBootstrapper ( char *  apBuffer,
int  anBufLen 
)

This routine updates the DSP Critical Link Unified bootloader bootstrapper image with the contents of the buffer provided.

It is assumed that the file is consistent with a file provided to the MityGUI application.

Parameters:
[in] apBuffer Buffer containing decoded HEX file used by MityGUI
[in] anBufLen Length of the buffer
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::DecodeFileToFLASH ( const char *  apFileName,
unsigned int  anBuffSize,
unsigned int  anBuffOffset,
bool  abIsDSPCode 
)

This routine Decodes an Intel HEX file into a buffer and programes it to FLASH at the offset specified.

Parameters:
[in] apFileName Fully qualified filename of file to decode
[in] anBuffSize Maximum size of the FLASH buffer
[in] anBuffOffset Offset into FLASH to write the buffer
[in] abIsDSPCode When true, Data is APPLICATION code
Note:
this method allocates a buffer the size of anBuffSize onto the heap. It is deallocated upon exit of this routine.
Returns:
Number of Bytes Programmed, or negative number on error
int tcDspBootloader::WriteBufferToFLASH ( char *  apBuffer,
unsigned int  anBufLen,
unsigned int  anBlockSize,
unsigned int  anBlockOffset,
bool  abIsDSPCode 
)

This routine writes a bootloader GUI image file (already decoded from the normal Intel HEX format) to the specified location in FLASH.

NOTE: if byte swapping is required, the provided buffer will be modified.

Parameters:
[in] apBuffer the buffer containing the image
[in] anBufLen Length of the provided buffer
[in] anBlockSize Maximum size of the FLASH buffer
[in] anBlockOffset Offset into FLASH to write the buffer
[in] abIsDSPCode When true, Data is APPLICATION code
Returns:
Number of Bytes Programmed, or negative number on error

  
Generated on Fri Sep 23 16:33:47 2011 for MityDSP Core by  Doxygen Version 1.6.1
Copyright © 2009, Critical Link LLC, All rights reserved.