Skip to content

Commit

Permalink
ISPTool V4.07.1206
Browse files Browse the repository at this point in the history
 - sync. ICPTool revision 7305
  • Loading branch information
CCTU authored and CCTU committed Dec 6, 2021
1 parent d9baedb commit 4bbeba4
Show file tree
Hide file tree
Showing 15 changed files with 91 additions and 239 deletions.
Binary file modified Documents/RH_ISP_Programming_Tool_EN_RevO.OO.docx
Binary file not shown.
Binary file modified Documents/UM_ISP_Programming_Tool_RevX.XX.doc
Binary file not shown.
17 changes: 2 additions & 15 deletions NuvoISP/DataBase/ChipDefs.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,6 @@ typedef enum {
NUC_CHIP_TYPE_M480 = 0x411,
NUC_CHIP_TYPE_I94000 = 0x414,
NUC_CHIP_TYPE_M460 = 0x49A,
NUC_CHIP_TYPE_M460HD = 0x49B,
NUC_CHIP_TYPE_M460LD = 0x49C,
NUC_CHIP_TYPE_NUC505 = 0x500,
NUC_CHIP_TYPE_KM1M7 = 0x600, // NTCJ M7
NUC_CHIP_TYPE_GENERAL_ARM7 = 0x700,
Expand Down Expand Up @@ -435,17 +433,6 @@ typedef enum {
# define M460_CLK_AHBCLK_KSCKEN 0x00002000UL

/* CONFIG 3 */
#define M460_FLASH_CONFIG_SPIMPSL 0x00000030UL
# define M460_FLASH_CONFIG_SPIMPSL_SEL0 0x00000000UL
# define M460_FLASH_CONFIG_SPIMPSL_SEL1 0x00000010UL
# define M460_FLASH_CONFIG_SPIMPSL_SEL2 0x00000020UL
# define M460_FLASH_CONFIG_SPIMPSL_SEL3 0x00000030UL
#define M460_FLASH_CONFIG_UART1PSL 0x00000003UL
# define M460_FLASH_CONFIG_UART1PSL_SEL0 0x00000000UL
# define M460_FLASH_CONFIG_UART1PSL_SEL1 0x00000001UL
# define M460_FLASH_CONFIG_UART1PSL_SEL2 0x00000002UL
# define M460_FLASH_CONFIG_UART1PSL_SEL3 0x00000003UL

#define M460_FLASH_CONFIG_UARTISPEN 0x00000100UL
#define M460_FLASH_CONFIG_USBISPDIS 0x00000200UL
#define M460_FLASH_CONFIG_CANISPEN 0x00000400UL
Expand Down Expand Up @@ -651,7 +638,7 @@ typedef enum {
# define OT8051_CONFIG_CLKDIV_2 0x02
# define OT8051_CONFIG_CLKDIV_1 0x01
# define OT8051_CONFIG_CLKDIV_0 0x00
#define OT8051_CONFIG_ADC_TRIGGER 0x08
#define OT8051_CONFIG_ADCINTEN 0x08

/* CONFIG 4 */
#define OT8051_CONFIG_WDT 0xF0
Expand All @@ -677,6 +664,6 @@ typedef enum {

#define OT8051_SID_MUG51_16K 0x6300

#define OT8051_SID_N76S003_MSS51 0x6700
#define OT8051_SID_N76S003_MG51 0x6700

#endif
4 changes: 3 additions & 1 deletion NuvoISP/DataBase/FlashInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -546,6 +546,7 @@ void *GetInfo(unsigned int uPID,
{ 512 * 1024, 0 * 1024, 160 * 1024, 0x00080000, 4 * 1024, 0x00D48740}, //M487KIDAE
{ 512 * 1024, 0 * 1024, 160 * 1024, 0x00080000, 4 * 1024, 0x00D48710}, //M487SIDAE
{ 256 * 1024, 0 * 1024, 128 * 1024, 0x00040000, 4 * 1024, 0x01348110}, //M481SGCAE
{ 128 * 1024, 0 * 1024, 64 * 1024, 0x00020000, 4 * 1024, 0x01348112}, //M481SE8AE
{ 256 * 1024, 0 * 1024, 128 * 1024, 0x00040000, 4 * 1024, 0x01348114}, //M481SGCAE2A
{ 256 * 1024, 0 * 1024, 128 * 1024, 0x00040000, 4 * 1024, 0x01348100}, //M481LGCAE
{ 128 * 1024, 0 * 1024, 64 * 1024, 0x00020000, 4 * 1024, 0x01348102}, //M481LE8AE
Expand Down Expand Up @@ -628,6 +629,7 @@ void *GetInfo(unsigned int uPID,
{ 256 * 1024, 0 * 1024, 32 * 1024, 0x00040000, 4 * 1024, 0x00F25140}, //M251KG6AE
{ 256 * 1024, 0 * 1024, 32 * 1024, 0x00040000, 4 * 1024, 0x00F25111}, //M251SG6AE
{ 256 * 1024, 0 * 1024, 32 * 1024, 0x00040000, 4 * 1024, 0x00F25102}, //M251LG6AE
{ 64 * 1024, 0 * 1024, 16 * 1024, 0x00010000, 4 * 1024, 0x00F25410}, //M254SD3AE
{ 128 * 1024, 0 * 1024, 16 * 1024, 0x00020000, 4 * 1024, 0x00F25411}, //M254SE3AE
{ 128 * 1024, 0 * 1024, 16 * 1024, 0x00020000, 4 * 1024, 0x00F25471}, //M254QE3AE
{ 128 * 1024, 0 * 1024, 16 * 1024, 0x00020000, 4 * 1024, 0x00F25441}, //M254KE3AE
Expand Down Expand Up @@ -782,7 +784,7 @@ void *GetInfo_8051_1T(unsigned int uDID,
// MUG51 (HAG049)
{ 16 * 1024, 0, 0x0400, 0x00006321, ((1 << 25) | (1 << 24) | (0x0F << 8) | (0 << 7) | (1 << 6) | (1 << 5) | (1 << 4) | (0 << 2) | (0 << 0))},

// 90nm (TC8258)
// MG51, N76S003 (KAG056)
//{ 18*1024, 0, 0x0300, 0x00006750, ((0 << 25) | (0 << 24) | (0x0E << 8) | (0 << 7) | (0 << 6) | (0 << 5) | (0 << 4) | (0 << 2) | (0 << 0))},
{ 18 * 1024, 0, 0x0400, 0x00006750, ((0 << 25) | (0 << 24) | (0x0E << 8) | (0 << 7) | (1 << 6) | (1 << 5) | (1 << 4) | (0 << 2) | (0 << 0))},
{ 16 * 1024, 0, 0x0400, 0x00006721, ((0 << 25) | (1 << 24) | (0x0E << 8) | (0 << 7) | (1 << 6) | (1 << 5) | (1 << 4) | (0 << 2) | (0 << 0))},
Expand Down
4 changes: 1 addition & 3 deletions NuvoISP/DataBase/NuDataBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,7 @@ bool GetChipStaticInfo(unsigned int uID)
uFlashType |= 0x200;
} else if ((uSeriesCode == IDD_DIALOG_CONFIGURATION_M480) //M480
|| (uSeriesCode == IDD_DIALOG_CONFIGURATION_M480LD)
|| (uSeriesCode == NUC_CHIP_TYPE_M460)
|| (uSeriesCode == NUC_CHIP_TYPE_M460HD)
|| (uSeriesCode == NUC_CHIP_TYPE_M460LD)) {
|| (uSeriesCode == NUC_CHIP_TYPE_M460)) {
uFlashType |= 0x300;
}

Expand Down
62 changes: 36 additions & 26 deletions NuvoISP/DataBase/PartNumID.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -645,6 +645,7 @@ struct CPartNumID g_PartNumIDs[] = {

/* M480LD series */
{"M481SGCAE", 0x01348110, IDD_DIALOG_CONFIGURATION_M480LD},
{"M481SE8AE", 0x01348112, IDD_DIALOG_CONFIGURATION_M480LD},
{"M481SGCAE2A", 0x01348114, IDD_DIALOG_CONFIGURATION_M480LD},
{"M481LGCAE", 0x01348100, IDD_DIALOG_CONFIGURATION_M480LD},
{"M481LE8AE", 0x01348102, IDD_DIALOG_CONFIGURATION_M480LD},
Expand Down Expand Up @@ -707,6 +708,7 @@ struct CPartNumID g_PartNumIDs[] = {
{"M251LG6AE", 0x00F25102, IDD_DIALOG_CHIP_SETTING_CFG_M251},

/* M254/6/8 series */
{"M254SD3AE", 0x00F25410, IDD_DIALOG_CHIP_SETTING_CFG_M258},
{"M254SE3AE", 0x00F25411, IDD_DIALOG_CHIP_SETTING_CFG_M258},
{"M254QE3AE", 0x00F25471, IDD_DIALOG_CHIP_SETTING_CFG_M258},
{"M254KE3AE", 0x00F25441, IDD_DIALOG_CHIP_SETTING_CFG_M258},
Expand Down Expand Up @@ -785,30 +787,30 @@ struct CPartNumID g_PartNumIDs[] = {
{"M031GTC1AE", 0x011316E1, NUC_CHIP_TYPE_M030G},

/* M460 */
{"M467SJHAE", 0x01B46710, NUC_CHIP_TYPE_M460HD},
{"M463SJHAE", 0x01B46310, NUC_CHIP_TYPE_M460HD},
{"M463H3SJHAN", 0x01B46B10, NUC_CHIP_TYPE_M460HD},
{"M463SIHAE", 0x01B46311, NUC_CHIP_TYPE_M460HD},
{"M467KJHAE", 0x01B46740, NUC_CHIP_TYPE_M460HD},
{"M463KJHAE", 0x01B46340, NUC_CHIP_TYPE_M460HD},
{"M463H3KJHAN", 0x01B46B40, NUC_CHIP_TYPE_M460HD},
{"M463KIHAE", 0x01B46341, NUC_CHIP_TYPE_M460HD},
{"M467JJHAE", 0x01B46750, NUC_CHIP_TYPE_M460HD},
{"M467HJHAE", 0x01B46760, NUC_CHIP_TYPE_M460HD},
{"M467H3JJHAN", 0x01B46B50, NUC_CHIP_TYPE_M460HD},
{"M467H3HJHAN", 0x01B46B61, NUC_CHIP_TYPE_M460HD},

{"M463KGCAE", 0x01C46340, NUC_CHIP_TYPE_M460LD},
{"M464KGCAE", 0x01C46440, NUC_CHIP_TYPE_M460LD},
{"M463VGCAE", 0x01C46330, NUC_CHIP_TYPE_M460LD},
{"M463SGCAE", 0x01C46310, NUC_CHIP_TYPE_M460LD},
{"M464SGCAE", 0x01C46410, NUC_CHIP_TYPE_M460LD},
{"M463AGCAE", 0x01C46380, NUC_CHIP_TYPE_M460LD},
{"M464AGCAE", 0x01C46480, NUC_CHIP_TYPE_M460LD},
{"M463LGCAE", 0x01C46300, NUC_CHIP_TYPE_M460LD},
{"M464LGCAE", 0x01C46400, NUC_CHIP_TYPE_M460LD},
{"M463YGCAE", 0x01C46390, NUC_CHIP_TYPE_M460LD},
{"M464YGCAE", 0x01C46490, NUC_CHIP_TYPE_M460LD},
{"M467SJHAE", 0x01B46710, NUC_CHIP_TYPE_M460},
{"M463SJHAE", 0x01B46310, NUC_CHIP_TYPE_M460},
{"M463H3SJHAN", 0x01B46B10, NUC_CHIP_TYPE_M460},
{"M463SIHAE", 0x01B46311, NUC_CHIP_TYPE_M460},
{"M467KJHAE", 0x01B46740, NUC_CHIP_TYPE_M460},
{"M463KJHAE", 0x01B46340, NUC_CHIP_TYPE_M460},
{"M463H3KJHAN", 0x01B46B40, NUC_CHIP_TYPE_M460},
{"M463KIHAE", 0x01B46341, NUC_CHIP_TYPE_M460},
{"M467JJHAE", 0x01B46750, NUC_CHIP_TYPE_M460},
{"M467HJHAE", 0x01B46760, NUC_CHIP_TYPE_M460},
{"M467H3JJHAN", 0x01B46B50, NUC_CHIP_TYPE_M460},
{"M467H3HJHAN", 0x01B46B61, NUC_CHIP_TYPE_M460},

{"M463KGCAE", 0x01C46340, NUC_CHIP_TYPE_M460},
{"M464KGCAE", 0x01C46440, NUC_CHIP_TYPE_M460},
{"M463VGCAE", 0x01C46330, NUC_CHIP_TYPE_M460},
{"M463SGCAE", 0x01C46310, NUC_CHIP_TYPE_M460},
{"M464SGCAE", 0x01C46410, NUC_CHIP_TYPE_M460},
{"M463AGCAE", 0x01C46380, NUC_CHIP_TYPE_M460},
{"M464AGCAE", 0x01C46480, NUC_CHIP_TYPE_M460},
{"M463LGCAE", 0x01C46300, NUC_CHIP_TYPE_M460},
{"M464LGCAE", 0x01C46400, NUC_CHIP_TYPE_M460},
{"M463YGCAE", 0x01C46390, NUC_CHIP_TYPE_M460},
{"M464YGCAE", 0x01C46490, NUC_CHIP_TYPE_M460},

/* M471 */
{"M471KI8AE", 0x01647140, NUC_CHIP_TYPE_M471},
Expand Down Expand Up @@ -891,8 +893,16 @@ struct CPartNumID g_PartNumIDs[] = {
{"ML51LD1AE", 0x00105744, NUC_CHIP_TYPE_GENERAL_1T},
{"ML51TD1AE", 0x0C105744, NUC_CHIP_TYPE_GENERAL_1T},

{"MUG51TB9AE", 0x0C106321, NUC_CHIP_TYPE_GENERAL_1T},
{"MUG51W", 0xFFFF6321, NUC_CHIP_TYPE_GENERAL_1T},
/* KAG056 */
{"MG51XB9AE", 0x05006721, NUC_CHIP_TYPE_GENERAL_1T},
{"MG51XB9BE", 0x0E006721, NUC_CHIP_TYPE_GENERAL_1T},
{"MG51FB9AE", 0x0B006721, NUC_CHIP_TYPE_GENERAL_1T},
{"MG51XC9AE", 0x05006731, NUC_CHIP_TYPE_GENERAL_1T},
{"MG51XC9BE", 0x0E006731, NUC_CHIP_TYPE_GENERAL_1T},
{"MG51FC9AE", 0x0B006731, NUC_CHIP_TYPE_GENERAL_1T},
{"N76S003AQ20", 0x05006750, NUC_CHIP_TYPE_GENERAL_1T},
{"N76S003BQ20", 0x0E006750, NUC_CHIP_TYPE_GENERAL_1T},
{"N76S003AT20", 0x0B006750, NUC_CHIP_TYPE_GENERAL_1T},
{"---------", 0xFFFFFFFF, 0},
};

128 changes: 0 additions & 128 deletions NuvoISP/DialogChipSetting/DialogChipSetting_CFG_M460.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ CDialogChipSetting_CFG_M460::CDialogChipSetting_CFG_M460(CWnd *pParent /*=NULL*/
m_nRadioCBOV = -1;
m_nRadioCIOINI = -1;
m_nRadioCBS = -1;
m_nRadioSPIMPSL = -1;
m_nRadioUART1PSL = -1;
m_bCheckCBORST = FALSE;
m_bCheckCBODEN = FALSE;
m_bCheckICELOCK = FALSE;
Expand Down Expand Up @@ -51,8 +49,6 @@ void CDialogChipSetting_CFG_M460::DoDataExchange(CDataExchange *pDX)
DDX_Radio(pDX, IDC_RADIO_BOV_7, m_nRadioCBOV);
DDX_Radio(pDX, IDC_RADIO_IO_TRI, m_nRadioCIOINI);
DDX_Radio(pDX, IDC_RADIO_BS_APROM_LDROM, m_nRadioCBS);
DDX_Radio(pDX, IDC_RADIO_SPIM_SEL3, m_nRadioSPIMPSL);
DDX_Radio(pDX, IDC_RADIO_UART1_SEL3, m_nRadioUART1PSL);
DDX_Check(pDX, IDC_CHECK_BROWN_OUT_RESET, m_bCheckCBORST);
DDX_Check(pDX, IDC_CHECK_BROWN_OUT_DETECT, m_bCheckCBODEN);
DDX_Check(pDX, IDC_CHECK_ICE_LOCK, m_bCheckICELOCK);
Expand Down Expand Up @@ -96,14 +92,6 @@ BEGIN_MESSAGE_MAP(CDialogChipSetting_CFG_M460, CDialog)
ON_BN_CLICKED(IDC_RADIO_IO_BI, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_BS_APROM_LDROM, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_BS_LDROM_APROM, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_SPIM_SEL3, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_SPIM_SEL2, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_SPIM_SEL1, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_SPIM_SEL0, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_UART1_SEL3, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_UART1_SEL2, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_UART1_SEL1, OnRadioClick)
ON_BN_CLICKED(IDC_RADIO_UART1_SEL0, OnRadioClick)

ON_BN_CLICKED(IDC_CHECK_BROWN_OUT_RESET, OnCheckClick)
ON_BN_CLICKED(IDC_CHECK_BROWN_OUT_DETECT, OnCheckClick)
Expand Down Expand Up @@ -135,7 +123,6 @@ BOOL CDialogChipSetting_CFG_M460::OnInitDialog()
//GetChipInfo_NuMicro(m_uPID, m_uDID, 0xFFFFFFFF, 0xFFFFFFFF, false, &chipInfo);
//m_uProgramMemorySize = chipInfo.uProgramMemorySize;
//m_uFlashPageSize = (1 << chipInfo.uFlash_PageSize);
//m_bSupportSPIM = (chipInfo.uSPIM_Size > 0) ? true : false;
UpdateUI();
UDACCEL pAccel[1];
pAccel[0].nInc = 1;
Expand All @@ -152,31 +139,6 @@ BOOL CDialogChipSetting_CFG_M460::OnInitDialog()
void CDialogChipSetting_CFG_M460::UpdateUI()
{
// TODO: Add your control notification handler code here
if (!m_bSupportSPIM) {
GetDlgItem(IDC_GROUP_SPIM_SELECT)->ShowWindow(SW_HIDE);
GetDlgItem(IDC_RADIO_SPIM_SEL3)->ShowWindow(SW_HIDE);
GetDlgItem(IDC_RADIO_SPIM_SEL2)->ShowWindow(SW_HIDE);
GetDlgItem(IDC_RADIO_SPIM_SEL1)->ShowWindow(SW_HIDE);
GetDlgItem(IDC_RADIO_SPIM_SEL0)->ShowWindow(SW_HIDE);
RECT rcTmp, rcGroupSPIMPSL, rcGroupUART1PSL;
LONG lDiff;
GetDlgItem(IDC_GROUP_SPIM_SELECT)->GetWindowRect(&rcGroupSPIMPSL);
GetDlgItem(IDC_GROUP_UART1_SELECT)->GetWindowRect(&rcGroupUART1PSL);
lDiff = rcGroupSPIMPSL.bottom - rcGroupUART1PSL.bottom;
int i;
int nID0s[] = { IDC_GROUP_ISP_MODE, IDC_CHECK_ISP_MODE_UART, IDC_CHECK_ISP_MODE_USB, IDC_CHECK_ISP_MODE_CAN, IDC_CHECK_ISP_MODE_I2C, IDC_CHECK_ISP_MODE_SPI,
IDC_GROUP_CONFIG_VALUE, IDC_STATIC_CONFIG_0, IDC_STATIC_CONFIG_VALUE_0, IDC_STATIC_CONFIG_1, IDC_STATIC_CONFIG_VALUE_1, IDC_STATIC_CONFIG_2, IDC_STATIC_CONFIG_VALUE_2, IDC_STATIC_CONFIG_3, IDC_STATIC_CONFIG_VALUE_3
};

for (i = 0; i < _countof(nID0s); i++) {
GetDlgItem(nID0s[i])->GetWindowRect(&rcTmp);
this->ScreenToClient(&rcTmp);
GetDlgItem(nID0s[i])->SetWindowPos(NULL, rcTmp.left, rcTmp.top - lDiff, 0, 0, SWP_NOZORDER | SWP_NOSIZE);
}

this->GetWindowRect(&rcTmp);
SetWindowPos(this, 0, 0, rcTmp.right - rcTmp.left, rcTmp.bottom - rcTmp.top - lDiff, SWP_NOZORDER | SWP_NOMOVE);
}
}

void CDialogChipSetting_CFG_M460::ConfigToGUI()
Expand All @@ -197,45 +159,6 @@ void CDialogChipSetting_CFG_M460::ConfigToGUI()
m_bCheckISP_CAN = ((m_uConfigValue_t[3] & M460_FLASH_CONFIG_CANISPEN) != 0 ? TRUE : FALSE);
m_bCheckISP_I2C = ((m_uConfigValue_t[3] & M460_FLASH_CONFIG_I2CISPEN) != 0 ? TRUE : FALSE);
m_bCheckISP_SPI = ((m_uConfigValue_t[3] & M460_FLASH_CONFIG_SPIISPEN) != 0 ? TRUE : FALSE);

/* SPIM multi-function pin selection */
switch (m_uConfigValue_t[3] & M460_FLASH_CONFIG_SPIMPSL) {
case M460_FLASH_CONFIG_SPIMPSL_SEL0:
m_nRadioSPIMPSL = 3;
break;

case M460_FLASH_CONFIG_SPIMPSL_SEL1:
m_nRadioSPIMPSL = 2;
break;

case M460_FLASH_CONFIG_SPIMPSL_SEL2:
m_nRadioSPIMPSL = 1;
break;

case M460_FLASH_CONFIG_SPIMPSL_SEL3:
m_nRadioSPIMPSL = 0;
break;
}

/* UART1 multi-function pin selection */
switch (m_uConfigValue_t[3] & M460_FLASH_CONFIG_UART1PSL) {
case M460_FLASH_CONFIG_UART1PSL_SEL0:
m_nRadioUART1PSL = 3;
break;

case M460_FLASH_CONFIG_UART1PSL_SEL1:
m_nRadioUART1PSL = 2;
break;

case M460_FLASH_CONFIG_UART1PSL_SEL2:
m_nRadioUART1PSL = 1;
break;

case M460_FLASH_CONFIG_UART1PSL_SEL3:
m_nRadioUART1PSL = 0;
break;
}

m_sConfigValue0.Format(_T("0x%08X"), m_uConfigValue_t[0]);
m_sConfigValue1.Format(_T("0x%08X"), m_uConfigValue_t[1]);
m_sConfigValue2.Format(_T("0x%08X"), m_uConfigValue_t[2]);
Expand Down Expand Up @@ -288,57 +211,6 @@ void CDialogChipSetting_CFG_M460::GUIToConfig()
m_uConfigValue_t[3] &= ~M460_FLASH_CONFIG_SPIISPEN;
}

if (m_bSupportSPIM) {
m_uConfigValue_t[3] &= ~M460_FLASH_CONFIG_SPIMPSL;

switch (m_nRadioSPIMPSL) {
case 0:
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_SPIMPSL_SEL3;
break;

case 1:
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_SPIMPSL_SEL2;
break;

case 2:
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_SPIMPSL_SEL1;
break;

case 3:
default:
if (m_nRadioUART1PSL != 1) {
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_SPIMPSL_SEL0;
} else {
m_uConfigValue_t[3] |= (m_uConfigValue[3] & M460_FLASH_CONFIG_SPIMPSL);
}
}
}

m_uConfigValue_t[3] &= ~M460_FLASH_CONFIG_UART1PSL;

switch (m_nRadioUART1PSL) {
case 0:
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_UART1PSL_SEL3;
break;

case 1:
if (m_nRadioSPIMPSL != 3) {
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_UART1PSL_SEL2;
} else {
m_uConfigValue_t[3] |= (m_uConfigValue[3] & M460_FLASH_CONFIG_UART1PSL);
}

break;

case 2:
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_UART1PSL_SEL1;
break;

case 3:
default:
m_uConfigValue_t[3] |= M460_FLASH_CONFIG_UART1PSL_SEL0;
}

m_uConfigValue[0] = m_uConfigValue_t[0];
m_uConfigValue[1] = m_uConfigValue_t[1];
m_uConfigValue[2] = m_uConfigValue_t[2];
Expand Down
3 changes: 0 additions & 3 deletions NuvoISP/DialogChipSetting/DialogChipSetting_CFG_M460.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ class CDialogChipSetting_CFG_M460 : public CDialogResize
int m_nRadioCBOV;
int m_nRadioCIOINI;
int m_nRadioCBS;
int m_nRadioSPIMPSL;
int m_nRadioUART1PSL;

BOOL m_bCheckCBORST;
BOOL m_bCheckCBODEN;
Expand Down Expand Up @@ -70,7 +68,6 @@ class CDialogChipSetting_CFG_M460 : public CDialogResize

unsigned int m_uProgramMemorySize;
unsigned int m_uFlashPageSize;
bool m_bSupportSPIM;
protected:

// Generated message map functions
Expand Down
1 change: 0 additions & 1 deletion NuvoISP/DialogChipSetting/DialogChipSetting_M460.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ BOOL CDialogChipSetting_M460::OnInitDialog()
m_pChipSetting_CFG = new CDialogChipSetting_CFG_M460();
m_pChipSetting_CFG->m_uProgramMemorySize = m_uProgramMemorySize;
m_pChipSetting_CFG->m_uFlashPageSize = m_uFlashPageSize;
m_pChipSetting_CFG->m_bSupportSPIM = (m_uChipSeries == NUC_CHIP_TYPE_M460HD) ? true : false;
m_pChipSetting_CFG->m_uPID = m_uPID;
m_pChipSetting_CFG->m_uDID = m_uDID;
m_pChipSetting_CFG->m_uConfigValue[0] = m_uConfigValue[0];
Expand Down
Loading

0 comments on commit 4bbeba4

Please sign in to comment.