LPC Microcontrollers Knowledge Base

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPC Microcontrollers Knowledge Base

Discussions

Sort by:
1 Abstract       MCB1700 is the evaluation board from KEIL, the onboard chip is LPC1758, LPC1768 or LPC1769 which is based on ARM cortex-M3.       EmWin is the embedded graphics library developed by SEGGER, it is now offered by NXP in library form for free commercial use with NXP microcontrollers. The software bundle offered by NXP includes the emWin Color basic package, the Window Manager/Widgets module including the GUIBuilder, the Memory Devices module for flicker-free animation, the Antialiasing module for smooth display of curves, lines and fonts, the Font Converter and the VNC Server.        NXP have provided the MCB1700 emWin board support packages: emWin 5.14 BSP version 1.0 for MCB1700  This package includes three IDE project: IAR, MDK and LPCXpresso, but now, when customer use it, normally will find these questions: LPCXpresso project have the build error MDK project have the build error Some MCB1700 boards can’t work after downloading this code, LCD always display white, no other pictures.     This document is mainly talking about these three problems and give the according solutions to make the MCB1700 emWin_mcb1700_bsp work. 2 Code issue analysis and solutions      Customer need to download the emWin_mcb1700_bsp at first from the above link, and install it, after the package is installed in default, the source code can be found in this path: C:\nxp\emWin\NXP_emWin514_MCB1700_BSP 2.1 keil project build error       This chapter mainly describe the emWin_mcb1700_bsp keil project build error and it’s solutions. 2.1.1 Problem reproduction       Open the emWin_mcb1700_bsp keil project with keil IDE, you may find there has 6 errors like the following picture: All these errors are related to the GUI function which is included in the emwin lib, after click the GUI folder, you will find the lib is emWin_514 which is the old emWin lib. So people can try to use the newest lib from the nxp website. 2.1.2 Problem solution     Download the newest emWin lib from this link:    emwin 5.30 Pre-Compiled Libraries for NXP ARM MCUs    After install it, copy emWin_M3.lib from folder: NXP_emWin530\emWin_library\Keil\ to NXP_emWin514_MCB1700_BSP\GUI folder. Then add this new lib to the KEIL project’s GUI folder like this:    After the emWin_M3.lib is added, remove the build of old lib emWin_514_Keil4_M3_LE.lib, just deselect item include in Target build in the right click options like this: Save and rebuild it again, you will find the error is disappeared. 2.2 LPCXpresso project build error     This chapter mainly describe the emWin_mcb1700_bsp LPCXpresso project build error and it’s solutions. 2.2.1 LPCXpresso project problem reproduction Open LPCXpresso project, and build it, you may find these problems:     All the errors are C/C++ Problem. 2.2.2 LPCXpresso project problem solution     Choose project->properties, change the language standard to GNU C90 stand like this:   Click button “ Apply”,  then rebuild it again, you will find the error is disappeared: Of course, you also can change the lib to the newest one, just like the method in the KEIL project, use the newest LPCXpresso emWin lib from this folder:  NXP_emWin530\emWin_library\LPCXpresso\libemWin_M3.a   2.3 Code function problem in some MCB1700 board      This part is mainly taking about the function problem in some MCB1700 boards, give the analysis and the according solutions. 2.3.1 Code function problem reproduction       After the build problem is solved, customer can download the code to the MCB1700 board by debugger or programmer, no matter with LPC1758, LPC1768 or LPC1769. After testing some MCB1700 boards, we found some board always display white, the emwin function doesn’t work, but some board can display the correct picture. All these boards seems the same.       I have compared these boards carefully, I found the series number in the LCD have difference, now I list it as follows:   MCB LCD Series number RESULT MCB1758 A774A-43-P101210-4072 OK MCB1758 A774A-61-P120814-4074 Abnormal, LCD display white MCB1769 A774A-22-P120814-4074 Abnormal, LCD display white MCB1769 A774A-57-P120814-4074 Abnormal, LCD display white      From the above form, we can find all the MCB boards which can’t work have one feature: the LCD series number contains P120814, so it should be related to the LCD controller, but what the controller on these MCB1700 boards? After download the LCD_Blinky code from the KEIL IDE install path: C:\Keil_v5\ARM\Boards\Keil\MCB1700\LCD_Blinky I found this project can display the picture correctly, so I do the debugging and the source code checking, after that I get the LCD with P120814 is using the HX8347-D LCD controller which from Himax company. But the LCD diver code in emWin MCB1700 BSP is for SPFD5408 LCD controller.   2.3.2 Code function problem solutions     Here take MDK project as an example, describe how to modify the emWin_MCB1700_BSP code and make it work in those not working MCB1700 boards. After the analysis in the above chapter, you will get that the main problem is caused by the LCD driver, so the code modification is mainly about the LCDConf.c file, this code in this file is for the LCD driver configuration. 2.3.2.1 Modify the display orientation     Comment the old DISPLAY_ORIENTATION definition, and define it like this: //#define DISPLAY_ORIENTATION (GUI_SWAP_XY) #define DISPLAY_ORIENTATION (GUI_MIRROR_X | GUI_SWAP_XY)   2.3.2.2 Modify the LCD controller initialization code From chapter 2.3.1, we can get the LCD on the not working MCB1700 board is HX8347-D, the HX8347 LCD controller initialization code should be modified like this: static void _InitController(void) { #ifndef WIN32     GUI_X_Delay(10);   LCD_X_SPI_Init();   GUI_X_Delay(10);     /* Driving ability settings ------------------------------------*/     wr_reg(0xEA, 0x00);       /* Power control internal used (1)    */     wr_reg(0xEB, 0x20);       /* Power control internal used (2)    */     wr_reg(0xEC, 0x0C);       /* Source control internal used (1)   */     wr_reg(0xED, 0xC7);       /* Source control internal used (2)   */     wr_reg(0xE8, 0x38);       /* Source output period Normal mode   */     wr_reg(0xE9, 0x10);       /* Source output period Idle mode     */     wr_reg(0xF1, 0x01);       /* RGB 18-bit interface ;0x0110       */     wr_reg(0xF2, 0x10);             /* Adjust the Gamma Curve --------------------------------------*/     wr_reg(0x40, 0x01);     wr_reg(0x41, 0x00);     wr_reg(0x42, 0x00);     wr_reg(0x43, 0x10);     wr_reg(0x44, 0x0E);     wr_reg(0x45, 0x24);     wr_reg(0x46, 0x04);     wr_reg(0x47, 0x50);     wr_reg(0x48, 0x02);     wr_reg(0x49, 0x13);     wr_reg(0x4A, 0x19);     wr_reg(0x4B, 0x19);     wr_reg(0x4C, 0x16);       wr_reg(0x50, 0x1B);     wr_reg(0x51, 0x31);     wr_reg(0x52, 0x2F);     wr_reg(0x53, 0x3F);     wr_reg(0x54, 0x3F);     wr_reg(0x55, 0x3E);     wr_reg(0x56, 0x2F);     wr_reg(0x57, 0x7B);     wr_reg(0x58, 0x09);     wr_reg(0x59, 0x06);     wr_reg(0x5A, 0x06);     wr_reg(0x5B, 0x0C);     wr_reg(0x5C, 0x1D);     wr_reg(0x5D, 0xCC);       /* Power voltage setting ---------------------------------------*/     wr_reg(0x1B, 0x1B);     wr_reg(0x1A, 0x01);     wr_reg(0x24, 0x2F);     wr_reg(0x25, 0x57);     wr_reg(0x23, 0x88);       /* Power on setting --------------------------------------------*/     wr_reg(0x18, 0x36);       /* Internal oscillator frequency adj  */     wr_reg(0x19, 0x01);       /* Enable internal oscillator         */     wr_reg(0x01, 0x00);       /* Normal mode, no scrool             */     wr_reg(0x1F, 0x88);       /* Power control 6 - DDVDH Off        */     GUI_X_Delay(200);     wr_reg(0x1F, 0x82);       /* Power control 6 - Step-up: 3 x VCI */     GUI_X_Delay(50);                     wr_reg(0x1F, 0x92);       /* Power control 6 - Step-up: On      */     GUI_X_Delay(50);     wr_reg(0x1F, 0xD2);       /* Power control 6 - VCOML active     */     GUI_X_Delay(50);       /* Color selection ---------------------------------------------*/     wr_reg(0x17, 0x55);       /* RGB, System interface: 16 Bit/Pixel*/     wr_reg(0x00, 0x00);       /* Scrolling off, no standby          */       /* Interface config --------------------------------------------*/     wr_reg(0x2F, 0x11);       /* LCD Drive: 1-line inversion        */     wr_reg(0x31, 0x00);     wr_reg(0x32, 0x00);       /* DPL=0, HSPL=0, VSPL=0, EPL=0       */       /* Display on setting ------------------------------------------*/     wr_reg(0x28, 0x38);       /* PT(0,0) active, VGL/VGL            */     GUI_X_Delay(200);     wr_reg(0x28, 0x3C);       /* Display active, VGL/VGL            */   //  wr_reg(0x16, 0x00);       /* Mem Access Control (MX/Y/V/L,BGR)  */       /* Display scrolling settings ----------------------------------*/     wr_reg(0x0E, 0x00);       /* TFA MSB                            */     wr_reg(0x0F, 0x00);       /* TFA LSB                            */     wr_reg(0x10, 320 >> 8);   /* VSA MSB                            */     wr_reg(0x11, 320 & 0xFF); /* VSA LSB                            */     wr_reg(0x12, 0x00);       /* BFA MSB                            */     wr_reg(0x13, 0x00);       /* BFA LSB                            */ #endif }   2.3.2.3 Modify the LCD_X_Config configuration    From the emWin display drivers website in the Segger: https://www.segger.com/emwin-display-drivers.html You can find the HX8347 display driver is GUIDRV_FlexColor, the parameter pfFunc in function GUIDRV_FlexColor_SetFunc is GUIDRV_FLEXCOLOR_F66712.   So, modify GUIDRV_FlexColor_SetFunc in the LCD_X_Config function like this: GUIDRV_FlexColor_SetFunc(pDevice, &PortAPI, GUIDRV_FLEXCOLOR_F66712, GUIDRV_FLEXCOLOR_M16C0B16);     After the modification, then save and rebuild it. At last, download the code to the MCB1700 board which was not working before, download the code to the board, press the RESET button on the board, you will find the LCD displays the GRAPH_DATA_XY demo picture like this:   2.3.3 Other applications testing    After the above code modification for the not working MCB1700 board, if you have interest, you also can try the other application to display other pictures. In folder  NXP_emWin514_MCB1700_BSP\Application, there still has a lot of other applications, you just need to add it to the application folder in the project, then the LCD can display the according picture,  now list some application’s testing result. 2.3.3.1 GUI_WIDGET_GraphYtDemo.c   2.3.3.2 GUI_HelloWorld.c     2.3.3.3 GUI_ALPHA_TransparentDialogDemo.c   2.3.3.4 WM_RadialMenu.c   3 Conclusion    From the above detail descriptions, you will know emWin_MCB1700_bsp KEIL project build error can be fixed by changing the lib to the newest emwin lib, LPCXpresso project build error can be fixed by changing the language standard to GNU C90, the function problem in some MCB1700 is mainly caused by the mismatch LCD driver, just modify the code to the according LCD driver can fix the LCD display white problem.    Wish this document can help those customers who are using the emWin_MCB1700_bsp on the MCB1700 board, the modified project also in the attachment for your reference.
View full article
Now that you've downloaded & unzipped your LPCXpresso54608 SDK, let's open IAR Embedded Workbench IDE. Note: You must have at least IAR Embedded Workbench version 7.80.3.12146 to use this board Once open, select File>Open>Workspace Navigate to the location where you unzipped your SDK files. Within this folder there are plenty of SDK based demos for you to explore our microcontroller.  We will use one of them to guide you through this tutorial, but definitely take time to try all of them! Select boards>lpcxpresso54608>demo_apps>touch_cursor>iar>touch_cursor Once the workspace is loaded, you will see the project files on the left.  Along the toolbar the first highlighted item is 'Build' select it. Once your console shows no errors you can select the 'Download and Debug' a few icons to the right of 'Build' Your debug session will start and will look like the following window.  Once it opens 'touch_cursor.c' and has a green arrow next to the main function you can select 'Go' After you have successfully flashed the board with this demo you will see the following on your board. This demo utilizes the touch interface on the screen to read where you are touching and updates the cursor position to the last known location.   Remember that other demos and sample code are provided in the root folder of the SDK download.   Be sure to explore these demos and reach out on the community if you need help!
View full article
Hello Community! This document is provided as a hands-on lab guide.  The intent of the lab is to demonstrate how to program the LPCXpresso804 board with the MCUXpresso IDE making use of the SDK examples and the PLU module drivers. The PLU configuration tool will be used to create a new schematic design that will be programmed to the PLU. Setup The following items need to be installed on your computer to complete the lab: Software: •    SDK_2.4.1_LPCXpresso804: -    Copy link into browser: https://mcuxpresso.nxp.com/en/select?device=LPCXpresso804 -    Select ‘MCUXpresso IDE’ or ‘All Toolchains’ in the Toolchain IDE drop-down -    Select ‘Download SDK’ •    MCUXpresso IDE version 10.2.1: -    Can be installed at following link: https://www.nxp.com/mcuxpresso/ide •    PLU configuration tool -    Can be installed at this link: https://www.nxp.com/products/processors-and-microcontrollers/arm-based-processors-and-mcus/i.mx-applications-processors/i.mx-rt-series/i.mx-rt1060-crossover-processor-with-arm-cortex-m7-core:i.MX-RT1060?tab=Design_Tools_Tab   Hardware: •    LPCXpresso804 Development Board (OM40001): https://www.nxp.com/support/developer-resources/evaluation-and-development-boards/lpcxpresso-boards/lpcxpresso804-for-the-lpc804-family-of-mcus:OM40001?tab=Design_Tools_Tab •    PLU Shield Board •    1 Micro USB cable Hope this guide is helpful! Any comments are welcome. Best Regards, Carlos Mendoza Technical Support Engineer
View full article
I already have several customers met SB file loading error Inject command 'receive-sb-file' while working on LPC55S6xx 1B version. There is significant change of Secure Boot in LPC55S6xx 1B version and 0A version. To solve this problem, we need to understand it first.     1  SB2.1  vs. SB2.0 SB2 container is described in elftosb User’s Guide. SB file config file contains configuration commands that will be processed after SB2 file is loaded in the device. The image location is stated in the "sources" .bd file section. SB key in text file is used for encryption with elftosb command line tool.   The 0A version of the LPC55S6xx silicon supports version 2.0 of the SB image format. The 1B version of the LPC55S6xx silicon supports version 2.1 of the SB image format. The main difference between version 2.0 and version 2.1 is in the usage of the digital signature. SB 2.0 is encrypted and SB2.1 is encrypted + signed.     2. SB file Preparation and Usage   Example of use (Encrypted SB2):   elftosb -f lpc55xx -k "sbkek.txt" -c "commandFile.bd" -o "output.sb2" "input.bin"   where -f = family lpc55xx -k = path to KEK file (SBKEK) -c = path to command file to be processed:   options { flags = 0x4; // 0x8 encrypted + signed, 0x4 encrypted buildNumber = 0x1; productVersion = "1.00.00"; componentVersion = "1.00.00"; } sources { inputFile = extern(0); } section (0) {       erase 0x0..0x40000; load inputFile > 0x0; }   -o = path to output file   files... = path to files (usually image files), which will be replacing placeholders defined in command file, paths can be hardcoded in command file and then not inserted as input   Example of use (Encrypted + Signed SB):   1 root key   elftosb.exe -f lpc55xx -k "sbkek.txt" -c "commandFile.bd" -o "output.sb2" -s "selfsign_privatekey_rsa2048.pem" -S "selfsign_v3.der.crt" -R "selfsign_v3.der.crt" -h "RKTH.bin" "input.bin"   4 root keys   elftosb.exe  -f lpc55xx -k "sbkek.txt" -c "commandFile.bd" -o "output.sb2" -s private_key_1_2048.pem -S certificate_1_2048.der.crt -R certificate_1_2048.der.crt -R certificate_2_2048.der.crt -R certificate_3_2048.der.crt -R certificate_4_2048.der.crt -h "RHKT.bin" "input.bin"   where -f = family lpc55xx -k = path to KEK file (SBKEK) c = path to command file to be processed   options { flags = 0x8; // 0x8 encrypted + signed, 0x4 encrypted buildNumber = 0x1; productVersion = "1.00.00"; componentVersion = "1.00.00"; } sources { inputFile = extern(0); } section (0) {       erase 0x0..0x40000; load inputFile > 0x0; }   -o = path to output file -s = path to private key of certificate used for signing -S = path(s) to certificates in certificate chain, each certificate in chain must be specified with new -S switch in order of how was chain created (root certificate first) -R = path(s) to root certificate(s), 1-4 root certificates can be specified, each root certificate must be specified with new -R switch, one of the root certificates must be first certificate specified by -S switch -h = path and name of output binary file generated by elftosb, which contain hash of hashes of all root certificates (RKTH), which must be uploaded to the device register files... = path to files (usually image files), which will be replacing placeholders defined in command file, paths can be hardcoded in command file and then not inserted as input The SB2.0 file created with the updated binary image can be loaded into the device through ISP command handler with command “receive-sb-file“   blhost -p COMxx receive-sb-file <path to the secured binary(.sb2)>   The SB2.1 file created with the updated binary image can be loaded into the device through ISP command handler with command “receive-sb-file“ but keep in mind that before sending SB2.1 file into device has to be there already RKTH in CMPA (see AN12283 chapter 5.5 CMPA preparation) and enabled RoT keys in ROTKH_REVOKE field at CFPA page address 0x9DE18 (see chapter AN12283 5.4 CFPA preparation).   blhost -p COMxx receive-sb-file <path to the secured binary(.sb2)>   After successfully loading the SB2 file it is executed as configured in SB configuration file (.bd file). The above figure shows an example of SB configuration file. When the file is executed, the internal flash address from 0x0 to 0x40000 is erased. After flash erase operation, the image mentioned in the sources parameter is loaded to address 0x0. Reset the device after these operations. The updated image loaded into internal flash starts to execute.    English and Chinese versions of this article are both attached.
View full article
The LPC800 series is a 32-bit, Arm® Cortex®-M0+-based MCU portfolio offering a range of low-power, space efficient, low-pin-count options for basic microcontroller applications. Unique among low-end devices, the LPC800 series MCUs include differentiated product features, such as an NFC communication interface, programmable logical unit (PLU), mutual capacitive touch, switch matrix for flexible configuration, patent-approved SCTimer/PWM, and more – including a comprehensive enablement offering to help you get to market faster. LPC80x 15 MHz|Arm Cortex-M0+|32-bit Microcontrollers (MCUs)|NXP  Webinar series are now available for on-demand viewing, you can get access to the webinars by clicking on the following links:   (5/31) Part I: Thinking about migrating from 8-bit? Wait no longer - LPC80x MCUs are your 32-bit answer! Learn more about the LPC80x MCU family, discover the features, target applications, tools, software and how to get started right away with your 32-bit design.   (6/07) Part II: Creative ways to leverage the LPC804 MCU’s integrated programmable logic feature Continuing its history of innovation in MCUs, NXP introduces a programmable logic unit (PLU) to the LPC family for the first time with the LPC804 MCU. We'll show you how easy it is set up the PLU as we will explore several real-world examples of the challenges many face, but can be overcome with this unique feature.   (6/14) Part III: Get started fast with this comprehensive enablement offering for LPC800 MCUs In May 2018, NXP expanded the MCUXpresso suite of software and tools to include full support for the LPC800 MCU family. Learn about the MCUXpresso IDE, configuration tools and SDK support that is now available for the most cost-effective and compelling family of Arm-based 8-bit replacement microcontrollers available.   (6/21) Part IV: Got NFC? LPC8N04 does - Learn how to leverage this unique feature in your next design? Learn more about the LPC8N04 MCU, its features, and how to get started with NFC quickly by leveraging the available development   Presentations for the webinars are also available now!
View full article
[中文翻译版] 见附件   原文链接: https://community.nxp.com/community/general-purpose-mcus/lpc/blog/2019/05/05/trustzone-with-armv8-m-and-the-nxp-lpc55s69-evk
View full article
[中文翻译版] 见附件 原文链接: https://community.nxp.com/docs/DOC-342406
View full article
MCUXpresso Config Tools is now available! You can access it on the following link: Welcome to MCUXpresso | MCUXpresso Config Tools  Overview. MCUXpresso Config Tools provides a set of system configuration tools that help users of all levels with a Kinetis or LPC-based MCU solution. Let it be your guide from first evaluation to production development. High Quality, Comprehensive Enablement - Production-grade, rigorously tested software and tools. - Easy-to-use SDK, IDE and configuration tools. Compatibility Across MCUs - Supports Kinetis, LPC Cortex-M. - Easy migration and scalability between MCUs. Note: i.MX Cortex-M device support coming in 2017 Interoperability Across Tools - Common experience and broader support through fewer, more cohesive software and tools. - Seamless development using SDK, IDE and Config tools together. - SDK and configuration tools also support the large ecosystem of NXP’s partner IDEs. Features. Architecture - CMSIS-CORE compatible - Single driver for each peripheral - Transactional APIs w/ optional DMA support for communication peripherals Integrated RTOS - FreeRTOS, µC/OS-II & -III - RTOS-native driver wrappers Integrated Stacks and Middleware - USB Host, Device and OTG - lwIP, FatFS - Crypto acceleration plus wolfSSL & mbedTLS - SD and eMMC card support Reference Software - Peripheral driver usage examples - Application demos - FreeRTOS usage demos License - BSD 3-clause for startup, drivers, USB stack Toolchains - IAR®, ARM® Keil®, GCC w/ Cmake - + MCUXpresso IDE Quality - Production-grade software - MISRA 2004 compliance - Checked with Coverity® static analysis tools Configuration and development tools.   SDK Builder packages custom SDKs based on user selections of MCU, evaluation board, and optional software components. Pins, Clocks, and Peripheral(1) tools generate initialization C code for custom board support. Project Generator(1) creates new SDK projects  or clones existing ones. Power Estimation tool provides energy and battery-life estimates based on a user’s application model Power Analyzer(1) measures and displays energy consumption data. (1)Coming 2017 Related links: Introducing MCUXpresso SDK v.2 for LPC54xxx Series  Generating a downloadable MCUXpresso SDK v.2 package  How to start with SDK v.2.0 for LPC5411x using LPCXpresso IDE  https://community.nxp.com/docs/DOC-333369   
View full article
This article introduces how to create a custom board MCUXpresso SDK and how to use it, mainly includes three parts: Part1: Generating a Board Support Configuration (.mex) Part2: Create a Custom Board SDK Using the Board SDK Wizard Part3. Using the Custom SDK to Create a New Project   Requirements: MCUXpresso IDE v11.1.1, MCUXpresso SDK for LPC845, LPC845-BRK board. This method works for all NXP mcu which support by MCUXpresso SDK. About detail steps, please refer to attachment. Thanks!
View full article
This content was originally contributed to lpcware.com by Cam Thompson This project is a simple data logging example that takes readings from various sensors, and log the information to a web page. The Cortex-M4 is used to collect and process sample data, and the Cortex-M0 is used to run a web server for supplying data to web clients. This allows data to be viewed on any web browser, including portable devices such as smart phones and tablets. The web data logging example was implemented using the Hitex LPC4300 evaluation board, which has all the necessary components. The LPC43xx has a built-in ethernet controller accessible by either core, and the Hitex evaluation board provides the physical layer. An on-board 128x32 pixel Chip-on-Glass (COG) LCD display, four touch sensors, and several LEDs are used for implementing a simple user interface. The LPC43xx contains a Real-Time Clock (RTC) which is used to record the date and time of data samples.
View full article
This is a quick introduction that shows how to interface a popular GPS module to the LPC845 Breakout Board using the UART drivers from the MCUXpresso SDK. This example reads and parses GPS data from the module when the user button is pressed and outputs the information to a host computer console via the board's VCOM interface.    UART Protocol The UART function uses two TPU channels to provide a 2-wire (TxD and RxD) asynchronous serial interface. One TPU channel is configured to function as the serial transmitter (TxD), and another TPU channel is configured to function as a serial receiver (RxD).    Adafruit Flora Wearable GPS The module used for this example is built around the MTK3339 chipset, a no-nonsense, high-quality GPS module that can track up to 22 satellites on 66 channels, has an excellent high-sensitivity receiver. It can do up to 10 location updates a second for high speed, high sensitivity logging or tracking. Power usage is very low, only 20 mA during navigation. Adafruit took this module and mounted it on one of their super-compact Flora boards, which are very easy to connect up to the LPC845 Breakout:     Figure 1. Flora Wearable GPS.   GPS Module Example NXP provides example packages that include projects to use the principal's peripherals that the board include: ADC, I2C, PWM, USART, Captouch, and SPI.   What we need: LPC845 Breakout Board MCUXpresso IDE V10.3.0 SDK_2.5.0_LPC845 NXP example packages Adafruit Flora Wearable GPS Micro USB cable   Once downloaded, we import the library project into the workspace using the ''Import project(s) from file system... from the Quickstart panel in MCUXpresso IDE:     Figure 2. Import projects   Then browse the examples packages archive file:     Figure 3. Select Example package.   Press next, and see that are a selection of projects to import, in this case, only keep select the LPC845_BoB_GPS how it looks in the picture below:     Figure 4. Select GPS project   Connections Now, with the project already in the workspace is time to set up the connection between the LPC845 Breakout board and the GPS module, as shown in the table below:     Table 1. LPC845 to GPS module.   The Flora module has the signals clearly printed on their silkscreen which really helps .     Figure 5. LPC845 Breakout Board to GPS module connections.   Once the connections are made, its time to build and run the example code, use the build and debug button inside the IDE. Now open a terminal program and connect to the COM port the board enumerated as. Configure the terminal with these settings:  115200 baud rate.   No parity.  8 data bits  1 stop bit   Place the GPS module outside. Once the GPS has located the satellite data, the red LED on the GPS will stop blinking. If you see the LED blinking once a second, it does not yet have a fix! It can take many minutes to get a fix if the module sees any satellites immediately. Once it has a fix, press the user button (K1) to display the GPS data in the serial monitor, which includes the current date and time in UTC. It will also give you your latitude, longitude and approximate altitude with the Serial monitor. Figure 6. GPS Print Out.
View full article
Hello Community! This document is provided as a hands-on lab guide.  The intent of the lab is to demonstrate how to program and use the LPC8N04 development board by using the LPC8N04 board support package demo application and make use of the read, write and energy harvesting capabilities of the NFC tag. Setup The following items are needed to complete the lab: Software: •    LPC8N04 Board Support Package MCUXpresso, can be downloaded at this link: https://www.nxp.com/downloads/en/lab-test-software/LPC8N04-MCUXpresso-BSP.zip •    MCUXpresso IDE version 10.2.1, can be installed from here: https://www.nxp.com/mcuxpresso/ide •    LPC8N04 NFC Demo Android application, can be installed at the link below: https://play.google.com/store/apps/details?id=com.nxp.lpc8nxxnfcdemo   Hardware: •    LPC8N04 Development Board for LPC8N04 MCU (OM40002): https://www.nxp.com/products/processors-and-microcontrollers/arm-based-processors-and-mcus/lpc-cortex-m-mcus/lpc800-series-cortex-m0-plus-mcus/lpc8n04-development-board-for-lpc8n04-mcu:OM40002 •    Android Phone with NFC •    1 Micro USB cable   Hope this guide is helpful! Any comments are welcome.   Best Regards, Carlos Mendoza Technical Support Engineer
View full article
Hello I have worked on Eclipse for developing applications. I am using NXP's  LPC1769 chip. I have made a documentation on setting up an Eclipse environment.Initially I worked on two basic projects i.e. GPIO toggling and Seven segment display. For running any application ,environment setup is is very important. In this documentation, I have mentioned some links and videos which worked for me. For setting up eclipse environment you need to set up tool chains and paths properly otherwise it will show path errors while compiling any project. Hope it would be helpful!
View full article
Introduction Amazon Web Services (AWS) is the world’s most comprehensive and broadly adopted cloud platform, offering over 165 fully-featured services from data centers globally. Millions of customers —including the fastest-growing startups, largest enterprises, and leading government agencies—trust AWS to power their infrastructure, become more agile, and lower costs.This document will take you step-by-step in a simple approach to adding peripherals to your AWS IOT and Alexa skills project. This is in continuation of the demo established in the following link, it is important to have this completed before continuing with this guide: Connecting the LPC55S69 to Amazon Web Services  Prerequisites - LPC55S69-EVK - Mikroe WiFi 10 Click - AWS Account - Alexa Developer Account - MCUXpresso IDE 11.2 - LPC55S69 SDK 2.8.0 Modifying "AWS_REMOTE_CONTROL_WIFI" In this example I will be adding a single-ended ADC peripheral. 1. First, create a separate .c and .h files in my source folder to keep it organized.  2. Initialize your peripheral. This includes your global variables, pins, clocks, interrupt handlers and other necessary peripheral configurations yours may have.  In my new_peripherals.c file, I add the following 2.1 Definitions: 2.2 Global variables: 2.3 Interrupt handler: 2.4 Initialization function: 2.5 Read ADC Function: 3.  Create header file with the two functions that will be used to enable the ADC, make sure to include the "fsl_lpadc"drivers. 4.  Add the ADC pin with pin configuration tool.  4.1 In this example I use PIO0_23 for the ADC0 Channel 0, 5. Add ADC_Init function to the main. 6. Now let's go ahead and modify "remote_control.c". Here we need to build the JSON text that we want updating our Thing's shadow with the ADC value, add the read function, add the variable in the initial shadow document and the keyword for our DeltaJSON. 6.1 First create global variables for the actual state of the ADC interaction and the parsed state. 6.2 Add external function which will read the ADC value. 6.3 Shadows use JSON shadow documents to store and retrieve data. A shadow’s document contains a state property that describes these aspects of the device’s state: desired: Apps specify the desired states of device properties by updating the desired object. reported: Devices report their current state in the reported object. delta: AWS IoT reports differences between the desired and the reported state in the delta object. 6.4 I've added the initial ADC state with a hard-coded 0, so that I can verify my Thing's shadow is initialized with the new information. 6.5 In the "void processShadowDeltaJSON(char *json, uint32_t jsonLength)" function, we need to add the condition for the change in state of the ADC. This will helps us identify when the action to read the ADC is requested. 6.6 Finally in the "prvShadowMainTask" function, we will create the action based on the above request. We can add some PRINTFs so that we know that the action is requested and processed properly through the serial console. As you may see I only want to update the ADC value when it is requested. Meaning the value of the ADC's state or parsed state is important. We will clear it to zero after we read the ADC and only update the value when it is 1. As opposed to the LEDState and parsedLEDState, where the value is important since it points to which color LED will be on/off. That's it you can build and run the project! Now we can add the Alexa Skill and the functionality in the AWS Lambda. MODIFYING AWS LAMBDA Since the lambda will be the connection between our LPCXpresso board and the Alexa Skill, we need to add the handler for  our new ADC requests. 1.  In this example we add the third request type which is the ADC event and the name of the callback function we will use.  2. The callback function "manage_ADC_request" will contain the attributes for reading and updating the shadow, this will consequently cause the change in delta shadow so our LPC55S69 will read the ADC pin. In addition, the utterances sent to the Alexa skill as well as how we want Alexa to respond will also be defined here.  As you may observe our function builds the JSON payload to update the shadow with a "1" when it is called and ignores the led and accelerometer values. We delay for 2.5 seconds to allow the LPC to read and write the ADC value in the necessary field and send the updated shadow. Then the Lambda will read the shadow and create the return message.  With this we construct the answer for Alexa. MODIFYING ALEXA SKILLS 1.  First create a custom 'intent'. Here is the general definition of what the utterances will be to request an action from the AWS Thing.    1.1 The name needs to match the name used for the event in the Lambda. In this example it is ADC_INTENT 2. Before we create the utterances, let's create the slot types. This is the list of all the words possible that may come to mind that a user might say to request a reading from the ADC.  2.1 The name of the slot type is not crucial, however please note it as we will need it later.  2.2 Add slot values. You can add as many as you think are necessary. For recommendations on custom slot values please check, best practices for sample utterances. 2.3 Go back to the general view of the ADC_INTENT, scroll down and we will add how the slot will be included in the utterances. In this example I use adc_name, however the name here is also not crucial. Select the slot type list we created earlier. 2.4 Now scroll back up and lets begin adding the sample utterances. This can be any command that you believe a user can say to invoke this action. You do not need to include the wake word here. In brackets add the name of your intent slot, in this case it is {adc_name}. That's it! You can save and rebuild the model. You are now ready to test it. You can do so through the 'Test' tab on the developer's console. In addition if you have an Alexa device or the SLN-ALEXA-IOT, you can test it by speaking with Alexa directly. In your LPCXpresso55S69 you can connect the 3.3V or the 0V to the ADC pin so you can see how the value is returned every request. 
View full article
Introduction FEZ is an open source development platform for beginners. Powered by an ARM processor (LPC2388) and driven by Microsoft's .NET Micro Framework, FEZ is a doorway to the embedded world. From the ground up, we designed FEZ to be extremely easy to learn. From the boards to the brochures, we made sure to explain everything on your journey. Programming is made easy by using Microsoft's Visual Studio and C#. Enabling those unfamiliar with the embedded world to program without having any prior knowledge. To further assist exploration, we've created an eBook providing extensive details and code examples. Not only is this eBook free, the SDK and IDE are also completely free. This overall low-cost starting point opens the opportunity to learn embedded devices to everyone. Key Features Based on Microsoft's .NET Micro Framework Runs on 72MHz NXP ARM processors (LPC2387 and LPC2388) Supports runtime debugging (breakpoints, variable inspection, stepping, etc.) Use Visual Studio 2008 C# Express Edition for development Advanced capabilities like FAT, USB device, and USB host Easily upgrades to hardware such as Embedded Master Open source hardware design files Use existing shields and holder boards Based on the USBizi chipset (ideal for commercial use) FEZ Mini pin-out compatible with BS2 FEZ Domino pin-out compatible with Arduino Developent Environment FEZ development is done using Visual Studio 2008 C# Express Edition. You're now able to use the same powerful IDE used by PC developers. The benefits of managed C# programming include reducing programming errors significantly and automatically managing system resources. From the code IntelliSense and included peripheral libraries to deploying and debugging applications. These tools are not only the most advanced, they are all free. As you type, IntelliSense gives you the appropriate methods and properties. Stepping through the code on-device allows you to debug problems efficiently. Hardware FEZ comes in two models: FEZ Domino and FEZ Mini. Both include libraries that contain the FAT file system, threading, UART, SPI, I 2 C, GPIO, PWM, ADC, DAC, and many more. Two kits are also available: the starter kit and the robot kit. We also offer a multitude of peripherals for these boards such as Bluetooth, LEDs, buttons, light sensors, and thermometers, to name a few. FEZ Domino FEZ Mini Software Microsoft's .NET Micro Framework is a lightweight implementation of the .NET Framework. It focuses on the specific requirements of resource-constrained embedded systems. Supporting development in C# and debugging on an emulator or the device, both using Visual Studio. The .NET Micro Framework is also open source, released under the Apache 2.0 license and completely free. Developers already experienced with .NET and Visual Studio can take advantage of their skills immediately, reducing the learning curve. The actual C# application development process is completely shielded from the low-level design details of the hardware platform. Combining the benefits with off-the-shelf, low-cost, network-enabled embedded systems creates a rapid product development solution. More Information FEZ Partners Links TinyCLR Brochure TinyCLR Ebook Reference TinyCLR Tutorial Microsoft .NET Micro Framework Blog Wikipedia Fez (hat
View full article
[中文翻译版] 见附件   原文链接: https://community.nxp.com/community/mcuxpresso/mcuxpresso-ide/blog/2019/02/26/lpc55xx-multicore-applications-with-mcuxpresso-ide
View full article