From d723bb19742e1522c5859fba5ea5a75b5e902ac1 Mon Sep 17 00:00:00 2001 From: Shlomo Hecht Date: Tue, 5 Feb 2019 14:50:38 +0200 Subject: IDS bug fix (microstepping) #217 solved --- Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c') diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c index a12c02867..ceb341c38 100644 --- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c +++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c @@ -49,9 +49,9 @@ FIL *DownloadFileHandle = 0; //the system supports a single active file char FileHandleChar[5]; char ErrorMsg[100]; #define MAX_CHUNK_LENGTH 2000 -int FileLength = 0; -int FileReceivedLength = 0; -int FileSentLength = 0; +uint32_t FileLength = 0; +uint32_t FileReceivedLength = 0; +uint32_t FileSentLength = 0; static char g_cCwdBuf[50] = "/"; uint32_t WrittenBytes = 0; uint32_t ReadBytes = 0; -- cgit v1.3.1 From a73a6f639445640123705f3e68e6a7ecd654ef41 Mon Sep 17 00:00:00 2001 From: Shlomo Hecht Date: Wed, 6 Feb 2019 11:30:20 +0200 Subject: flash programming improved, working --- Software/Embedded_SW/Embedded/.cproject | 2 +- .../Embedded/Common/SWUpdate/FileSystem.c | 5 +- .../Embedded/Common/SWUpdate/FirmwareUpgrade.c | 16 ++--- .../Drivers/FPGA/Full_Vme/FPGA_Programming_Up.c | 72 ++++++++++++++++++---- .../Drivers/FPGA/Full_Vme/FPGA_Programming_Up.h | 4 +- .../Drivers/I2C_Communication/DAC/Blower.c | 2 +- .../Embedded/Drivers/USB_Communication/USBCDCD.c | 7 +++ Software/Embedded_SW/Embedded/Embedded.cfg | 6 ++ Software/Embedded_SW/Embedded/Main.c | 6 +- Software/Embedded_SW/Embedded/tm4c129xnczad.cmd | 2 +- 10 files changed, 91 insertions(+), 31 deletions(-) (limited to 'Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c') diff --git a/Software/Embedded_SW/Embedded/.cproject b/Software/Embedded_SW/Embedded/.cproject index 38422568f..89dc72b30 100644 --- a/Software/Embedded_SW/Embedded/.cproject +++ b/Software/Embedded_SW/Embedded/.cproject @@ -169,7 +169,7 @@ - + diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c index 11fbf86c4..d39c335ef 100644 --- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c +++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c @@ -509,9 +509,9 @@ uint32_t GetStorageInfoRequestFunc(MessageContainer* requestContainer) tot_sect = (fs->n_fatent - 2) * fs->csize; fre_sect = fre_clust * fs->csize; response.has_capacity = true; - response.capacity = tot_sect/2; + response.capacity = tot_sect/2*1024; response.has_freespace = true; - response.freespace = fre_sect/2; + response.freespace = fre_sect/2*1024; response.root = "/"; } @@ -588,7 +588,6 @@ uint32_t GetFilesRequestFunc(MessageContainer* requestContainer) FilesInfo[i] = &Data[i]; Data[i].has_attribute = true; Data[i].attribute = fno[i]->fattrib; - Data[i].has_length = true; Data[i].name = fno[i]->fname; Data[i].has_length = true; Data[i].length = fno[i]->fsize; diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c index 35bde3636..dcb8cf8f2 100644 --- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c +++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c @@ -24,13 +24,12 @@ #include "drivers/FPGA/Full_Vme/FPGA_Programming_Up.h" #include "Common/SWUpdate/FileSystem.h" - uint32_t ActivateVersionRequestFunc(MessageContainer* requestContainer) { - uint32_t status = OK; void* buffer = NULL; uint32_t Bytes = 0; char SWINFOPath[100]; + char FullPath[50]; FRESULT Fresult = FR_OK; int File_i; @@ -41,12 +40,13 @@ uint32_t ActivateVersionRequestFunc(MessageContainer* requestContainer) ActivateVersionResponse response = ACTIVATE_VERSION_RESPONSE__INIT; VersionPackageDescriptor* VersionPackage;// = VERSION_PACKAGE_DESCRIPTOR__INIT; + FPGA_ID FileDestinationToFPGAId[VERSION_FILE_DESTINATION__FPGA3+1] = {MAX_FPGA,FPGA1,FPGA2,FPGA3}; + strcpy (SWINFOPath,request->path); - strcat(SWINFOPath,"//SWINFO.DAT"); + strcat(SWINFOPath,"/file1.pck"); Fresult = FileRead(SWINFOPath, &Bytes, &buffer); - if (Fresult == FR_OK) { VersionPackage = version_package_descriptor__unpack(NULL,Bytes,buffer); @@ -61,17 +61,19 @@ uint32_t ActivateVersionRequestFunc(MessageContainer* requestContainer) case VERSION_FILE_DESTINATION__FPGA3: //validate //update - Fresult = FPGA_Programming_Up( VersionPackage->filedescriptors[File_i]->destination, VersionPackage->filedescriptors[File_i]->filename, false); + usnprintf(FullPath, 50, "%s%s%s", request->path,"/", VersionPackage->filedescriptors[File_i]->filename); + + Fresult = FPGA_Programming_Request( FileDestinationToFPGAId[VersionPackage->filedescriptors[File_i]->destination], FullPath, false); break; default: - LOG_ERROR (VersionPackage->filedescriptors[File_i]->destination,"wrong fule update Destination"); + LOG_ERROR (VersionPackage->filedescriptors[File_i]->destination,"wrong file update Destination"); Fresult = FR_INVALID_NAME; break; } } } responseContainer = createContainer(MESSAGE_TYPE__ActivateVersionResponse, requestContainer->token, false, &response, &activate_version_response__pack, &activate_version_response__get_packed_size); - if (status!= OK) + if (Fresult!= OK) { responseContainer.error = FileError_to_ErrorCode[Fresult]; responseContainer.errormessage = "Activate Version Request error"; diff --git a/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.c b/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.c index ab0775af3..248c9e66d 100644 --- a/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.c +++ b/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.c @@ -14,8 +14,8 @@ #include "FPGA_Programming_Up.h" #include - - +#include "Modules/Control/Control.h" +#include "Modules/Control/MillisecTask.h" extern short int main_vme(); @@ -69,8 +69,8 @@ FRESULT FPGA_Programming_Up(FPGA_ID FPGA_Id, char * FullPath, bool IncludeReboot FPGA_JTAG.GPI_TDO.Pin = GPIO_PIN_7; break; default: - //return error - break; + return FR_INVALID_OBJECT; + //break; } FileHandlevme = malloc(sizeof(FIL)); @@ -79,7 +79,7 @@ FRESULT FPGA_Programming_Up(FPGA_ID FPGA_Id, char * FullPath, bool IncludeReboot { return(fresult); } - main_vme(); + fresult = main_vme(); @@ -91,14 +91,62 @@ FRESULT FPGA_Programming_Up(FPGA_ID FPGA_Id, char * FullPath, bool IncludeReboot return fresult; } +/****************************************************************************** + * ======== messageTsk ======== + * Task for this function is created statically. See the project's .cfg file. + * this message task is created statically in system initialization, + ******************************************************************************/ +Mailbox_Handle FPGALoadMsgQ = NULL; +typedef enum +{ + OneFPGALoad, +}FPGALoadMessages; -void Test_Programing_Up() +typedef struct FPGALoadMessage{ + uint16_t messageId; + FPGA_ID FPGA_Id; + char * FullPath; + bool IncludeReboot; +}FPGALoadMessageStruc; + +FRESULT FPGA_Programming_Request(FPGA_ID FPGA_Id, char * FullPath, bool IncludeReboot) { - char FullPath1[] = "0://FPGAJTAG//F1TangoF.vme"; - char FullPath2[] = "0://FPGAJTAG//F2TangoF.vme"; - char FullPath3[] = "0://FPGAJTAG//F3_Tango.vme"; - FPGA_Programming_Up(FPGA1, FullPath1, FALSE); - FPGA_Programming_Up(FPGA2, FullPath2, FALSE); - FPGA_Programming_Up(FPGA3, FullPath3, FALSE); + FPGALoadMessageStruc FPGALoadMessage; + + FPGALoadMessage.messageId = OneFPGALoad; + FPGALoadMessage.FPGA_Id = FPGA_Id; + FPGALoadMessage.FullPath = FullPath; + FPGALoadMessage.IncludeReboot = IncludeReboot; + if (FPGALoadMsgQ != NULL) + Mailbox_post(FPGALoadMsgQ , &FPGALoadMessage, BIOS_NO_WAIT); + return FR_OK; +} + + +void FPGALoadTask(UArg arg0, UArg arg1) +{ + FPGALoadMessageStruc FPGALoadMessage; + Error_Block eb; + Error_init(&eb); + + FPGALoadMsgQ = Mailbox_create(sizeof(FPGALoadMessageStruc), 4, NULL,&eb); + + while(1) + { + Mailbox_pend(FPGALoadMsgQ , &FPGALoadMessage, BIOS_WAIT_FOREVER); + switch (FPGALoadMessage.messageId) + { + case OneFPGALoad: + ControlStop(); + MillisecStop(); + FPGA_Programming_Up(FPGALoadMessage.FPGA_Id,FPGALoadMessage.FullPath,FPGALoadMessage.IncludeReboot); + ControlStart(); + MillisecStart(); + //printf( "Finished Load FPGA %d File %s\n", FPGALoadMessage.FPGA_Id,FPGALoadMessage.FullPath ); + break; + default: + break; + } + } } diff --git a/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.h b/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.h index 91ad2a61a..b752f24b3 100644 --- a/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.h +++ b/Software/Embedded_SW/Embedded/Drivers/FPGA/Full_Vme/FPGA_Programming_Up.h @@ -32,8 +32,10 @@ typedef struct GPIO GPI_TDO; //GPI FPGA->MCU }FPGA_JTAG_GPIO; +//Independent task non blocking call +FRESULT FPGA_Programming_Request(FPGA_ID FPGA_Id, char * FullPath, bool IncludeReboot); +//direct blocking call FRESULT FPGA_Programming_Up(FPGA_ID FPGA_Id, char * FullPath, bool IncludeReboot); - #endif /* DRIVERS_FPGA_FULL_VME_FPGA_PROGRAMMING_UP_H_ */ diff --git a/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c b/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c index 37789abb1..940cd136c 100644 --- a/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c +++ b/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c @@ -217,7 +217,7 @@ uint32_t Gradual_Increase_Blower(uint32_t Initial_mV,uint32_t Target_mV) uint32_t Cancel_Gradual_Increase_Blower(uint32_t Initial_mV) { Control_Voltage_To_Blower(Initial_mV); - Report("Finished Increasing blower",__FILE__,__LINE__,(int)Initial_mV,RpWarning,(int)millisecondCounter,0); + Report("Cancelled Increasing blower",__FILE__,__LINE__,(int)Initial_mV,RpWarning,(int)millisecondCounter,0); if (RemoveControlCallback(BlowerControlId, Gradual_Increase_Blower_Callback )==OK) { Report("Remove control callback",__FILE__,__LINE__,(int)1,RpWarning,(int)BlowerControlId,0); diff --git a/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c b/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c index 4c6b18030..b3ab21f0a 100644 --- a/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c +++ b/Software/Embedded_SW/Embedded/Drivers/USB_Communication/USBCDCD.c @@ -810,6 +810,13 @@ void USBCDCD_init(void) /* State specific variables */ state = USBCDCD_STATE_UNCONFIGURED; + /*added lines for drivers version 4.178*/ + uint32_t g_ui32SysClock = MAP_SysCtlClockFreqSet((SYSCTL_XTAL_25MHZ |SYSCTL_OSC_MAIN |SYSCTL_USE_PLL |SYSCTL_CFG_VCO_480), 120000000); + USBDCDFeatureSet(0, USBLIB_FEATURE_CPUCLK, &g_ui32SysClock); + //uint32_t ui32PLLRate; + //SysCtlVCOGet(SYSCTL_XTAL_25MHZ, &ui32PLLRate); + //USBDCDFeatureSet(0, USBLIB_FEATURE_USBPLL, &ui32PLLRate); + /* Set the USB stack mode to Device mode with VBUS monitoring */ USBStackModeSet(0, eUSBModeForceDevice, 0); diff --git a/Software/Embedded_SW/Embedded/Embedded.cfg b/Software/Embedded_SW/Embedded/Embedded.cfg index 97c95a452..45ed20a54 100644 --- a/Software/Embedded_SW/Embedded/Embedded.cfg +++ b/Software/Embedded_SW/Embedded/Embedded.cfg @@ -116,6 +116,12 @@ MillisecTaskParams.stackSize = 2048; MillisecTaskParams.priority = 12; Program.global.millisec = Task.create("&MillisecTask", MillisecTaskParams); +var FPGALoad = new Task.Params(); +FPGALoad.instance.name = "FPGALoad"; +FPGALoad.stackSize = 4096; +FPGALoad.priority = 5; +Program.global.FPGALoad = Task.create("&FPGALoadTask", FPGALoad); + var ControlTaskParams = new Task.Params(); ControlTaskParams.instance.name = "control"; ControlTaskParams.stackSize = 2048; diff --git a/Software/Embedded_SW/Embedded/Main.c b/Software/Embedded_SW/Embedded/Main.c index 5e96abaf6..b13bab1d5 100644 --- a/Software/Embedded_SW/Embedded/Main.c +++ b/Software/Embedded_SW/Embedded/Main.c @@ -30,8 +30,6 @@ #include #include "Sys_PinOut_Config/MCU_MAIN_pinout.h" -#include "drivers/FPGA/Full_Vme/FPGA_Programming_Up.h" - /* #include "Drivers/SPI_SDCARD/SDSPI.h" #include "Drivers/SPI_SDCARD/SDCardSPI.h" @@ -203,9 +201,7 @@ int main(void) } //Control_File_System();// test file system //IDS_ModuleInit(); -/* - Test_Programing_Up() -*/ + //GetFiles(); - to start jtag //GetVmeByte(); diff --git a/Software/Embedded_SW/Embedded/tm4c129xnczad.cmd b/Software/Embedded_SW/Embedded/tm4c129xnczad.cmd index d63d890cd..25916dae2 100644 --- a/Software/Embedded_SW/Embedded/tm4c129xnczad.cmd +++ b/Software/Embedded_SW/Embedded/tm4c129xnczad.cmd @@ -42,7 +42,7 @@ MEMORY { /* Application stored in and executes from internal flash */ - FLASH (RX) : origin = APP_BASE, length = 0x000B0000 + FLASH (RX) : origin = APP_BASE, length = 0x000D0000 /* Application stored in and executes from internal flash */ FLASH_RAM (RWX) : origin = FLASH_RAM_BASE, length = 0x00030000 /* Application uses internal RAM for data */ -- cgit v1.3.1 From 1cbfa754eea84d46fca7a9b0d27a0a1a212b9944 Mon Sep 17 00:00:00 2001 From: Shlomo Hecht Date: Thu, 7 Feb 2019 22:29:44 +0200 Subject: reboot after load --- .../Embedded/Common/SWUpdate/FileSystem.c | 45 ---------------------- .../Embedded/Common/SWUpdate/FirmwareUpgrade.c | 9 +++-- .../Drivers/I2C_Communication/DAC/Blower.c | 1 + Software/Embedded_SW/Embedded/Main.c | 2 +- .../Embedded_SW/Embedded/Modules/Control/control.c | 26 ------------- 5 files changed, 8 insertions(+), 75 deletions(-) (limited to 'Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c') diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c index d39c335ef..c3bfa396d 100644 --- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c +++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c @@ -422,51 +422,10 @@ uint32_t DeleteRequestFunc(MessageContainer* requestContainer) DeleteResponse response = DELETE_RESPONSE__INIT; - DIR dir; FILINFO* fno = 0; //int NumOfFiles = 0; FRESULT Fresult = FR_OK; - /*Fresult |= f_opendir(&dir, g_cCwdBuf); - if(Fresult != FR_OK) - { - LOG_ERROR (Fresult,"f_write error"); - } - else - { - - fno = my_malloc(sizeof(FILINFO)); - memset (fno,0,sizeof(FILINFO)); - Fresult = f_stat(request->path,fno); - if (Fresult == FR_OK) - { - if (isDirectory(fno->fattrib)) - { - //============================ - Fresult = f_opendir(&dir, request->path); - if (Fresult == FR_OK) - { - Fresult = f_readdir(&dir, &fno); - if (Fresult == FR_OK) - { - if(fno->fname[0] ==0) - { - //no files - Fresult = f_unlink(request->path); - } - else - { - LOG_ERROR (fno,"Directory not empty"); - } - } - } - } - else - { - Fresult = f_unlink(request->path); - } - } - }*/ Fresult = f_unlink(request->path); responseContainer = createContainer(MESSAGE_TYPE__DeleteResponse, requestContainer->token, false, &response, &delete_response__pack, &delete_response__get_packed_size); @@ -593,10 +552,6 @@ uint32_t GetFilesRequestFunc(MessageContainer* requestContainer) Data[i].length = fno[i]->fsize; Data[i].lastmodifieddate = fno[i]->fdate; Data[i].lastmodifiedtime = fno[i]->ftime; - //strcpy(FullPath[i],request->path); - //strcat(FullPath[i],'\\'); - //strcat(FullPath[i],&fno[i]->fname); - //sprintf (FullPath[i], "%s/%s", request->path, &fno[i]->fname); if (i==0) usnprintf(&FullPath[i], 50, "%s", request->path); else diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c index dcb8cf8f2..e029bf2ce 100644 --- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c +++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c @@ -32,7 +32,7 @@ uint32_t ActivateVersionRequestFunc(MessageContainer* requestContainer) char FullPath[50]; FRESULT Fresult = FR_OK; int File_i; - + bool Reboot = false; MessageContainer responseContainer; ActivateVersionRequest* request = activate_version_request__unpack(NULL, requestContainer->data.len, requestContainer->data.data); @@ -62,8 +62,11 @@ uint32_t ActivateVersionRequestFunc(MessageContainer* requestContainer) //validate //update usnprintf(FullPath, 50, "%s%s%s", request->path,"/", VersionPackage->filedescriptors[File_i]->filename); - - Fresult = FPGA_Programming_Request( FileDestinationToFPGAId[VersionPackage->filedescriptors[File_i]->destination], FullPath, false); + if (VersionPackage->filedescriptors[File_i]->destination == VERSION_FILE_DESTINATION__FPGA3) + Reboot = true; + else + Reboot = false; + Fresult = FPGA_Programming_Request( FileDestinationToFPGAId[VersionPackage->filedescriptors[File_i]->destination], FullPath, Reboot); break; default: LOG_ERROR (VersionPackage->filedescriptors[File_i]->destination,"wrong file update Destination"); diff --git a/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c b/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c index 940cd136c..eced74d16 100644 --- a/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c +++ b/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/DAC/Blower.c @@ -213,6 +213,7 @@ uint32_t Gradual_Increase_Blower(uint32_t Initial_mV,uint32_t Target_mV) Report("Add control callback failed",__FILE__,__LINE__,(int)0,RpWarning,(int)BlowerControlId,0); return ERROR; } + return OK; } uint32_t Cancel_Gradual_Increase_Blower(uint32_t Initial_mV) { diff --git a/Software/Embedded_SW/Embedded/Main.c b/Software/Embedded_SW/Embedded/Main.c index b13bab1d5..56382abd0 100644 --- a/Software/Embedded_SW/Embedded/Main.c +++ b/Software/Embedded_SW/Embedded/Main.c @@ -206,7 +206,7 @@ int main(void) //GetVmeByte(); ////////////////////////////////// - #warning + #warning breathing led test //Turn off LED1 //TODO temporary to stop the breathing leds - need the change the FPGA 3 F3_Prescaler1_reg5 = 0x03; F3_low_var_LED1 = 101; diff --git a/Software/Embedded_SW/Embedded/Modules/Control/control.c b/Software/Embedded_SW/Embedded/Modules/Control/control.c index 0cda9b5a6..898f7ec67 100644 --- a/Software/Embedded_SW/Embedded/Modules/Control/control.c +++ b/Software/Embedded_SW/Embedded/Modules/Control/control.c @@ -334,20 +334,6 @@ uint32_t GetControlLowDevice_i(void) } uint32_t ControlLoop(uint32_t tick) { - //call all modules control functions - //test dancers and speed encoders - //check all callback units (state machine waiting for completion of a change) - //uint32_t ControlDevice_i; - /*bool Ten_msTick, Hundred_msTick, Onesecond_Tick,Tick98,Tick998; - Ten_msTick = (tick%eTenMillisecond == 0) ?true:false; - Hundred_msTick = (tick%eHundredMillisecond == 0) ?true:false; -// Hundred_msTick = (tick%200 == 0) ?true:false; - Onesecond_Tick = (tick%eOneSecond == 0) ?true:false; - Tick98 = (tick%eHundredMillisecond == 98) ?true:false; -// Tick98 = (tick%200 == 199) ?true:false; - Tick998 = (tick%eOneSecond == 996) ?true:false; -*/ - //ROM_IntMasterDisable(); //for (ControlDevice_i = 0; ControlDevice_i < MaxHighDevices;ControlDevice_i++) for (ControlDevice_i = 0; ControlDevice_i < MAX_TANGO_CONTROL_DEVICES;ControlDevice_i++) { @@ -379,18 +365,6 @@ uint32_t ControlLoop(uint32_t tick) } uint32_t ControlLowLoop(uint32_t tick) { - //call all modules control functions - //test dancers and speed encoders - //check all callback units (state machine waiting for completion of a change) - //uint32_t Device_i; - //bool Ten_msTick, Hundred_msTick, Onesecond_Tick,Tick98,Tick998; - //Ten_msTick = (tick%eTenMillisecond == 0) ?true:false; - //Hundred_msTick = (tick%eHundredMillisecond == 0) ?true:false; - //Onesecond_Tick = (tick%eOneSecond == 0) ?true:false; - //Tick98 = (tick%eHundredMillisecond == 98) ?true:false; - //Tick998 = (tick%eOneSecond == 996) ?true:false; - - //ROM_IntMasterDisable(); for (ControlLowDevice_i = 0; ControlLowDevice_i < MAX_TANGO_CONTROL_DEVICES;ControlLowDevice_i++) { if (ControlArray[ControlLowDevice_i].ControlActive) -- cgit v1.3.1 From 3a970a55197e14c53e2692bf64d6caa62f51ed4b Mon Sep 17 00:00:00 2001 From: Shlomo Hecht Date: Thu, 7 Feb 2019 23:31:30 +0200 Subject: file upload chunk size 4000 --- Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c') diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c index c3bfa396d..60873243c 100644 --- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c +++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c @@ -48,7 +48,7 @@ FIL *UploadFileHandle = 0; //the system supports a single active file FIL *DownloadFileHandle = 0; //the system supports a single active file char FileHandleChar[5]; char ErrorMsg[100]; -#define MAX_CHUNK_LENGTH 2000 +#define MAX_CHUNK_LENGTH 4000 int32_t FileLength = 0; int32_t FileReceivedLength = 0; int32_t FileSentLength = 0; -- cgit v1.3.1