## Padé Delay is Okay Today

This article is going to be somewhat different in that I’m not really writing it for the typical embedded systems engineer. Rather it’s kind of a specialized topic, so don’t be surprised if you get bored and move on to something else. That’s fine by me.

Anyway, let’s just jump ahead to the punchline. Here’s a numerical simulation of a step response to a $p=126, q=130$ Padé approximation of a time delay:

Impressed? Maybe you should be. This...

## SIGFOX – A new network technology for IoT comms?

It’s quite likely you've never heard of SIGFOX, or if you have it has been sketchy at best on details. So what is it, and why should you care?

Well, if you have a need for low cost, low power data collection which doesn't involve transferring megabytes of data and doesn't have to be particularly “real-time” e.g. you only need your data say once an hour, or even once a day, then SIGFOX may be just what you are looking for.

SIGFOX has been designed from the ground up as a low...

## Cutting Through the Confusion with ARM Cortex-M Interrupt Priorities

February 26, 2016

The insanely popular ARM Cortex-M processor offers very versatile interrupt priority management, but unfortunately, the multiple priority numbering conventions used in managing the interrupt priorities are often counter-intuitive, inconsistent, and confusing, which can lead to bugs. In this post I attempt to explain the subject and cut through the confusion.

The Inverse Relationship Between Priority Numbers and Urgency of the Interrupts

The most important fact to know is that ARM...

## The New Forum is LIVE!

February 18, 20161 comment

After months of hard word, I am very excited to introduce to you the new forum interface.

Here are the key features:

1- Easily add images to a post by drag & dropping the images in the editor

2- Easily attach files to a post by drag & dropping the files in the editor

3- Add latex equations to a post and they will be rendered with Mathjax (tutorial)

4- Add a code snippet and surround the code with

## Metal detection: building the detector

IntroductionBefore starting, you may want to read this post describing the BFO stage:

//www.embeddedrelated.com/showarticle/911.php

I have detailed the implementation of a BFO stage for detecting metal. Now it has been validated on the bench, the next step is to integrate it in a stand alone instrument for testing on the field. A few things have to be done to reach this goal:

• make a PCB for the electronics,
• house the PCB in a box,
• make a frame to hold...

## Cortex-M Exception Handling (Part 2)

The first part of this article described the conditions for an exception request to be accepted by a Cortex-M processor, mainly concerning the relationship of its priority with respect to the current execution priority. This part will describe instead what happens after an exception request is accepted and becomes active.

PROCESSOR OPERATION AND PRIVILEGE MODE

Before discussing in detail the sequence of actions that occurs within the processor after an exception request...

## Metal detection: beat frequency oscillator

January 30, 20161 comment
Plan Introduction Theory Electronics Software Tests ReferencesNext part: building the detector 1. Introduction

This article discusses the implementation of a beat frequency oscillator (BFO) stage for metal detector. While they are mentioned here and there, the article does not detail other important electronic stages such as the power supply, and user interface, the coil or the detector frame. I may write other articles on these topics, and other detection methods.Before...

## Autonomous vehicle - design questions to ponder

January 27, 2016

When designing an autonomous or remotely-controlled vehicle, there are a few factors to take into consideration. Three of these are purpose, environment, and terrain.

What is the purpose of the vehicle?

Will it be used in an industrial setting with people moving around it that it must not run over?

Will it be used in a hazardous environment, like Fukushima or Chernobyl, where it would be exposed to high levels of radiation and must be cleaned or left behind? If it must be left behind, any...

## Ancient History

The other day I was downloading an IDE for a new (to me) OS.  When I went to compile some sample code, it failed.  I went onto a forum, where I was told "if you read the release notes you'd know that the peripheral libraries are in a legacy download".  Well damn!  Looking back at my previous versions I realized I must have done that and forgotten about it.  Everything changes, and keeping up with it takes time and effort.

When I first started with microprocessors we...

## Steering an autonomous vehicle - two basic ways

January 15, 2016

While there are many types of steering mechanisms, for now, I will be concentrating on two of them.

