Giter Club home page Giter Club logo

mcuoneclipse's People

Contributors

bluesign2k avatar chipfelzappe avatar cocolitto avatar daniw avatar erichstyger avatar ghsecuritylab avatar kevinuskali avatar mihu90 avatar muriukidavid avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mcuoneclipse's Issues

FreeRTOS component fails to reload

Hi Erich,
I have the latest set of pex components from sourceforge (5th feb). I am developing on kinetis K10 using KDS.
It all seems to work great until I shut down KDS.
When I restart KDS it is unable to load the list of components.

I am using the FreeRTOS component which also imports the Utility Component.
The only way I can get processor expert components back is to manually delete the Freertos bean from the pe file in the project.

There is an error generated when the components fail to load.
It look like this:
java.lang.NoSuchMethodError: com.processorexpert.core.repositories.PartialComponentReference.matches(Lcom/processorexpert/core/repositories/IComponentReference;Z)Z

Can you help me?

Thanks,
Nick

Weird Problem when snapshotting components

Hello Erich,
I have a strange issue which arose after I made a snapshot of my projects components. I'm using FreeRTOS 9.0.0 with Segger System Viewer and Command Line shell capabilities. I can create the components and everything is fine. I generate code and debug with no issues. I can run the code and attach with system viewer and it's all good UNTIL.....

I want to get my components into version control without versioning the entire KDS3 repo. So I have used the snapshot feature to create a repo of only the components needed by my project. The snapshot seems to work fine, and I can check into my VCS. However, once the project attempts to reconcile the new repository, there are a couple of problems that I can't seem to resolve. These are with the UTIL1 component and the CLS1 component. Switching the FRTOS1 component back to the original repository seems to correct the issue.

Any ideas?
Best,
-Mike

could you help me i meet a error when i use this script

java.lang.IllegalStateException: The platform metadata area could not be written: E:\MCUXpresso\workspace" -build frdmk66f_enet__enet_txrx_transfer.metadata. By default the platform writes its content
under the current working directory when the platform is launched. Use the -data parameter to
specify a different content area for the platform.

i want know how can i solve it

PE LED error on copy from KDS200 to KDS300 project

Image of LedRedCopied:LED from KDS200 project.
It has error on Properties.Hw Interface. Pin "Error in the inherited component setting"
On attempting to change the Pin it can't find a suitable component
(Using KDS300 with latest mcuOnEclipse 05-July-2015 Release)
image

If the LED is started from new it works OK
image

Kinetis low power timer defines not identical for all processor defs

When enabling the low power time as the tick timer in low power mode. The port.c file shows the following code:

if configSYSTICK_USE_LOW_POWER_TIMER

SIM_SCGC5 |= SIM_SCGC5_LPTMR_MASK; /* enable clock: SIM_SCGC5: LPTMR=1 */

Some processors (like MK20D5.h) have SIM_SCGC5_LPTIMER_MASK defined (not LPTMR). Some headers even contain both...

FreeRTOS: xTaskCreate() doesn't return Task Handle

After updating to recent PEComponents from 2015-11-22, xTaskCreate() doesn't return the task handle any more. Maybe it's a bug in FreeRTOS 8.2.3.

Reading the task handle with xTaskGetCurrentTaskHandle() from inside the task is working.

SD_Card Component Doesn't allow selection of CS pin in SPIMaster_LDD

Hi Again Erich,

I'm using the SD_Card component driving an SPIMaster_LDD component.
The settings for SD_Card allow you to select the attribute sets to use for fast and slow mode.
That all seems to work.

The problem is that the attribute set number is used for selecting the CS line.
For example, if you use 0 for slow and 1 for fast, PEX emits the following:

define SD1_SPI_SetSlowMode() (void)SM2_SelectConfiguration(SM2_DeviceData, 0, 0)

define SD1_SPI_SetFastMode() (void)SM2_SelectConfiguration(SM2_DeviceData, 1, 1)

Unfortunately, most of the time, the user will want to use the same CS pin for both fast and slow mode.
PEX will not let you have 2 different CS configurations with the same pin so it's impossible to make this work.

The fix is to emit the same CS pin for each like below:

define SD1_SPI_SetSlowMode() (void)SM2_SelectConfiguration(SM2_DeviceData, 0, 0)

define SD1_SPI_SetFastMode() (void)SM2_SelectConfiguration(SM2_DeviceData, 0, 1)

It would also be possible to let the user select the CS pin for fast and slow mode, but I can't think of a situation where different CS pins would be needed.

Thanks,
Nick

CodeWarrior 10.6 for MC9S08 C compiler don't have stdbool.h and stdint.h

Hi Erich,
As mention in title, My project was very old, target CPU is MC9S08xx, running with FreeRTOS component, after install "Components 2016-04-03.zip", new version ask a new componet "KinetisSDK",
after some fixed, PE running well, but when build my project, compiler complaint "stdbool.h" "stdint.h" not found in "KSDK1.h" , and same problem also appen in "port.c"

Could you help to fixed this problem.

Thanks,
Cai

PPAGE handling in FreeRTOS port for HCS12X banked memory model

Hi Erich,
I tried to run your FreeRTOS port on MC9 S12XEQ512 with CodeWarrior v5.1 and PE 3.06.
I'm using banked memory model for flash and I've encountered possible issue during context switching. In interrupt from TickCntr1_Interrupt there is call to TickCntr1_OnInterrupt() function. After this call PPAGE register value is changed to the flash page where TickCntr1_OnInterrupt() is located and then portSAVE_CONTEXT macro is called. In effect wrong PPAGE value might be saved and then restored.
In my case issue was fixed by moving portSAVE_CONTEXT macro earlier - to ISR, before call to the TickCntr1_OnInterrupt().
I've checked project settings with example provided by you and they are similar (ie compiler flags that may influence this behaviour).
I'm fairly new to FreeRTOS and S12 family so it's possible that this issue is caused by something else and port unrelated. BTW thanks for all the projects and instructions you share, they all have been incredibly helpful in porting my application and using this IDE.

BR
Grzegorz Sobczyk

Kinetis low power tick timer port.c: NVIC_ISER define

When activating low power tick timer (configSYSTICK_USE_LOW_POWER_TIMER) the following define is used:
/* NVIC_ISER: SETENA|=0x10000000 /
NVIC_ISER |= NVIC_ISER_SETENA(0x10000000); /
0xE000E100 <= 0x10000000 */

The NVIC_ISER define is NVIC_ISER(index) on some processor definitions (like MK20D5.h).

building tinyK22_RaspberryPi_UPS on linux: naming error

Build error on linux:
fatal error: Buttons.h: No such file or directory application.c /tinyK22_RaspberryPi_UPS/source line 45 C/C++ Problem --> line 45: #include "buttons.h"

fatal error: InitPins.h: No such file or directory initPins.c /tinyK22_RaspberryPi_UPS/source line 7 C/C++ Problem --> line 7: #include "initPins.h"

fatal error: minIni.h: No such file or directory MinINI.h /tinyK22_RaspberryPi_UPS/McuLib/src line 58 C/C++ Problem --> line 58: //#include "minIni.h" commented and it builds

Those should fix the problem with building on linux

How to use your USB PE component without any RTOS???

Dear Professor Erich,

 We downloaded and added your USB PE component (11/8/2015) into PE without using RTOS.   

When using IAR compiled the PE generated C code, we got " "freeRTOS.h" not found". We added your "FSL_USB_STACK" and "FatfsMem_USB_MSD" components into our PE, which is part of our IAR project,

 Our main project does not use any RTOS. The USB is used to read ONE fixed file which is written by K60 occasionally - Simply USB application. Our main project handles many other tasks unrelated to USB where RTOS is not used.

Can the problem be fixed without using FreeRTOS? Your past note indicates it can. But I do not know how to fix this issue. Please help - Please give us your help.

Thank you very much,

Rong

CriticalSection bug

I've found a bug that I've reported on the forum I thought I'd report it here too, since it'll look nicer

Updating CriticalSection (CS1) to 1.008 seems to cause the SDHC sub-component of my FAT_FileSystem/FatFsMemSDHC break. it somehow decides that sdhc1_SetWriteProtecton is ill-defined??

