## Is it a Bug or an Error?

Probably you’ve heard the story of how Adm. Grace Hopper attached a moth that was dislodged from a relay in the Harvard Mark II mainframe to an engineering notebook and labeled it the “First actual case of bug being found.”

Designers of electronics, including Thomas Edison, had been using the term bug for decades. But it was mostly after this amusing 1947 event hat the use of words like “bugs” and “debugging” took off in the emerging software realm.

So why is it that if a...

## A Wish for Things That Work

As the end of the year approaches, I become introspective. This year I am frustrated by bad user interfaces in software.

Actually, every year, throughout the year, I am frustrated by bad user interfaces in software. And yet here it is, the end of 2017, and things aren’t getting much better! Argh!

I wrote about this sort of thing a bit back in 2011 (“Complexity in Consumer Electronics Considered Harmful”) but I think it’s time to revisit the topic. So I’m...

## Linear Feedback Shift Registers for the Uninitiated, Part XII: Spread-Spectrum Fundamentals

December 29, 20171 comment

Last time we looked at the use of LFSRs for pseudorandom number generation, or PRNG, and saw two things:

• the use of LFSR state for PRNG has undesirable serial correlation and frequency-domain properties
• the use of single bits of LFSR output has good frequency-domain properties, and its autocorrelation values are so close to zero that they are actually better than a statistically random bit stream

The unusually-good correlation properties...

## Linear Feedback Shift Registers for the Uninitiated, Part XI: Pseudorandom Number Generation

December 20, 2017

Last time we looked at the use of LFSRs in counters and position encoders.

This time we’re going to look at pseudorandom number generation, and why you may — or may not — want to use LFSRs for this purpose.

But first — an aside:

Science Fair 1983

When I was in fourth grade, my father bought a Timex/Sinclair 1000. This was one of several personal computers introduced in 1982, along with the Commodore 64. The...

## Linear Feedback Shift Registers for the Uninitiated, Part X: Counters and Encoders

December 9, 2017

Last time we looked at LFSR output decimation and the computation of trace parity.

Today we are starting to look in detail at some applications of LFSRs, namely counters and encoders.

Counters

I mentioned counters briefly in the article on easy discrete logarithms. The idea here is that the propagation delay in an LFSR is smaller than in a counter, since the logic to compute the next LFSR state is simpler than in an ordinary counter. All you need to construct an LFSR is

## Linear Feedback Shift Registers for the Uninitiated, Part IX: Decimation, Trace Parity, and Cyclotomic Cosets

December 3, 2017

Last time we looked at matrix methods and how they can be used to analyze two important aspects of LFSRs:

• time shifts
• state recovery from LFSR output

In both cases we were able to use a finite field or bitwise approach to arrive at the same result as a matrix-based approach. The matrix approach is more expensive in terms of execution time and memory storage, but in some cases is conceptually simpler.

This article will be covering some concepts that are useful for studying the...

## Linear Feedback Shift Registers for the Uninitiated, Part VIII: Matrix Methods and State Recovery

November 21, 2017

Last time we looked at a dsPIC implementation of LFSR updates. Now we’re going to go back to basics and look at some matrix methods, which is the third approach to represent LFSRs that I mentioned in Part I. And we’re going to explore the problem of converting from LFSR output to LFSR state.

Matrices: Beloved Historical Dregs

Elwyn Berlekamp’s 1966 paper Non-Binary BCH Encoding covers some work on

## Obsolete? Yes. Still in use? Yes. How do you use it? Ummm...

In today's world of constantly changing technology, quick parts availability, and seemingly endless options, some things can't change.  It isn't a big deal to wait a day or less for a computer upgrade to arrive.  It seems program size increases proportionally to hard drive size.  The old is discarded and replaced with the new.  Hard drives can hold terrabytes and even SD cards can hold gigabytes of information.

Now, suppose a system can't be changed.  It is still...

