• Stars
    star
    136
  • Rank 267,670 (Top 6 %)
  • Language
    C
  • License
    Other
  • Created about 8 years ago
  • Updated about 1 month ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Library of McuOnEclipse components
readme.txt
----------
This is the 'McuOnEclipseLibrary' or short 'McuLib': a scalable C/C++ library from the McuOnEclipse (https://mcuoneclipse.com/) project.
Some of the drivers are generated by Processor Expert for legacy reasons, but no Processor Expert is required to use the library.

Directories:
- Generator: Processor Expert (NXP Kinetis Design Studio) project used to create some of the files.
- lib/src: driver source and interface files
- lib/config: driver configuration header files
- lib/fonts: graphical fonts used with the McuFontDisplay

Additionally following middleware is provided:
- lib\FatFS: FAT FS File System by Elm Chan
- lib\FreeRTOS: FreeRTOS port for ARM Cortex-M (M0, M4, M33, M7) and RISC-V
- lib\HD44780: library for the HD44780 character display
  see https://mcuoneclipse.com/2019/01/27/tutorial-hd44780-display-driver-with-nxp-mcuxpresso-sdk/
- lib\LittlevGL: GUI library for microcontrollers and small LCD's
- lib\SEGGER_RTT: Port of the SEGGER RTT Library
- lib\SEGGER_Sysview: Port of the SEGGER SystemView Library
- lib\TraceRecorder: Port of the Percepio Tracealyzer library, see
  https://mcuoneclipse.com/2018/02/18/faster-freertos-percepio-tracealyzer-streaming-with-segger-rtt/
  https://mcuoneclipse.com/2017/03/08/percepio-freertos-tracealyzer-plugin-for-eclipse/
- lib\minIni: INI file reading and writing, see
  https://mcuoneclipse.com/2014/04/26/frdm-with-arduino-ethernet-shield-r3-part-4-minini/
  https://mcuoneclipse.com/2020/05/20/fatfs-minini-shell-and-freertos-for-the-nxp-k22fn512/
  https://mcuoneclipse.com/2021/05/15/using-fatfs-and-minini-with-the-nxp-lpc55s16-evk/
  https://mcuoneclipse.com/2021/12/19/key-value-pairs-in-flash-memory-file-system-less-minini/

Make sure you follow my McuOnEclipse blog: http://mcuoneclipse.com/ for updates and new articles.

How to integrate the library
============================
NEW: if you consider adding the McuLib to many Eclipse/MCUXpresso projects, consider using
  the PowerShell scripts written by 'urhano':  https://github.com/urhano/addMCULib

- download the repository zip file: https://github.com/ErichStyger/McuOnEclipseLibrary/archive/master.zip
- place the 'lib' folder into your Eclipse project and rename it to 'McuLib'. You can use any other name, but then you need to change the include paths accordingly
- Make sure that the folder is included in the build (see https://mcuoneclipse.com/2014/07/22/exclude-source-files-from-build-in-eclipse/)
- Add the following paths to the compiler include settings (you might simply copy-paste them into the control):
../McuLib/config
../McuLib/config/fonts
../McuLib/fonts
../McuLib/src
../McuLib/FreeRTOS/Source/include
../McuLib/FreeRTOS/Source/portable/GCC/ARM_CM4F
../McuLib/SEGGER_RTT
../McuLib/SEGGER_Sysview
../McuLib/TraceRecorder
../McuLib/TraceRecorder/config
../McuLib/TraceRecorder/include
../McuLib/TraceRecorder/streamports/Jlink_RTT/include
../McuLib/HD44780
../McuLib/minIni
- Disable or remove not used FreeRTOS ports, e.g.
  ../McuLib/FreeRTOS/Source/portable/GCC/ARM_CM33
  ../McuLib/FreeRTOS/Source/portable/GCC/RISC-V
- If the project contains a hard fault handler: disable or remove it, as the McuLib comes with its own handler.
- Edit the McuLib/config/McuLibConfig.h header file which configures the library. Below the settings for the Kinetis (ARM Cortex-M4F with FPU) using the MCUXpresso SDK 2.5.0:
#define McuLib_CONFIG_CPU_IS_ARM_CORTEX_M    (1 || defined(__CORTEX_M))
#define McuLib_CONFIG_CPU_IS_KINETIS         (1 && McuLib_CONFIG_CPU_IS_ARM_CORTEX_M)
#define McuLib_CONFIG_CORTEX_M      (4)
#define McuLib_CONFIG_FPU_PRESENT   (1 || (defined(__FPU_PRESENT) && (__FPU_PRESENT)==1))
#define McuLib_CONFIG_FPU_USED      (1 || (defined(__FPU_USED) && (__FPU_USED)==1))
#define McuLib_CONFIG_SDK_VERSION_MAJOR   2
#define McuLib_CONFIG_SDK_VERSION_MINOR   5
#define McuLib_CONFIG_SDK_VERSION_BUILD   0
#define McuLib_CONFIG_SDK_VERSION_USED  McuLib_CONFIG_SDK_MCUXPRESSO_2_0

How to use the Modules in the library
=====================================
a) Include the Module header file:
#include "McuWait.h"

b) Initialize the Module before using it:
McuWait_Init(); /* initialize the module */

c) Use the Module:
McuWait_Waitms(100); /* wait for 100 ms */

Enjoy!
Erich