‘Building file: ../Generated_Code/SDHC1.c’
‘Invoking: Cross ARM C Compiler’
arm-none-eabi-gcc -mcpu=cortex-m4 -mthumb -O0 -fmessage-length=0 -fsigned-char -ffunction-sections -fdata-sections -g3 -I”C:/Code/kinetis/SF4V/Static_Code/PDD” -I”C:/Code/kinetis/SF4V/Static_Code/IO_Map” -I”C:/Code/kinetis/SF4V/Sources” -I”C:/Code/kinetis/SF4V/Generated_Code” -std=c99 -MMD -MP -MF”Generated_Code/SDHC1.d” -MT”Generated_Code/SDHC1.o” -c -o “Generated_Code/SDHC1.o” “../Generated_Code/SDHC1.c”
../Generated_Code/SDHC1.c:1474:12: error: conflicting types for ‘SDHC1_SetWriteProtection’
LDD_TError SDHC1_SetWriteProtection(LDD_TDeviceData *DeviceDataPtr, LDD_SDHC_TWriteProtectType Type, uint32_t Address, bool Protected)
^
In file included from ../Generated_Code/FATM1.h:64:0,
from ../Generated_Code/SDHC1.c:129:
../Generated_Code/SDHC1.h:597:12: note: previous declaration of ‘SDHC1_SetWriteProtection’ was here
LDD_TError SDHC1_SetWriteProtection(LDD_TDeviceData *DeviceDataPtr, LDD_SDHC_TWriteProtectType Type, uint32_t Address, bool Protected);
^
make: *** [Generated_Code/SDHC1.o] Error 1

the problem is here:

-/* Include shared modules, which are used for whole project */
-#include “PE_Types.h”
-#include “PE_Error.h”
-#include “PE_Const.h”
-#include “IO_Map.h”
/* Include inherited beans */
+#include “KSDK1.h”

-#include “Cpu.h”+#if KSDK1_SDK_VERSION_USED == KSDK1_KSDK1_SDK_VERSION_NONE
+/* Include shared modules, which are used for whole project */
+ #include “PE_Types.h”
+ #include “PE_Error.h”
+ #include “PE_Const.h”
+ #include “IO_Map.h”
+ #include “Cpu.h”
+#endif

KSDK1_KSDK1_SDK_VERSION_NONE has an extra KSDK1_

Cannot see anything in Image Info Tab of MCUXpressoIDE v11.2.1_4149?

Hi all,

I have imported a project for the LPC11U68 in my workspace of MCUXpresso 11.2.1.
The project builds fine without errors. Only I see no info at all from the Image Info Tab!
Tried to copy this project into the workspace to see if this could make the difference, but the result is the same.

Have any of you guys have experienced this issue?
I would appreciate if anybody has a solution/guidance or workaround for this issue.
Thanks for help in advance!

Max

minINI: writing to the sd card

Thanks for the blog Erich.

I am trying to integrate minINI with Fatfs in baremetal. Everything seems working until I try to write a value or string to the Key in its sections. While trying to write with ini_putl & in_puts, the unnecessary files has been creating inside with size of 524787 bytes . And the actual files inside the card been changes and not able to open the files.

I have not defined read-only in the header.
What causing the issue ?
ini_puts2

KDS USB Host MSC ISO99 cc isssue

Not sure if this is worth mentioning, but using Comonent USB:FSL_USB_stack MSD Host I'm having a couple of compile errors.
Either I'm doing something wrong (Learner plates still on advice appreciated) or upgrade to KDS issue.

I'm using (http://sourceforge.net/projects/mcuoneclipse/ Components 2014-10-17.zip)
and set CPU:MK20DX128VLH5 (from my FRDM-K20D50 RevB brd)
set the USB1:FSL_USB_Stack to Init_USB_OTG_VAR0, MSD Host, MSD
This causes errors with asm() with reason and fix
https://community.freescale.com/thread/326345

Then setting the compiler to GNU ISO C90 results in another error
GeneratedCode/usbmsgq.c:
'index' redeclared as different kind of symbol usbmsgq.c /Mk20Dx50Logger/Generated_Code line 38 C/C++ Problem

