Using the HC-06 Bluetooth Module

After my first post using a Bluetooth module, things have evolved a bit. The challenge with these Bluetooth modules is: they look the same, but having different firmware. I did not fully realize that until I have ordered another bluetooth module from dx.com:

DX.com Bluetooth Module (HC-06)

DX.com Bluetooth Module (HC-06)

That module comes already on a carrier, so I assumed I can use the same driver as for my other module. I was wrong :-(.

Continue reading

Tutorial: Arduino Motor/Stepper/Servo Shield – Part 3: 74HCT595 Shift Register

For many projects, I have one common problem: I run out of I/O pins on my microcontroller :-(. Luckily, I’m not alone, and the industry has created solutions for this kind of problems. One is to use a shift register as the 74HCT595/SN74HC595 which gives me 8 extra output pins. All what I need to spend are are 3 GPIO pins. Not a bad deal: I spend 3 pins and I get 8 (or multiple of it) on return :-).

So why do I say this for this Arduino Motor/Stepper/Servo Shield tutorial? I have asked in this earlier post with a poll for the next topic (relais, motor or command line interface). Right now votes are mostly for relay. But before I can do relay (or DC motor), I need to first cover the 74HCT559. So here we go to have you ready for the next tutorial 🙂

Arduino Motor Shield

Arduino Motor Shield with 74HC595

Continue reading

Bricking and Recovering FRDM-KL25Z Boards: Reset, SWD Clock and Low Power

I’m working with a student on building a small autonomous robot platform, based on the FRDM-KL25Z board. We integrated new software modules, compiled and linked, and then downloaded the application to the board. While debugging and stepping through the application startup, I had this:

The Debugger has lost communication on connection

The Debugger has lost communication on connection

Outsch! That’s not good. Even worse, trying to connect again to the board failed :-(. What happened?

Continue reading

Adding Quadrature Encoder to the Zumo Chassis

The Pololu Zumo chassis is nearly perfect for my needs: it is small and compact, and neatly works with the FRDM-KL25Z board. I’m able to use it for line following or maze solving. But it lacks a position (quadrature) encoder on the wheels which is either very useful or even required for the lecture assignments for my next class. The Pololu Zumo chassis mainly has been designed for Robot-Sumo competitions, where such quadrature sensors are not really needed. Pololu offers optical quadrature sensors for their 42×19 mm wheel which I used in this project. So why not adding these sensors to the Zumo chassis?

FRDM-Robot with Quadrature Sensors Mounted

FRDM-Robot with Quadrature Sensors Mounted

Continue reading

FRDM-KL25Z RevE Board arrived

About a year ago I started to use the FRDM-KL25Z board (RevD). Finally, I had it in my hands: the RevE board from Mouser 🙂 Using the RevD board, I faced several problems:

  1. 3.3V supply voltage drop because of low-cost diode D1 (see this post)
  2. Hard to use USB host mode, as no 5V supplied to the USB bus (see this post)
  3. No 5V generated from V_IN (see this post)

The good news: all of them have been improved 🙂 in the FRDM-KL25Z RevE Schematics:

FRDM-KL25Z RevE Board

FRDM-KL25Z RevE Board

Continue reading

Tutorial: Arduino Motor/Stepper/Servo Shield – Part 2: Timed Servo Moves

You have decided: More than 52% voted in Part 1 that the next topic should be Timed Servo Moves. So here we go :-).

This is about how to move the servos over time, instead of moving it to the given position as fast as possible. I’m using a linear approach here: moving the servos linearly over time.

Moving Servo Motors

Moving Servo Motors

Continue reading

Tutorial: Arduino Motor/Stepper/Servo Shield – Part 1: Servos

This post starts a small (or larger?) series of tutorials using the Arduino Motor/Stepper/Servo Shield with the FRDM-KL25Z board. That motor shield is probably one of the most versatile on the market, and features 2 servo and 4 motor connectors for DC or stepper motors. That makes it a great shield for any robotic project :-).

Arduino Motor Stepper Servo Shield with FRDM-KL25Z

Arduino Motor Stepper Servo Shield with FRDM-KL25Z

Continue reading

Character LCD with 4 Lines

Character LCD’s (like 2 lines with 16 characters each) as in this post are easy to use. Much easier to use compared to full graphical LCDs.

The ones I’m using have either 1 or 2 lines, but I saw that there are 4 line displays too. So far my LCD component only supports one or two lines.

4 Line LCD

4 Line LCD (Source: Ezequiel Bazotti)

Continue reading

CMSIS-DAP with IAR and the KL25Z Freedom Board

Beside of USBDM, there is another Open Source implementation of a debug interface for the Freedom Board OpenSDA: CMSIS-DAP.

CMSIS-DAP stands for ‘Cortex Microcontroller Software Interface Standard – Debug Access Port’) has been published by ARM Inc. With this, there is an open source alternative to proprietary implementation (e.g. P&E OpenSDA or Segger OpenSDA).
Beside of the ARM MDK IDE, CMSIS-DAP is supported by Coocox and IAR. And IAR is what I’m using in this post.

Continue reading