Senior Embedded Software Engineer with over 40 years programming experience, 20 years at the embedded level. 10 years in the US Army as a meteorologist while slowly moving toward programming. Experience in communications, OCR, graphics, and device drivers. Wrote a complete GUI from scratch and named it Caramel. Why Caramel? Because it's GUI...
This is the first blog of a number dealing with the NXP LPC17xx/40xx processor families and how to program them despite the lack of documentation. The next blog will deal with implementing the LPC17xx/40xx UART with interrupts properly, and a subsequent blog will show how to use the UART in RS485 Normal Multidrop Mode (NMM) with Auto Address Detection (AAD).
My company has decided on using the NXP LPC17xx/40xx processor line for all our embedded projects. Since...
Here's a meme I thought up. I took this picture at my daughter's house:And I heard that you can make face masks out of coffee filters. I sewed two filters together...
Ha ha! I love it! The smell detector is great!A suggestion for the next installment is to fix the lighting. The background is very bright because of the sun...
I'm an 8051 programmer but I haven't done any 8051 stuff for a few years. I welcome mik3ca's posts because they give me a chance to keep my 8051 skills sharp. ...
If you're just working with 16-bit numbers, you can eliminate the 1,000,000 and 100,000 from the table and drop down to two bytes. You can also eliminate the 1...
You could try counting the number of times you can subtract 10000, 1000, 100, and 10 from the original number. You'd need a table containing the values 10000,...
I can see only one place to save a couple of clock cycles. In txdf, you can replace the sjmp notxe2 with mov PSW,SPSW; reti, saving the 2 clocks for the jump. ...
I scraped the internet and found a discussion at http://www.8051projects.net/t9247/general-help-gui... where a zip file containing a number of 8051 math functions...
If you have access to the RTOS source code, make sure you read it through and become familiar with the code and structures. Inevitably, there will come a time...
Your comment about IAR being generally slow and crashing often really hits home. We're currently frozen at EWARM (Embedded Workbench for ARM processors) version...
A few years back we transitioned from 8051 assembler to 32-bit ARM processors. Since I had previous experience with IAR, I suggested that my company choose them,...
First, a definition of "volatile" is needed. A volatile variable is one that can change unexpectedly. Consequently, the compiler can make no assumptions about the...
A major problem with code is readability. Here's an example using Booleans, but this could apply to many other areas. Even the best coders with well commented...
One important consideration for a boot loader is if it needs to update itself, not just the application. If this is required, there are a number of ways to do...
There's "Embedded C Coding Standard" by Netrino (now the Barr Group), although I wouldn't consider it a standard like MISRA-C. But it helps eliminate bugs by defining...
Proper documentation for the part is very important. We use the NXP LPC1788 which is a great processor with lots of functionality, but the user manual for the...
Maybe your login session timed out? I think that happened to me once. I tend to not trust websites so I'll select and copy everything I wrote before clicking...
I suggest you start with "Embedded C Coding Standard" by Michael Barr. It's available in HTML or PDF for free here: https://barrgroup.com/Embedded-Systems/Books/Embed...It's...
There are various factors that can affect instruction timing. Some are shown in the list below:Interrupts (the biggest offender)If interrupts are enabled, an interrupt...
The NXP LPC17xx/40xx series processors have a unique 128-bit ID. It's different on every processor chip. I use it to generate a unique USB ID so that multiple...
I've been there too. I had a software engineer under me that put doubles in interrupts and even tried to do SPI transactions in an interrupt. Fortunately he...
Below is my code for setting the baud rate, which resides between the interrupt save-and-disable and enable code. This is the (modified) output from my compiler...
I'm not familiar with the LPC2214 but I do work with the LPC17xx/LPC40xx series so I'll give you my 2 cents based on that. NXP likes to reuse functionality across...
I've looked over your code as well as the FatFs source code and I can't find anything that stands out. So most likely there's a bug somewhere in the code you wrote...
I'm looking at the FatFs source code and f_close calls f_sync prior to actually closing the file. So I can't see why it isn't working. Could you post a code...
If FatFs worked and petit FatFs didn't, that may point to a bug of some sort in petit FatFs. Can you use FatFs instead? It has a small footprint as well, if...
"Global static"? That doesn't make sense. The variable can be either global (accessible by all modules) or static (accessible by the module it resides in). It...
On the Petit FAT File System page (http://elm-chan.org/fsw/ff/pf/appnote.html) I see: "_FS_FAT16 is 1. _FS_FAT12, _FS_FAT32 and _USE_LCC are 0." Since you're...
The GPIO interrupts are shared with External Interrupt 3 (EINT3) in the LPC175x/6x family, but has its own interrupt in the LPC177x/8x family. Perhaps the OP is...
I have a complete LPC17xx/40xx library that I wrote, so I'm posting the links to the GPIO module. You may find the information useful. The module has the following...
Use this form to contact jorick
Before you can contact a member of the *Related Sites: