mirror of https://github.com/rusefi/openblt.git
Refs #593. Merged branch with support for high ping firmware updates via TCP/IP back into the trunk.
git-svn-id: https://svn.code.sf.net/p/openblt/code/trunk@579 5dc33758-31d5-4daf-9ae8-b24bf3d40d73
This commit is contained in:
parent
d407f9b365
commit
8904af6a8b
|
@ -38,7 +38,7 @@ PROJECT_NAME = "BootCommander - Reference Manual"
|
|||
# could be handy for archiving the generated documentation or if some version
|
||||
# control system is used.
|
||||
|
||||
PROJECT_NUMBER = 1.4.0
|
||||
PROJECT_NUMBER = 1.4.1
|
||||
|
||||
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
||||
# for a project that appears at the top of each page and should give viewer a
|
||||
|
|
|
@ -38,7 +38,7 @@ PROJECT_NAME = "OpenBLT Host Library - Reference Manual"
|
|||
# could be handy for archiving the generated documentation or if some version
|
||||
# control system is used.
|
||||
|
||||
PROJECT_NUMBER = 1.3.1
|
||||
PROJECT_NUMBER = 1.3.2
|
||||
|
||||
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
||||
# for a project that appears at the top of each page and should give viewer a
|
||||
|
|
|
@ -268,7 +268,8 @@ int main(int argc, char const * const argv[])
|
|||
{
|
||||
printf("[" OUTPUT_YELLOW "TIMEOUT" OUTPUT_RESET "]\n");
|
||||
/* No response. Prompt the user to reset the system. */
|
||||
printf("Reset target system..."); (void)fflush(stdout);
|
||||
printf("Attempting backdoor entry (reset system if this takes too long)...");
|
||||
(void)fflush(stdout);
|
||||
/* Now keep trying until we get a response. */
|
||||
while (BltSessionStart() != BLT_RESULT_OK)
|
||||
{
|
||||
|
@ -471,8 +472,8 @@ int main(int argc, char const * const argv[])
|
|||
static void DisplayProgramInfo(void)
|
||||
{
|
||||
printf("--------------------------------------------------------------------------\n");
|
||||
printf("BootCommander version 1.04. Performs firmware updates on a microcontroller\n");
|
||||
printf("based system that runs the OpenBLT bootloader.\n\n");
|
||||
printf("BootCommander version 1.04.01. Performs firmware updates on a micro-\n");
|
||||
printf("controller based system that runs the OpenBLT bootloader.\n\n");
|
||||
printf("Copyright (c) 2017 by Feaser http://www.feaser.com\n");
|
||||
printf("-------------------------------------------------------------------------\n");
|
||||
} /*** end of DisplayProgramInfo ***/
|
||||
|
@ -507,6 +508,8 @@ static void DisplayProgramUsage(void)
|
|||
printf(" value (Default = 10000 ms).\n");
|
||||
printf(" -t5=[timeout] Program memory and target reset timeout in milli-\n");
|
||||
printf(" seconds as a 16-bit value (Default = 1000 ms).\n");
|
||||
printf(" -t6=[timeout] Connect response timeout in milliseconds as a 16-bit\n");
|
||||
printf(" value (Default = 50 ms).\n");
|
||||
printf(" -t7=[timeout] Busy wait timer timeout in milliseconds as a 16-bit\n");
|
||||
printf(" value (Default = 2000 ms).\n");
|
||||
printf(" -sk=[file] Seed/key algorithm library filename (Optional).\n");
|
||||
|
@ -607,6 +610,7 @@ static void DisplaySessionInfo(uint32_t sessionType, void const * sessionSetting
|
|||
printf(" -> Timeout T3: %hu ms\n", xcpSettings->timeoutT3);
|
||||
printf(" -> Timeout T4: %hu ms\n", xcpSettings->timeoutT4);
|
||||
printf(" -> Timeout T5: %hu ms\n", xcpSettings->timeoutT5);
|
||||
printf(" -> Timeout T6: %hu ms\n", xcpSettings->timeoutT6);
|
||||
printf(" -> Timeout T7: %hu ms\n", xcpSettings->timeoutT7);
|
||||
printf(" -> Seed/Key file: ");
|
||||
if (xcpSettings->seedKeyFile != NULL)
|
||||
|
@ -925,6 +929,7 @@ static void * ExtractSessionSettingsFromCommandLine(int argc, char const * const
|
|||
* -t3=[timeout] -> Start programming timeout in milliseconds.
|
||||
* -t4=[timeout] -> Erase memory timeout in milliseconds.
|
||||
* -t5=[timeout] -> Program memory and reset timeout in milliseconds.
|
||||
* -t6=[timeout] -> Connect response timeout in milliseconds.
|
||||
* -t7=[timeout] -> Busy wait timer timeout in milliseconds.
|
||||
* -sk=[file] -> Seed/key algorithm library filename.
|
||||
* -cm=[value] -> Connection mode parameter in XCP connect command.
|
||||
|
@ -941,6 +946,7 @@ static void * ExtractSessionSettingsFromCommandLine(int argc, char const * const
|
|||
xcpSettings->timeoutT3 = 2000;
|
||||
xcpSettings->timeoutT4 = 10000;
|
||||
xcpSettings->timeoutT5 = 1000;
|
||||
xcpSettings->timeoutT6 = 50;
|
||||
xcpSettings->timeoutT7 = 2000;
|
||||
xcpSettings->seedKeyFile = NULL;
|
||||
xcpSettings->connectMode = 0;
|
||||
|
@ -985,6 +991,15 @@ static void * ExtractSessionSettingsFromCommandLine(int argc, char const * const
|
|||
/* Continue with next loop iteration. */
|
||||
continue;
|
||||
}
|
||||
/* Is this the -t6=[timeout] parameter? */
|
||||
if ( (strstr(argv[paramIdx], "-t6=") != NULL) &&
|
||||
(strlen(argv[paramIdx]) > 4) )
|
||||
{
|
||||
/* Extract the timeout value. */
|
||||
sscanf(&argv[paramIdx][4], "%hu", &(xcpSettings->timeoutT6));
|
||||
/* Continue with next loop iteration. */
|
||||
continue;
|
||||
}
|
||||
/* Is this the -t7=[timeout] parameter? */
|
||||
if ( (strstr(argv[paramIdx], "-t7=") != NULL) &&
|
||||
(strlen(argv[paramIdx]) > 4) )
|
||||
|
|
|
@ -86,6 +86,7 @@ type
|
|||
timeoutT3: Word; // Start programming timeout in milliseconds.
|
||||
timeoutT4: Word; // Erase memory timeout in milliseonds.
|
||||
timeoutT5: Word; // Program memory and reset timeout in milliseonds.
|
||||
timeoutT6: Word; // Connect response timeout in milliseonds.
|
||||
timeoutT7: Word; // Busy wait timer timeout in milliseonds.
|
||||
seedKeyFile: PAnsiChar; // Seed/key algorithm library filename.
|
||||
connectMode: Byte; // Connection mode parameter in XCP connect command.
|
||||
|
|
|
@ -834,6 +834,7 @@ class BltSessionSettingsXcpV10:
|
|||
self.timeoutT3 = 2000 # Start programming timeout in milliseconds.
|
||||
self.timeoutT4 = 10000 # Erase memory timeout in milliseonds.
|
||||
self.timeoutT5 = 1000 # Program memory and reset timeout in milliseconds.
|
||||
self.timeoutT6 = 50 # Command response timeout in milliseconds.
|
||||
self.timeoutT7 = 2000 # Busy wait timer timeout in milliseconds.
|
||||
self.seedKeyFile = '' # Seed/key algorithm library filename.
|
||||
self.connectMode = 0 # Connection mode parameter in XCP connect command.
|
||||
|
@ -929,6 +930,7 @@ def session_init(session_type, session_settings, transport_type, transport_setti
|
|||
session_settings.timeoutT3 = 2000
|
||||
session_settings.timeoutT4 = 10000
|
||||
session_settings.timeoutT5 = 1000
|
||||
session_settings.timeoutT6 = 50
|
||||
session_settings.timeoutT7 = 2000
|
||||
session_settings.seedKeyFile = ''
|
||||
session_settings.connectMode = 0
|
||||
|
@ -947,6 +949,7 @@ def session_init(session_type, session_settings, transport_type, transport_setti
|
|||
('timeoutT3', ctypes.c_uint16),
|
||||
('timeoutT4', ctypes.c_uint16),
|
||||
('timeoutT5', ctypes.c_uint16),
|
||||
('timeoutT6', ctypes.c_uint16),
|
||||
('timeoutT7', ctypes.c_uint16),
|
||||
('seedKeyFile', ctypes.c_char_p),
|
||||
('connectMode', ctypes.c_uint8)]
|
||||
|
@ -984,6 +987,7 @@ def session_init(session_type, session_settings, transport_type, transport_setti
|
|||
session_settings_struct.timeoutT3 = ctypes.c_uint16(session_settings.timeoutT3)
|
||||
session_settings_struct.timeoutT4 = ctypes.c_uint16(session_settings.timeoutT4)
|
||||
session_settings_struct.timeoutT5 = ctypes.c_uint16(session_settings.timeoutT5)
|
||||
session_settings_struct.timeoutT6 = ctypes.c_uint16(session_settings.timeoutT6)
|
||||
session_settings_struct.timeoutT7 = ctypes.c_uint16(session_settings.timeoutT7)
|
||||
session_settings_struct.seedKeyFile = \
|
||||
ctypes.c_char_p(session_settings.seedKeyFile.encode('utf-8'))
|
||||
|
|
|
@ -51,10 +51,10 @@
|
|||
* for major-, minor-, and patch-version. Version 1.05.12 would for example be
|
||||
* 10512.
|
||||
*/
|
||||
#define BLT_VERSION_NUMBER (10301u)
|
||||
#define BLT_VERSION_NUMBER (10302u)
|
||||
|
||||
/** \brief The version number of the library as a null-terminated string. */
|
||||
#define BLT_VERSION_STRING "1.03.01"
|
||||
#define BLT_VERSION_STRING "1.03.02"
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
|
@ -140,6 +140,7 @@ LIBOPENBLT_EXPORT void BltSessionInit(uint32_t sessionType,
|
|||
xcpLoaderSettings.timeoutT3 = bltSessionSettingsXcpV10Ptr->timeoutT3;
|
||||
xcpLoaderSettings.timeoutT4 = bltSessionSettingsXcpV10Ptr->timeoutT4;
|
||||
xcpLoaderSettings.timeoutT5 = bltSessionSettingsXcpV10Ptr->timeoutT5;
|
||||
xcpLoaderSettings.timeoutT6 = bltSessionSettingsXcpV10Ptr->timeoutT6;
|
||||
xcpLoaderSettings.timeoutT7 = bltSessionSettingsXcpV10Ptr->timeoutT7;
|
||||
xcpLoaderSettings.seedKeyFile = bltSessionSettingsXcpV10Ptr->seedKeyFile;
|
||||
xcpLoaderSettings.connectMode = bltSessionSettingsXcpV10Ptr->connectMode;
|
||||
|
|
|
@ -124,6 +124,7 @@ typedef struct t_blt_session_settings_xcp_v10
|
|||
uint16_t timeoutT3; /**< Start programming timeout in milliseconds. */
|
||||
uint16_t timeoutT4; /**< Erase memory timeout in milliseconds. */
|
||||
uint16_t timeoutT5; /**< Program memory and reset timeout in milliseconds.*/
|
||||
uint16_t timeoutT6; /**< Connect response timeout in milliseconds. */
|
||||
uint16_t timeoutT7; /**< Busy wait timer timeout in milliseonds. */
|
||||
char const * seedKeyFile; /**< Seed/key algorithm library filename. */
|
||||
uint8_t connectMode; /**< Connection mode parameter in XCP connect command.*/
|
||||
|
|
|
@ -59,9 +59,6 @@
|
|||
/* XCP response packet IDs as defined by the protocol. */
|
||||
#define XCPLOADER_CMD_PID_RES (0xFFu) /**< positive response */
|
||||
|
||||
/** \brief Maximum timeout for the XCP connect command. */
|
||||
#define XCPLOADER_CONNECT_TIMEOUT_MS (50u)
|
||||
|
||||
/** \brief Number of retries to connect to the XCP slave. */
|
||||
#define XCPLOADER_CONNECT_RETRIES (5u)
|
||||
|
||||
|
@ -169,6 +166,7 @@ static void XcpLoaderInit(void const * settings)
|
|||
xcpSettings.timeoutT3 = 2000;
|
||||
xcpSettings.timeoutT4 = 10000;
|
||||
xcpSettings.timeoutT5 = 1000;
|
||||
xcpSettings.timeoutT6 = 50;
|
||||
xcpSettings.timeoutT7 = 2000;
|
||||
xcpSettings.connectMode = 0;
|
||||
xcpSettings.seedKeyFile = NULL;
|
||||
|
@ -244,6 +242,7 @@ static void XcpLoaderTerminate(void)
|
|||
xcpSettings.timeoutT3 = 2000;
|
||||
xcpSettings.timeoutT4 = 10000;
|
||||
xcpSettings.timeoutT5 = 1000;
|
||||
xcpSettings.timeoutT6 = 50;
|
||||
xcpSettings.timeoutT7 = 2000;
|
||||
xcpSettings.connectMode = 0;
|
||||
xcpSettings.seedKeyFile = NULL;
|
||||
|
@ -695,7 +694,7 @@ static bool XcpLoaderSendCmdConnect(void)
|
|||
cmdPacket.len = 2;
|
||||
/* Send the packet. */
|
||||
if (!xcpSettings.transport->SendPacket(&cmdPacket, &resPacket,
|
||||
XCPLOADER_CONNECT_TIMEOUT_MS))
|
||||
xcpSettings.timeoutT6))
|
||||
{
|
||||
/* Could not send packet or receive response within the specified timeout. */
|
||||
result = false;
|
||||
|
|
|
@ -90,6 +90,8 @@ typedef struct t_xcp_loader_settings
|
|||
uint16_t timeoutT4;
|
||||
/** \brief Program memory and reset timeout in milliseconds. */
|
||||
uint16_t timeoutT5;
|
||||
/** \brief Connect response timeout in milliseconds. */
|
||||
uint16_t timeoutT6;
|
||||
/** \brief Busy wait timer timeout in milliseconds. */
|
||||
uint16_t timeoutT7;
|
||||
/** \brief Connection mode used in the XCP connect command. */
|
||||
|
|
|
@ -19,8 +19,9 @@
|
|||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="MainUnit"/>
|
||||
<TopLine Value="291"/>
|
||||
<CursorPos X="11" Y="296"/>
|
||||
<IsVisibleTab Value="True"/>
|
||||
<TopLine Value="26"/>
|
||||
<CursorPos X="61" Y="37"/>
|
||||
<UsageCount Value="87"/>
|
||||
<Loaded Value="True"/>
|
||||
<LoadedDesigner Value="True"/>
|
||||
|
@ -31,7 +32,7 @@
|
|||
<UnitName Value="OpenBlt"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="53"/>
|
||||
<CursorPos Y="80"/>
|
||||
<CursorPos X="5" Y="85"/>
|
||||
<UsageCount Value="87"/>
|
||||
</Unit2>
|
||||
<Unit3>
|
||||
|
@ -39,18 +40,17 @@
|
|||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="CurrentConfig"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="17"/>
|
||||
<CursorPos Y="34"/>
|
||||
<TopLine Value="202"/>
|
||||
<CursorPos X="57" Y="251"/>
|
||||
<UsageCount Value="87"/>
|
||||
</Unit3>
|
||||
<Unit4>
|
||||
<Filename Value="configgroups.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="ConfigGroups"/>
|
||||
<IsVisibleTab Value="True"/>
|
||||
<EditorIndex Value="2"/>
|
||||
<TopLine Value="366"/>
|
||||
<CursorPos X="15" Y="224"/>
|
||||
<EditorIndex Value="1"/>
|
||||
<TopLine Value="470"/>
|
||||
<CursorPos X="37" Y="495"/>
|
||||
<UsageCount Value="84"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit4>
|
||||
|
@ -61,11 +61,10 @@
|
|||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="SettingsDialog"/>
|
||||
<EditorIndex Value="3"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="252"/>
|
||||
<CursorPos X="63" Y="258"/>
|
||||
<UsageCount Value="79"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit5>
|
||||
<Unit6>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
|
@ -74,10 +73,12 @@
|
|||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="SessionXcpDialog"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="114"/>
|
||||
<CursorPos X="43" Y="127"/>
|
||||
<EditorIndex Value="2"/>
|
||||
<TopLine Value="226"/>
|
||||
<CursorPos X="52" Y="230"/>
|
||||
<UsageCount Value="76"/>
|
||||
<Loaded Value="True"/>
|
||||
<LoadedDesigner Value="True"/>
|
||||
</Unit6>
|
||||
<Unit7>
|
||||
<Filename Value="customutil.pas"/>
|
||||
|
@ -152,12 +153,12 @@
|
|||
<Filename Value="firmwareupdate.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="FirmwareUpdate"/>
|
||||
<EditorIndex Value="1"/>
|
||||
<TopLine Value="481"/>
|
||||
<CursorPos X="84" Y="490"/>
|
||||
<EditorIndex Value="3"/>
|
||||
<TopLine Value="896"/>
|
||||
<CursorPos Y="930"/>
|
||||
<UsageCount Value="49"/>
|
||||
<Bookmarks Count="1">
|
||||
<Item0 X="23" Y="995" ID="1"/>
|
||||
<Item0 X="23" Y="998" ID="1"/>
|
||||
</Bookmarks>
|
||||
<Loaded Value="True"/>
|
||||
</Unit13>
|
||||
|
@ -174,11 +175,10 @@
|
|||
<Filename Value="filelogger.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="FileLogger"/>
|
||||
<EditorIndex Value="4"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="134"/>
|
||||
<CursorPos X="19" Y="140"/>
|
||||
<UsageCount Value="24"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit15>
|
||||
<Unit16>
|
||||
<Filename Value="/usr/share/fpcsrc/3.0.0/rtl/objpas/sysutils/osutilsh.inc"/>
|
||||
|
@ -296,126 +296,119 @@
|
|||
<OtherDefines Count="1">
|
||||
<Define0 Value="UseCThreads"/>
|
||||
</OtherDefines>
|
||||
<JumpHistory Count="30" HistoryIndex="29">
|
||||
<JumpHistory Count="28" HistoryIndex="27">
|
||||
<Position1>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="487" Column="39" TopLine="446"/>
|
||||
<Caret Line="106" Column="41" TopLine="70"/>
|
||||
</Position1>
|
||||
<Position2>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="497" Column="23" TopLine="456"/>
|
||||
<Caret Line="604" Column="50" TopLine="569"/>
|
||||
</Position2>
|
||||
<Position3>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="498" Column="41" TopLine="457"/>
|
||||
<Caret Line="694" Column="50" TopLine="659"/>
|
||||
</Position3>
|
||||
<Position4>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="509" Column="45" TopLine="468"/>
|
||||
<Caret Line="708" Column="50" TopLine="690"/>
|
||||
</Position4>
|
||||
<Position5>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="559" Column="45" TopLine="518"/>
|
||||
<Caret Line="488" Column="32" TopLine="481"/>
|
||||
</Position5>
|
||||
<Position6>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="578" Column="43" TopLine="537"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="127" Column="43" TopLine="114"/>
|
||||
</Position6>
|
||||
<Position7>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="588" Column="45" TopLine="547"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="132" Column="43" TopLine="119"/>
|
||||
</Position7>
|
||||
<Position8>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="648" Column="45" TopLine="607"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="104" Column="3" TopLine="92"/>
|
||||
</Position8>
|
||||
<Position9>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="667" Column="43" TopLine="626"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="20" Column="35"/>
|
||||
</Position9>
|
||||
<Position10>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="677" Column="45" TopLine="636"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="60" Column="17" TopLine="18"/>
|
||||
</Position10>
|
||||
<Position11>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="716" Column="39" TopLine="675"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="71" Column="17" TopLine="29"/>
|
||||
</Position11>
|
||||
<Position12>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="724" Column="39" TopLine="683"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="219" Column="50" TopLine="176"/>
|
||||
</Position12>
|
||||
<Position13>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="744" Column="37" TopLine="703"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="230" Column="60" TopLine="187"/>
|
||||
</Position13>
|
||||
<Position14>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="1129" Column="39" TopLine="1087"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="259" Column="57" TopLine="214"/>
|
||||
</Position14>
|
||||
<Position15>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="1138" Column="52" TopLine="1096"/>
|
||||
<Filename Value="configgroups.pas"/>
|
||||
<Caret Line="94" Column="6" TopLine="69"/>
|
||||
</Position15>
|
||||
<Position16>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="1126" Column="64" TopLine="1104"/>
|
||||
<Filename Value="configgroups.pas"/>
|
||||
<Caret Line="108" Column="14" TopLine="69"/>
|
||||
</Position16>
|
||||
<Position17>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Filename Value="configgroups.pas"/>
|
||||
<Caret Line="449" Column="13" TopLine="420"/>
|
||||
</Position17>
|
||||
<Position18>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="98" Column="43" TopLine="93"/>
|
||||
<Filename Value="configgroups.pas"/>
|
||||
<Caret Line="469" Column="4" TopLine="427"/>
|
||||
</Position18>
|
||||
<Position19>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="745" TopLine="719"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="215" Column="30" TopLine="185"/>
|
||||
</Position19>
|
||||
<Position20>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="98" Column="72" TopLine="68"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="57" Column="8" TopLine="32"/>
|
||||
</Position20>
|
||||
<Position21>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="947" TopLine="938"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="66" Column="8" TopLine="32"/>
|
||||
</Position21>
|
||||
<Position22>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="1053" Column="19" TopLine="1018"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="215" Column="21" TopLine="190"/>
|
||||
</Position22>
|
||||
<Position23>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="1038" Column="17" TopLine="1032"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="226" Column="6" TopLine="190"/>
|
||||
</Position23>
|
||||
<Position24>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="600" Column="63" TopLine="579"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="250" Column="9" TopLine="225"/>
|
||||
</Position24>
|
||||
<Position25>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="68" TopLine="42"/>
|
||||
<Filename Value="sessionxcpdialog.pas"/>
|
||||
<Caret Line="251" Column="23" TopLine="225"/>
|
||||
</Position25>
|
||||
<Position26>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="106" Column="41" TopLine="70"/>
|
||||
<Caret Line="490" Column="84" TopLine="481"/>
|
||||
</Position26>
|
||||
<Position27>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="604" Column="50" TopLine="569"/>
|
||||
<Caret Line="791" Column="63" TopLine="762"/>
|
||||
</Position27>
|
||||
<Position28>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="694" Column="50" TopLine="659"/>
|
||||
<Filename Value="mainunit.pas"/>
|
||||
<Caret Line="294" Column="14" TopLine="291"/>
|
||||
</Position28>
|
||||
<Position29>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="708" Column="50" TopLine="690"/>
|
||||
</Position29>
|
||||
<Position30>
|
||||
<Filename Value="firmwareupdate.pas"/>
|
||||
<Caret Line="488" Column="32" TopLine="481"/>
|
||||
</Position30>
|
||||
</JumpHistory>
|
||||
</ProjectSession>
|
||||
</CONFIG>
|
||||
|
|
|
@ -95,6 +95,7 @@ type
|
|||
FTimeoutT3: Integer;
|
||||
FTimeoutT4: Integer;
|
||||
FTimeoutT5: Integer;
|
||||
FTimeoutT6: Integer;
|
||||
FTimeoutT7: Integer;
|
||||
FConnectMode: Integer;
|
||||
FSeedKey: String;
|
||||
|
@ -108,6 +109,7 @@ type
|
|||
property TimeoutT3: Integer read FTimeoutT3 write FTimeoutT3;
|
||||
property TimeoutT4: Integer read FTimeoutT4 write FTimeoutT4;
|
||||
property TimeoutT5: Integer read FTimeoutT5 write FTimeoutT5;
|
||||
property TimeoutT6: Integer read FTimeoutT6 write FTimeoutT6;
|
||||
property TimeoutT7: Integer read FTimeoutT7 write FTimeoutT7;
|
||||
property ConnectMode: Integer read FConnectMode write FConnectMode;
|
||||
property SeedKey: String read FSeedKey write FSeedKey;
|
||||
|
@ -444,6 +446,7 @@ begin
|
|||
FTimeoutT3 := 2000;
|
||||
FTimeoutT4 := 10000;
|
||||
FTimeoutT5 := 1000;
|
||||
FTimeoutT6 := 50;
|
||||
FTimeoutT7 := 2000;
|
||||
FConnectMode := 0;
|
||||
FSeedKey := '';
|
||||
|
@ -467,6 +470,7 @@ begin
|
|||
FTimeoutT3 := XmlConfig.GetValue('timeout_t3', FTimeoutT3);
|
||||
FTimeoutT4 := XmlConfig.GetValue('timeout_t4', FTimeoutT4);
|
||||
FTimeoutT5 := XmlConfig.GetValue('timeout_t5', FTimeoutT5);
|
||||
FTimeoutT6 := XmlConfig.GetValue('timeout_t6', FTimeoutT6);
|
||||
FTimeoutT7 := XmlConfig.GetValue('timeout_t7', FTimeoutT7);
|
||||
FConnectMode := XmlConfig.GetValue('connect_mode', FConnectMode);
|
||||
FSeedKey := String(XmlConfig.GetValue('seed_key', UnicodeString(FSeedKey)));
|
||||
|
@ -492,6 +496,7 @@ begin
|
|||
XmlConfig.SetValue('timeout_t3', FTimeoutT3);
|
||||
XmlConfig.SetValue('timeout_t4', FTimeoutT4);
|
||||
XmlConfig.SetValue('timeout_t5', FTimeoutT5);
|
||||
XmlConfig.SetValue('timeout_t6', FTimeoutT6);
|
||||
XmlConfig.SetValue('timeout_t7', FTimeoutT7);
|
||||
XmlConfig.SetValue('connect_mode', FConnectMode);
|
||||
XmlConfig.SetValue('seed_key', UnicodeString(FSeedKey));
|
||||
|
|
|
@ -788,6 +788,7 @@ begin
|
|||
sessionSettingsXcp.timeoutT3 := sessionXcpConfig.TimeoutT3;
|
||||
sessionSettingsXcp.timeoutT4 := sessionXcpConfig.TimeoutT4;
|
||||
sessionSettingsXcp.timeoutT5 := sessionXcpConfig.TimeoutT5;
|
||||
sessionSettingsXcp.timeoutT6 := sessionXcpConfig.TimeoutT6;
|
||||
sessionSettingsXcp.timeoutT7 := sessionXcpConfig.TimeoutT7;
|
||||
sessionSettingsXcp.connectMode := sessionXcpConfig.ConnectMode;
|
||||
sessionSettingsXcp.seedKeyFile := PAnsiChar(AnsiString(sessionXcpConfig.SeedKey));
|
||||
|
@ -926,6 +927,8 @@ begin
|
|||
Synchronize(@SynchronizeLogEvent);
|
||||
FLogString := ' -> Timeout T5: ' + IntToStr(sessionXcpConfig.TimeoutT5) + ' ms';
|
||||
Synchronize(@SynchronizeLogEvent);
|
||||
FLogString := ' -> Timeout T6: ' + IntToStr(sessionXcpConfig.TimeoutT6) + ' ms';
|
||||
Synchronize(@SynchronizeLogEvent);
|
||||
FLogString := ' -> Timeout T7: ' + IntToStr(sessionXcpConfig.TimeoutT7) + ' ms';
|
||||
Synchronize(@SynchronizeLogEvent);
|
||||
if sessionXcpConfig.SeedKey <> '' then
|
||||
|
|
|
@ -48,7 +48,7 @@ uses
|
|||
//***************************************************************************************
|
||||
const
|
||||
PROGRAM_NAME_STR = 'MicroBoot';
|
||||
PROGRAM_VERSION_STR = 'v2.00';
|
||||
PROGRAM_VERSION_STR = 'v2.01';
|
||||
|
||||
|
||||
//***************************************************************************************
|
||||
|
|
|
@ -1,19 +1,19 @@
|
|||
object SessionXcpForm: TSessionXcpForm
|
||||
Left = 1306
|
||||
Left = 582
|
||||
Height = 308
|
||||
Top = 661
|
||||
Top = 371
|
||||
Width = 407
|
||||
Caption = 'XCP Session'
|
||||
ClientHeight = 308
|
||||
ClientWidth = 407
|
||||
OnCreate = FormCreate
|
||||
OnDestroy = FormDestroy
|
||||
LCLVersion = '1.6.2.0'
|
||||
LCLVersion = '1.8.2.0'
|
||||
object LblTimeouts: TLabel
|
||||
Left = 8
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 160
|
||||
Width = 56
|
||||
Width = 59
|
||||
Caption = 'Timeouts'
|
||||
Font.Style = [fsBold]
|
||||
ParentColor = False
|
||||
|
@ -21,15 +21,15 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblTimeoutT1: TLabel
|
||||
Left = 23
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 187
|
||||
Width = 45
|
||||
Width = 47
|
||||
Caption = 'T1 (ms):'
|
||||
ParentColor = False
|
||||
end
|
||||
object EdtTimeoutT1: TEdit
|
||||
Left = 80
|
||||
Height = 29
|
||||
Height = 28
|
||||
Hint = 'Command response timeout in milliseconds as a 16-bit value (Default = 1000 ms)'
|
||||
Top = 184
|
||||
Width = 115
|
||||
|
@ -41,15 +41,15 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblTimeoutT3: TLabel
|
||||
Left = 23
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 227
|
||||
Width = 45
|
||||
Width = 47
|
||||
Caption = 'T3 (ms):'
|
||||
ParentColor = False
|
||||
end
|
||||
object EdtTimeoutT3: TEdit
|
||||
Left = 80
|
||||
Height = 29
|
||||
Height = 28
|
||||
Hint = 'Start programming timeout in milliseconds as a 16-bit value (Default = 2000 ms)'
|
||||
Top = 224
|
||||
Width = 115
|
||||
|
@ -61,15 +61,15 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblTimeoutT4: TLabel
|
||||
Left = 23
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 267
|
||||
Width = 45
|
||||
Width = 47
|
||||
Caption = 'T4 (ms):'
|
||||
ParentColor = False
|
||||
end
|
||||
object EdtTimeoutT4: TEdit
|
||||
Left = 80
|
||||
Height = 29
|
||||
Height = 28
|
||||
Hint = 'Erase memory timeout in milliseconds as a 16-bit value (Default = 10000 ms)'
|
||||
Top = 264
|
||||
Width = 115
|
||||
|
@ -81,15 +81,15 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblTimeoutT5: TLabel
|
||||
Left = 226
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 187
|
||||
Width = 45
|
||||
Width = 47
|
||||
Caption = 'T5 (ms):'
|
||||
ParentColor = False
|
||||
end
|
||||
object EdtTimeoutT5: TEdit
|
||||
Left = 280
|
||||
Height = 29
|
||||
Height = 28
|
||||
Hint = 'Program memory and target reset timeout in milliseconds as a 16-bit value (Default = 1000 ms)'
|
||||
Top = 184
|
||||
Width = 115
|
||||
|
@ -101,17 +101,17 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblTimeoutT7: TLabel
|
||||
Left = 226
|
||||
Height = 17
|
||||
Top = 227
|
||||
Width = 45
|
||||
Height = 16
|
||||
Top = 267
|
||||
Width = 47
|
||||
Caption = 'T7 (ms):'
|
||||
ParentColor = False
|
||||
end
|
||||
object EdtTimeoutT7: TEdit
|
||||
Left = 280
|
||||
Height = 29
|
||||
Height = 28
|
||||
Hint = 'Busy wait timer timeout in milliseconds as a 16-bit value (Default = 2000 ms)'
|
||||
Top = 224
|
||||
Top = 264
|
||||
Width = 115
|
||||
OnChange = EdtTimeoutChange
|
||||
OnKeyPress = EdtTimeoutKeyPress
|
||||
|
@ -121,9 +121,9 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblConnection: TLabel
|
||||
Left = 8
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 8
|
||||
Width = 68
|
||||
Width = 74
|
||||
Caption = 'Connection'
|
||||
Font.Style = [fsBold]
|
||||
ParentColor = False
|
||||
|
@ -131,15 +131,15 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblConnectMode: TLabel
|
||||
Left = 23
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 38
|
||||
Width = 35
|
||||
Width = 38
|
||||
Caption = 'Mode:'
|
||||
ParentColor = False
|
||||
end
|
||||
object CmbConnectMode: TComboBox
|
||||
Left = 80
|
||||
Height = 27
|
||||
Height = 26
|
||||
Hint = 'Connection mode value sent in the XCP connect command as a 8-bit value (Default=0)'
|
||||
Top = 35
|
||||
Width = 120
|
||||
|
@ -411,9 +411,9 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblSecurity: TLabel
|
||||
Left = 8
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 72
|
||||
Width = 49
|
||||
Width = 54
|
||||
Caption = 'Security'
|
||||
Font.Style = [fsBold]
|
||||
ParentColor = False
|
||||
|
@ -421,15 +421,15 @@ object SessionXcpForm: TSessionXcpForm
|
|||
end
|
||||
object LblSeedKey: TLabel
|
||||
Left = 23
|
||||
Height = 17
|
||||
Height = 16
|
||||
Top = 96
|
||||
Width = 276
|
||||
Width = 298
|
||||
Caption = 'Select your seed/key algorithm shared library file:'
|
||||
ParentColor = False
|
||||
end
|
||||
object EdtSeedKey: TEdit
|
||||
Left = 23
|
||||
Height = 29
|
||||
Height = 28
|
||||
Hint = 'Seed/key algorithm shared library filename (Optional)'
|
||||
Top = 120
|
||||
Width = 281
|
||||
|
@ -446,6 +446,26 @@ object SessionXcpForm: TSessionXcpForm
|
|||
OnClick = BtnSeedKeyClick
|
||||
TabOrder = 2
|
||||
end
|
||||
object LblTimeoutT6: TLabel
|
||||
Left = 224
|
||||
Height = 16
|
||||
Top = 227
|
||||
Width = 47
|
||||
Caption = 'T6 (ms):'
|
||||
ParentColor = False
|
||||
end
|
||||
object EdtTimeoutT6: TEdit
|
||||
Left = 280
|
||||
Height = 28
|
||||
Hint = 'Connect response timeout in milliseconds as a 16-bit value (Default = 50 ms)'
|
||||
Top = 224
|
||||
Width = 115
|
||||
OnChange = EdtTimeoutChange
|
||||
OnKeyPress = EdtTimeoutKeyPress
|
||||
ParentShowHint = False
|
||||
ShowHint = True
|
||||
TabOrder = 8
|
||||
end
|
||||
object OpenDialog: TOpenDialog
|
||||
Filter = 'Shared libraries (*.dll;*.so)|*.dll;*.so|All files (*.*)|*.*'
|
||||
Options = [ofFileMustExist, ofEnableSizing, ofViewDetail]
|
||||
|
|
|
@ -47,6 +47,9 @@ uses
|
|||
//***************************************************************************************
|
||||
type
|
||||
//------------------------------ TSessionXcpForm ----------------------------------------
|
||||
|
||||
{ TSessionXcpForm }
|
||||
|
||||
TSessionXcpForm = class(TForm)
|
||||
BtnSeedKey: TButton;
|
||||
CmbConnectMode: TComboBox;
|
||||
|
@ -55,6 +58,7 @@ type
|
|||
EdtTimeoutT3: TEdit;
|
||||
EdtTimeoutT4: TEdit;
|
||||
EdtTimeoutT5: TEdit;
|
||||
EdtTimeoutT6: TEdit;
|
||||
EdtTimeoutT7: TEdit;
|
||||
LblConnection: TLabel;
|
||||
LblSeedKey: TLabel;
|
||||
|
@ -65,6 +69,7 @@ type
|
|||
LblTimeoutT3: TLabel;
|
||||
LblTimeoutT4: TLabel;
|
||||
LblTimeoutT5: TLabel;
|
||||
LblTimeoutT6: TLabel;
|
||||
LblTimeoutT7: TLabel;
|
||||
OpenDialog: TOpenDialog;
|
||||
procedure BtnSeedKeyClick(Sender: TObject);
|
||||
|
@ -211,6 +216,7 @@ begin
|
|||
FSessionXcpConfig.TimeoutT3 := Config.TimeoutT3;
|
||||
FSessionXcpConfig.TimeoutT4 := Config.TimeoutT4;
|
||||
FSessionXcpConfig.TimeoutT5 := Config.TimeoutT5;
|
||||
FSessionXcpConfig.TimeoutT6 := Config.TimeoutT6;
|
||||
FSessionXcpConfig.TimeoutT7 := Config.TimeoutT7;
|
||||
FSessionXcpConfig.ConnectMode := Config.ConnectMode;
|
||||
FSessionXcpConfig.SeedKey := Config.SeedKey;
|
||||
|
@ -221,6 +227,7 @@ begin
|
|||
EdtTimeoutT3.Text := IntToStr(FSessionXcpConfig.TimeoutT3);
|
||||
EdtTimeoutT4.Text := IntToStr(FSessionXcpConfig.TimeoutT4);
|
||||
EdtTimeoutT5.Text := IntToStr(FSessionXcpConfig.TimeoutT5);
|
||||
EdtTimeoutT6.Text := IntToStr(FSessionXcpConfig.TimeoutT6);
|
||||
EdtTimeoutT7.Text := IntToStr(FSessionXcpConfig.TimeoutT7);
|
||||
end; //*** end of LoadConfig ***
|
||||
|
||||
|
@ -248,6 +255,8 @@ begin
|
|||
FSessionXcpConfig.TimeoutT4 := StrToInt(EdtTimeoutT4.Text);
|
||||
if EdtTimeoutT5.Text <> '' then
|
||||
FSessionXcpConfig.TimeoutT5 := StrToInt(EdtTimeoutT5.Text);
|
||||
if EdtTimeoutT6.Text <> '' then
|
||||
FSessionXcpConfig.TimeoutT6 := StrToInt(EdtTimeoutT6.Text);
|
||||
if EdtTimeoutT7.Text <> '' then
|
||||
FSessionXcpConfig.TimeoutT7 := StrToInt(EdtTimeoutT7.Text);
|
||||
// Store configuration.
|
||||
|
@ -255,6 +264,7 @@ begin
|
|||
Config.TimeoutT3 := FSessionXcpConfig.TimeoutT3;
|
||||
Config.TimeoutT4 := FSessionXcpConfig.TimeoutT4;
|
||||
Config.TimeoutT5 := FSessionXcpConfig.TimeoutT5;
|
||||
Config.TimeoutT6 := FSessionXcpConfig.TimeoutT6;
|
||||
Config.TimeoutT7 := FSessionXcpConfig.TimeoutT7;
|
||||
Config.ConnectMode := FSessionXcpConfig.ConnectMode;
|
||||
Config.SeedKey := FSessionXcpConfig.SeedKey;
|
||||
|
|
Loading…
Reference in New Issue