SLAU358Q September 2011 – October 2019
Set of functions that return the names of all supported MCUs, including the family, group, and MCU name.
Syntax
LONG WINAPI MSPGANG_Get_qty_MCU_Type( void );
LONG WINAPI MSPGANG_Set_MCU_Type( int type );
LONG WINAPI MSPGANG_Get_MCU_TypeName( LONG index, LPTSTR name );
LONG WINAPI MSPGANG_Get_qty_MCU_Family( void );
LONG WINAPI MSPGANG_Get_MCU_FamilyName( LONG index, LPTSTR name );
LONG WINAPI MSPGANG_Get_MCU_Name( LONG group_index, LONG index, LPTSTR name );
Use these functions in the following order:
typedef struct
{
int no;
char name[24];
} MCU_FAMILY;
MCU_FAMILY MCU_family_list[30];
typedef struct
{
int index;
char name[24];
} MCU_NAME;
MCU_NAME MCU_name_list[100];
n = MSPGANG_Get_qty_MCU_Family(); //get no of MCU groups
for(k=0; k<n; k++)
{
P = MSPGANG_Get_MCU_FamilyName(k, MCU_family_list[k].name);
If(p == 0) break;
MCU_family_list[k].no = p;
}
The following names and numbers are received using the previous functions:
MCU_Family_list
{ 1, " MSP430" },
{ 0x20, " MSP430FR" },
{ 0x10, " CC430" },
{ 0x80, " MSP432" },
MCU_Group_list
{ 1, 1, " MSP430F1xx" },
{ 20, 1, " MSP430F2xx" },
{ 22, 1, " MSP430AFE2xx" },
{ 21, 1, " MSP430G2xx" },
{ 23, 1, " MSP430i2xx" },
{ 25, 1, " MSP430Txxx" },
{ 40, 1, " MSP430F4xx" },
{ 41, 1, " MSP430FE4xx" },
{ 42, 1, " MSP430FG4xx" },
{ 43, 1, " MSP430FW4xx" },
{ 50, 1, " MSP430F5xx" },
{ 60, 1, " MSP430F6xx" },
{ 62, 1, " MSP430FG6xx" },
{ 55, 0x20, " MSP430FR2xx" },
{ 56, 0x20, " MSP430FR4xx" },
{ 57, 0x20, " MSP430FR5xx" },
{ 67, 0x20, " MSP430FR6xx" },
{ 51, 0x10, " CC-430F5xx" },
{ 61, 0x10, " CC-430F6xx" },
{ 0x84,0x80, " MSP432P4xx" },
{ 0x85,0x80, " MSP432E4xx" },
List of the MCU names in a selected group can be found as follows (in this example, a list of the MCUs from the MSP430F5xx group (group number 50)):
for(n = 0; n< 100; n++) MCU_name_list[n].index = 0;
for(n = 0; n< 100; n++)
{
p = MSPGANG_Get_MCU_Name(50, n, MCU_name_list[n].name);
if(p == 0) break;
MCU_name_list[n].index = n;
}