## Linear Feedback Shift Registers for the Uninitiated, Part VII: LFSR Implementations, Idiomatic C, and Compiler Explorer

November 13, 2017

The last four articles were on algorithms used to compute with finite fields and shift registers:

Today we’re going to come back down to earth and show how to implement LFSR updates on a microcontroller. We’ll also talk a little bit about something called “idiomatic C” and a neat online tool for experimenting with the C compiler.

## Lazy Properties in Python Using Descriptors

November 7, 2017

This is a bit of a side tangent from my normal at-least-vaguely-embedded-related articles, but I wanted to share a moment of enlightenment I had recently about descriptors in Python. The easiest way to explain a descriptor is a way to outsource attribute lookup and modification.

Python has a bunch of “magic” methods that are hooks into various object-oriented mechanisms that let you do all sorts of ridiculously clever things. Whether or not they’re a good idea is another...

## Introduction to Microcontrollers - Hello World

Embedded Hello World

A standard first program on an embedded platform is the blinking LED.  Getting an LED to blink demonstrates that you have your toolchain set up correctly, that you are able to download your program code into the μC, and that the μC and associated circuitry (e.g. the power supply) is all working.  It can even give you good evidence as to the clock rate that your microcontroller is running (something that trips up a great many people,...

## Boot Sequence for an ARM based embedded system

Hello all,

Allow me to introduce myself. I am Deeksha and I come from plains of North India. My tryst with embedded technologies has been 5 years long and every single day I am amazed with the vastness and learning involved. The thing with embedded technologies is either you are into it, or you aren't. You cannot just hang around half-heartedly (I guess that holds true for every field, for that matter).You have to keep the learning and sharing process going on. And that is the reason I am...

## Introduction to Microcontrollers - Driving WS2812 RGB LEDs

This tutorial chapter is a bit of a detour, but I think an interesting and useful one.  It introduces a bit of assembly language programming, and demonstrates bit-banging a tight serial data protocol.  And it deals with RGB LEDs, which are just very fun in their own right, especially these new parts.  So I thought I'd post this to give readers time for some holiday lighting experimenting.

Back To The Future

Remember how we started this...

## Important Programming Concepts (Even on Embedded Systems) Part I: Idempotence

There are literally hundreds, if not thousands, of subtle concepts that contribute to high quality software design. Many of them are well-known, and can be found in books or the Internet. I’m going to highlight a few of the ones I think are important and often overlooked.

But first let’s start with a short diversion. I’m going to make a bold statement: unless you’re a novice, there’s at least one thing in computer programming about which you’ve picked up...

## An overview of Linux Boot Process for Embedded Systems

This Text provides an insight in to the Embedded Linux Boot Process. Reader should have a basic Knowledge of Boot Process in general and should be familiar with Embedded Linux Boot Process.

.................PART-A................(1) Software components Involved in Embedded Linux Boot Process    (a) Bootloader    (b) kernel Image    (c) root file system - either an initrd image or a NFS location(2) Steps during Booting process of a conventional...

## VHDL tutorial

When I was first introduced to "Programmable Logic" several years ago, it was an answer to many of the challenges that I was struggling with. Though the parts were primitive by today's standards (simple PALs verses FPGA), they were an extremely cost effective tool addressing the need for specialized logic blocks.

I have continued to incorporate these powerful blocks into many of my latest designs. My current favorite part line is the Xilinx CoolRunner series (XC2Cxxx). In this...

## C++ on microcontrollers 1 - introduction, and an output pin class

This blog series is about the use of C++ for modern microcontrollers. My plan is to show the gradual development of a basic I/O library. I will introduce the object-oriented C++ features that are used step by step, to provide a gentle yet practical introduction into C++ for C programmers.  Reader input is very much appreciated, you might even steer me in the direction you find most interesting.

I am lazy. I am also a programmer. Luckily, being a lazy...

## Introduction to Microcontrollers - Further Beginnings

Embedded Programming Basics

This tutorial entry will discuss some further embedded programming basics that you will need to understand before proceeding on to the LED blinky and other example programs. We will do this by looking at the general organization and types of instructions found in most microcontrollers, and how that organization and those instructions are reflected (or, in some cases, ignored) by the C programming language.

Basic CPU...

## How to Read a Power MOSFET Datasheet

One of my pet peeves is when my fellow engineers misinterpret component datasheets. This happened a few times recently in separate instances, all involving power MOSFETs. So it’s time for me to get on my soapbox. Listen up!

I was going to post an article on how to read component datasheets in general. But MOSFETs are a good place to start, and are a little more specific. I’m not the first person to write something about how to read datasheets; here are some other good...

## VHDL tutorial - A practical example - part 2 - VHDL coding

May 27, 2011

In part 1 of this series we focused on the hardware design, including some of the VHDL definitions of the I/O characteristics of the CPLD part.  In part 2, we will describe the VHDL logic of the CPLD for this design.

With any design, the first step to gather the requirements for the job at hand.  From part 1 of this article, I have copied two sections that address some of the requirements for the CPLD design.

The data acquisition engine has the...

## Recruiting New Bloggers!

Previous calls for bloggers have been very successful in recruiting some great communicators - Rick LyonsJason Sachs, Victor Yurkovsky, Mike Silva, Markus NentwigGene BrenimanStephen Friederichs,

## DSPRelated and EmbeddedRelated now on Facebook & I will be at EE Live!

I have two news to share with you today.

The first one is that I finally created Facebook pages for DSPRelated.com and EmbeddedRelated (DSPRelated page - EmbeddedRelated page). For a long time I didn't feel that this was something that was needed, but it seems that these days more and more people are using their Facebook account to stay updated with their favorite websites. In any event, if you have a Facebook account, I would greatly appreciate if you could use the next 5 seconds to "like"...

## Free Embedded Systems Books

May 28, 2013

Following the success of the Collaborative Writing Experiment: What are your favorite Embedded Systems Online Resources? blog post, let's try a second collaborative writing experiment.  This time, let's work on a file that will list the best embedded systems books that are available online for free.  I am not talking about books that are illegally made available for download by pirates, but books that are made available online by authors and/or publishers.

Do you know of...

## Collaborative Writing Experiment: What are your favorite Embedded Systems Online Resources?

Edit 22/05 - Wow, this went better than expected.  I will try submitting this blog post to Reddit/ece and see if we can get a few more interesting links before I close the document.  Thanks to everyone who contributed!

_______

Edit 28/05 - The document is now closed to editing.  If there is a link that you would like to see added, please use the comment system at the end of this blog.  Thanks to all who participated!

Up next, Free...

## Success Story

A blog post has just broken the all-time record for the number of pageviews in 24 hours on the related sites. The blog post in question is titled Data Hiding in C and was written by Stephen Friederichs.  It has been viewed by more than 7000 individuals since its publication a few days ago.

One reason that explains the success of this blog post is the wide appeal of the subject of the article (c programming) which allowed me to

## Code Snippets Winners Announced

Wow, thanks a lot for all the code snippets - I am pleasantly surprised by the quality of the code that has been shared and I am very grateful.

Now, as you know, to give momentum to the section I had announced a special reward program for code snippets submitted by the end of March.

The partner members and I had a very hard time selecting the 5 "most useful" snippets out of the more than 50 who have been submitted.

Here's our selection:

## Now on Twitter + More Code Snippets Incentives

Better late than never, the three related sites (DSPRelated, FPGARelated and EmbeddedRelated) now have their Twitter accounts.  If you are already on Twitter, please consider following.  I'll make sure to keep the tweets interesting and informative.  Plus, once in a while, I will tweet a link where the first x persons to visit will receive a gift (book, gift certificate, etc).

@DSPRelated