The first is known as Ackerman-type steering. On a rear-wheel-drive four-wheeled car, the rear wheels push the vehicle while the two front wheels pivot left and right, either by using a servo or a geared motor, to steer the vehicle.  Understeer is when the vehicle tries to push through the turn too wide, possibly causing the vehicle to drive off the outside of the course.   ...

## Reverse engineering wireless wall outlets

July 19, 2014
Introduction

I am improving the domotics framework that I described in a previous article://www.embeddedrelated.com/showarticle/605.php

I want to support wireless wall outlets, allowing me to switch devices power from a remote location over HTTP.

To do so, I could design my own wireless wall outlets and use a hardware similar to the previous one, based on the NRF905 chipset. The problem is that such a product would not be certified, and that would be an issue regarding the home insurance,...

## Mutex vs. Semaphore - Part 1

It never ceases to amaze me how often I see postings in forums asking the difference between a semaphore and a mutex. Probably what baffles me more is that over 90% of the time the responses given are either incorrect or missing the key differences. The most often quoted response is that of the “The Toilet Example (c) Copyright 2005, Niclas Winquist” . This summarises the differences as:

• A mutex is really a semaphore with value 1

No, no, and no again....

## Jaywalking Around the Compiler

Our team had another code review recently. I looked at one of the files, and bolted upright in horror when I saw a function that looked sort of like this:

void some_function(SOMEDATA_T *psomedata) { asm volatile("push CORCON"); CORCON = 0x00E2; do_some_other_stuff(psomedata); asm volatile("pop CORCON"); }

There is a serious bug here — do you see what it is?

## Levitating Globe Teardown, Part 2

Part 1 of this article was really more of an extended (and cynical) product review.  In this part of the article, I actually take things apart (sometimes a bit more suddenly than I meant to) and show you some innards.First the globe.  I knew there was a magnet in there someplace, because it's obviously plastic and it also attracts metal.  I had intended to gently part the globe at the glue bond along the equator.  I started by trying to gently flex the thing on my work...

## How to Give Persistent Names To USB-Serial Devices on Ubuntu 14.04

May 22, 20171 comment

If you have a bunch of USB-serial devices connected to your dock station and you needed to bind your USB-serial devices under static names so that all the USB-serial devices don't get to be assigned to random names by "udev" manager when you re-plug your laptop to the dock station, follow the instructions below. I will share the udev rules I created as a reference and give the step by step instructions to achieve persistent naming. All the steps worked on my Ubuntu 14.04...

## Arduino robotics #2 - chassis, locomotion and power

October 16, 2013
Arduino Robotics

Beginner robotics is a series of article chronicling my first autonomous robot build, Clusterbot.  This build is meant to be affordable, relatively easy and instructive.  The total cost of the build is around \$50.

1. Arduino robotics - motor control2. Arduino robotics - chassis, locomotion and power3. Arduino robotics - wiring, coding and a test run4.

## Lost Secrets of the H-Bridge, Part II: Ripple Current in the DC Link Capacitor

July 28, 2013

In my last post, I talked about ripple current in inductive loads.

One of the assumptions we made was that the DC link was, in fact, a DC voltage source. In reality that's an approximation; no DC voltage source is perfect, and current flow will alter the DC link voltage. To analyze this, we need to go back and look at how much current actually is being drawn from the DC link. Below is an example. This is the same kind of graph as last time, except we added two...

## Stairway to Thévenin

December 31, 2011

This article was inspired by a recent post on reddit asking for help on Thévenin and Norton equivalent circuits.

(With apologies to Mr. Thévenin, the rest of the e's that follow will remain unaccented.)

I still remember my introductory circuits class on the subject, roughly as follows:

(NOTE: Do not get scared of what you see in the rest of this section. We're going to point out the traditional approach for teaching linear equivalent circuits first. If you have...

## Have You Ever Seen an Ideal Op-Amp?

April 30, 2012

Somewhere, along with unicorns and the Loch Ness Monster, lies a small colony of ideal op-amps. Op-amp is short for operational amplifier, and we start our education on them by learning about these mythical beasts, which have the following properties:

• Infinite gain
• Infinite input impedance
• Zero output impedance

And on top of it all, they will do whatever it takes to change their output in order to make their two inputs equal.

But they don't exist. Real op-amps have...