This can be fixed by changing index --> index2

Of course whenever the PE regenerates the files, it goes back to previous problem.
Suggested solution: change asm to __asm() per
https://community.freescale.com/thread/326345

Wifi driver for joystick

hi , sorry to open a ticket for my question, but I have some questions that your probably advise is really appreciated
Actually I've been trying to send some game keys, base on HID protocol to the computer by wifi link(ESP8266). PC computer with OS like Microsoft Windows instantly make "HID-compliant game controller" driver with typical USB joystick , my question is, how make specific driver which is shows up same as "HID-compliant game controller" but listen to specific IP address instead of USB
tnx

FreeRTOS compile issue

Running FreeRTOS bean on Codewarrior (MCU) for DEMO09S08DZ60 board. Bean settings are default.

  1. Looks like function "UBaseType_t FRTOS_AppGetRuntimeCounterValueFromISR(void)" is being re-declared because of a different return value type.

  2. Also enabling Custom portBASE_TYPE seems to totally mess up the compiler in that I get error "C1067 missing decl specifiers" and error "C2450 Expected ;" at Line 181: "BaseType_t xPortStartScheduler( void ) PRIVILEGED_FUNCTION;" in "portable.h"

Bad cast in gprof for arm

I try to reuse in a somewhat different context your great work on gprof, and I found a bug in the git hub implementation.

gmon.c:267 frompcindex should not be used but a fresh uint16t * should

p->froms is a u_short *

best regards

Waitms() inaccurate on Kinetis

Hi Erich,

I noticed that for my FRDM-KL25Z board, the Wait component is generating the following code for Waitms():

WAIT1_WaitCycles(1000);

Looking at your Processor Expert driver, I noticed that the other processor families have definitions like this:

NofCyclesMs(1, CPU_BUS_CLK_HZ);

When I put that in my code, my timing is a LOT more accurate, so why does the Kinetis require a fixed 1000 cycle delay?

Pointer to code:

https://github.com/erichstyger/mcuoneclipse/blob/master/Drivers/sw/Wait.drv#L546

Thanks!
Vishal

Init_Config.h missing

fatal error: Init_Config.h: No such file or directory ADC0_Init.c /FRDM-K64F_Demo/Static_Code/Peripherals line 56

FreeRTOS needs Shell named as CLS1

With the recent PEComponents from 2015-11-22, FreeRTOS needs the enabled shell named as CLS1.

The compiler throws 2 errors, if I name my shell e.g. SH1:

arm-none-eabi-g++ -mcpu=cortex-m0plus -mthumb -Os -fmessage-length=0 -fsigned-char   -ffunction-sections -fdata-sections -ffreestanding -Wall -Wextra  -g -T ...   
./Generated_Code/FRTOS1.o: In function `PrintTaskList':
./Generated_Code/FRTOS1.c:186: undefined reference to `CLS1_SendStr'
./Generated_Code/FRTOS1.c:219: undefined reference to `CLS1_SendStr'
collect2: error: ld returned 1 exit status

If I rename the shell to CLS1, everything is fine and the code is working.

FATFsMemSDHC throughput issue

Hi Erich,

http://mcuoneclipse.com/2012/07/30/fatfs-with-kinetis/#comment-16199

In the above comment, you mentioned that you weren't seeing any performance benefits using more data pins during SDHC communication. I believe this is due to the way that FATFsMemSDHC implements the disk_read and disk_write functions. Both of these functions use the following block of code to handle transferring multiple blocks to/from the SD card:

do {
if (SD_TransferBlock(&SD, FALSE, sector_FATM1_BLOCK_SIZE, (uint8_t_)buff, 1)) {
break;
}
sector++;
buff += FATM1_BLOCK_SIZE;
} while(--count);

Rather than performing one multi-block I/O operation, the component performs a number of single-block I/O operations. This incurs the SD card's read (or write) access time for each block transferred. A multi-block transfer would only incur this cost once.

I tested using 4-pin communication at 24MHz. A single 512-byte block read takes about 660us -- about 40us for the data transfer and 620us for the card-specific read access time. With the original disk read_function, reading n blocks takes n_(620us + 40us). I made some minor changes to disk_read and SD_TransferBlock so that they attempt to make a single multi-block read. Using the modified function, I saw times much closer to the ideal value of 620us + n_40us for n blocks.

Bug in GenericTimeDate component's computation of hundredths of seconds

When the tick time is < 10ms as in our application, the Sec100 variable is always set to 0.
The code currently generated is:

Time->Sec100 = (byte)((ticks%Datetime_TICKS_PER_S)*(Datetime_TICK_TIME_MS/10)); /* number of 1/10 seconds */

I think the fix is to perform division after the multiplication. Furthermore, the comment should say 1/100 instead of 1/10:

Time->Sec100 = (byte)((ticks%Datetime_TICKS_PER_S*Datetime_TICK_TIME_MS)/10); /* number of 1/100 seconds */

Thanks!

nRF24 project with KDS

Hello Eirch,

First of all, thank you so much for the amazing blog posts and this GitHub repo. I've been referring to you blog a lot to get up and running with my K64F board.

I want to try your nRF24 project with KDS 3.2.0, can you please give me some hint as to how to import the project into KDS? I don't see a .wsd file in the example folder, nor does KDS accent the .pe files. I'm very new to KDS in general so forgive me if I'm overlooking something obvious.

Thanks,
Ady

Wiki test documentation

Hey eric, an idea for the wiki associated with mcuonelipse- create a framework to document tests for components.
I really like your blog and postings on helpful snippets - and I wonder if there was a place for programmers to post their test results if they would?
Testing is the critical end of creating software, and critical to get an idea of when something worked and under what circumstances. Posting test results to the wiki with potential issue updates - that you could accept into the mainstream would also help build collaborative skills.
I would expect - but don't know - that github supports some sort of editorial revision control on wiki updates.
I did it for an mbed project:
http://developer.mbed.org/users/neilh20/code/kl25z_Usb_Logger/wiki/Homepage
So github doesn't have a way of marking an issue a feature request/suggestion that I can see of- so hope this works for you, and just retire it with a NO if you don't like it. Project Manager after all can attract some interesting effects in dark tunnels:)

"Unknown macro" error when generating FreeRTOS component files

When the "Dynamic Allocation" is disabled under the "Memory" properties, the following error occurs:

Generator: FAILURE: at line 4785: Unknown macro: "LinkerHeapBaseSymbolName" (file: Drivers\sw\FreeRTOS.drv) qg-h1 FRTOS1 Processor Expert Problem

I recently upgraded my ProcessorExpert components to the July 2017 release. Before this, I would never receive an error when "Dynamic Allocation" was disabled and "Static Allocation" was enabled. Unfortunately, I don't recall which release I had before performing the update.

SD card data width & clock speed always reset to 1-bit & 400kHz, causing slow write speeds

The function disk_initialize() resets the data bus width and the clock speed whenever it is called - and it is called by f_open(), meaning that file IO operations will always be slow. This appears to have been discussed in the comments on your blog.

I'll make a pull request that I believe fixes the issue, but I know very little about the making of processor expert components. Here is what the end result looks like for me:

DSTATUS disk_initialize (
        BYTE drv                        /* Physical drive number (0..) */
)
{
  bool Error = FALSE;

  if (drv!=0) return STA_NOINIT;        /* Supports only single drive */
  if (Stat & STA_NODISK) return Stat;   /* No card in the socket */

  if (!Error && SD.Inserted) {
    if (SD.SDHCPtr!=NULL) {
      SDHC1_Deinit(&SD.SDHCPtr);
      SD.SDHCPtr = SDHC1_Init(&SD);
      SD_Wait(&SD, &Error);
    }
    if (SDHC1_DetectCards(SD.SDHCPtr)!=ERR_OK) {
      Error = TRUE;
    }
    SD_Wait(&SD, &Error);
    if (!Error && SD.CardId != SDHC1_NO_CARD) {
      /* card detected - selecting card... */
      if (SDHC1_SelectCard(SD.SDHCPtr, SD.CardId)!=ERR_OK) {
        Error = TRUE;
      }
      SD_Wait(&SD, &Error);
    }
    if (!Error) {
      /* card selected - requesting card info... */
      if (SDHC1_GetCardInfo(SD.SDHCPtr, &SD.CardInfo)!=ERR_OK) {
        Error = TRUE;
      }
      SD_Wait(&SD, &Error);
    }
    if (!Error) {
      /* switching gears for higher speed */
      Error = SDHC1_SelectBusClock(SD.SDHCPtr, FATMEM_SPEED_INDEX_NORMAL)!=ERR_OK;
      SD_Wait(&SD, &Error);
    }
    if (!Error && SD.CardInfo.Caps.HighSpeed) {
      Error = SDHC1_SelectBusClock(SD.SDHCPtr, FATMEM_SPEED_INDEX_FAST)!=ERR_OK;
      SD_Wait(&SD, &Error);
      /* running at high speed (high slew rate on all the SDHC pins should be set) */
    }
    if (!Error) {
      if (SD.CardInfo.Caps.DataWidths&LDD_SDHC_CARD_DATA_WIDTH_8_BIT) {
        Error = SDHC1_SetDataWidth(SD.SDHCPtr, LDD_SDHC_CARD_DATA_WIDTH_8_BIT)!=ERR_OK;
      } else if (SD.CardInfo.Caps.DataWidths&LDD_SDHC_CARD_DATA_WIDTH_4_BIT) {
        Error = SDHC1_SetDataWidth(SD.SDHCPtr, LDD_SDHC_CARD_DATA_WIDTH_4_BIT)!=ERR_OK;
      } else if (SD.CardInfo.Caps.DataWidths&LDD_SDHC_CARD_DATA_WIDTH_1_BIT) {
        Error = SDHC1_SetDataWidth(SD.SDHCPtr, LDD_SDHC_CARD_DATA_WIDTH_1_BIT)!=ERR_OK;
      }
      SD_Wait(&SD, &Error);
  }

  Stat &= ~STA_NOINIT;                  /* Clear STA_NOINIT */
  return Stat;
}

TIMEOUT Component Enhancement

Hello,

I like the Timeout component but I'd like to see a Reset function added, to be able to reuse a timeout instance insdead of destroying it/creating a new one just to get a fresh countdown timer or change the value on-the-fly. The Reset function could be as follow:

/*
** ===================================================================
** Method : TMOUT1_Reset(component Timeout)
** Description :
** Resets the counter value and return the value just prior to
** the call.
** Parameters :
** NAME - DESCRIPTION
** handle - Counter handle
** nofTicks - Number of ticks for the counter
** until it expires.
** Returns :
** --- - The previous value of the counter (ticks)
**
** ===================================================================
*/

TMOUT1_CounterType TMOUT1_Reset(TMOUT1_CounterHandle handle, TMOUT1_CounterType nofTicks)
{
TMOUT1_CounterType res;
CS1_CriticalVariable();

if (handle==TMOUT1_OUT_OF_HANDLE) {
return;
}
if (nofTicks==0) {
nofTicks = 1; /* wait at least for one tick, otherwise will timeout immediately */
}
CS1_EnterCritical();
res = TMOUT1_Counters[handle];
TMOUT1_Counters[handle] = nofTicks;
CS1_ExitCritical();
return res;
}

As a side note, TMOUT1_Value() does not check the validity of the handle, and the documentation says it returns nothing.

As another side note, I'm not sure of the need for the nofTicks==0 then nofTicks=1, there are cases where the timeout must be zero, for example you may want to compute a delay that makes sure a given operations lasts at least a given amount of time, and in some cases the computed additional delay may very well be zero. I'd drop those ifs: when the app says zero then the timout object starts as "expired" which is what the app asked for. You can make it a codegen preference option perhaps?

Cheers from Geneva,
Axel

KDS USB Host MSC cpu K64 not an option

When attempting the FRDM-K64 USB HOST MSC the
MSD1:FSL_USB_MSD_Host component inspector only offers a CPU of Kinetis K60 - maybe be that is similar to the the K64.
All the other cpu options are very specific to the device family so just wondering if this should be K64.
The starting point was importing the
Examples/KDS/FRDM-K64F120M/FRDM-K64F_USB_CDC
getting that working, and then attempting to change the Device Class to MSD Host

split repo

Hi Erich

I would suggest to split your repo into several repos of its own as I think it would improve usability and also simplify collaboration. The current repo contain several zip archives and also the history of them. This blows up the size of the repo unnecessarily as each revision needs almost the full amount of space. Due to it's structure, it makes it inconvenience to work on the pe components.

Proposed layout

mcuoneclipse/Beans                  +
mcuoneclipse/Drivers                +-> mcuoneclipse_pe
mcuoneclipse/Eagle                  --> mcuoneclipse_hw
mcuoneclipse/Examples               --> mcuoneclipse_examples
mcuoneclipse/{EclipsePlugins,PEupd} --> keep it as is

With this design, one can just clone the processor expert components into his local PE folder, work on them and create a pull request. Also this repo would be quite small. Someone working on e.g. hardware only has to clone the _hw folder and not the whole ~300MB

How can this be done

One important point when talking about splitting is if the history will be preserved or not. Fortunately whith git this can be done easily. Example to create the _pe repo is shown below.

$ git clone https://github.com/ErichStyger/mcuoneclipse.git
$ cd mcuoneclipse
$ git filter-branch --index-filter 'git rm --cached --ignore-unmatch -r Eagle EclipsePlugins Examples PEupd' -- --all

Now the local master branch only contains the two pe related folders Beans and Drivers. Now create a new repo on github and push it. I've done the above steps and pushed it to https://github.com/bearsh/mcuoneclipse_pe
The newly created repo is quite small (~7MB) compared to the original one (not in the current directory as this still include the whole history).

For the other repos, the same step can be done.

Conclusion

In my opinion this is the right way to go as it ease contribution, let the user only clone what is relevant to him and it uses git in the way it is designed to be used. You can even go a step further and create a repo for each pe component but that would probably be an overkill. If you still like to have everything in one repo, simply include the various repos as sub-repo in your main repo.

What do you think?

Wait functions word width too low?

Hi Erich,

I noticed another problem with the WAIT component's functions - they only support 16-bit arguments. It's simple enough to work around this, but it leads to some situations where you call a higher level function with a large number and it calls a lower-level function with a value too large to fit into 16 bits. For example, at 72MHz, WAIT_Waitms(1000) in turn calls WAIT1_WaitCycles(72000). This probably didn't occur with the FRDM boards since they are limited to 50MHz and you wouldn't often call it with such large values, but it did happen to be at 72MHz.

Thanks,
Vishal

Don't name libraries this way!

Don't name a library QFN32 when there is not even one QFN32 package inside - don't steal others peoples lifetime this way!

FAT_FileSystem Component: unreachable code (2x)

There are two occurences of unreachable code in the generated code:

FS.C(719) FS_errFResultMsg() : the statement return (char_)"_error*"; is unreachable (the switch statement has a default case).

FS.C(744) FS_errDResultMsg : idem.

FreeRTOS component fails to generate on HCS12

It seems FreeRTOS PE component does not work with CodeWarrior for HCS12 v5.1 (PE v3.02), which is the latest (and the last) version of CW/PE for HCS12.

When I add FreeRTOS component, PE warns that a tick counter (TickCntr) component used by FreeRTOS has an error. Actual error found in TickCntr component window is: "Method Reset is not supported for selected device.".

Your website (http://www.steinerberg.com/EmbeddedComponents/FreeRTOS/) states that at least PE 3.09 service pack is needed. But the last version to support HCS12 is CW v5.1 + PE v3.02. Does this mean HCS12 is not supported anymore?

I'm not sure how to troubleshoot this.

I have FreeRTOS v8.0 running on my HCS12 board, so FreeRTOS surely still supports HCS12. And the warning given by PE also seems trivial, as I'm pretty sure there is some way to implement "Reset" functionality for any HCS12 timer/counter needed for system tick counting. Is there any way (say, editing some component bean file?) to suppress this error and allow me to implement needed function?

I'm using latest Part[12]_Beans_08.02.2014.PEupd checked out from github, with CW for HCS12 v5.1 (both special edition and eval edition, which I just installed now - so eval edition has all functionality enabled).

Best Regards,

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.