Reliable Bluetooth Comms Between Arduino and MIT App Inventor (AI2)

MIT_AI2_IconI recently needed to develop a Bluetooth application between an Arduino and a controlling App running on Android. App Inventor 2 was used to simplify development of the Android App .

MIT App Inventor (AI2) is a web-based online graphical mobile application development environment for Android devices, where you can create an application by simply dragging and connecting a series of function blocks.

When researching the task, I found a lot of disparate information about how to write the Bluetooth management code for AI2. This information (some good, some wrong, and a lot repetitive) was synthesized it into a set of functions, described here, that provide a reliable communications interface to my project.

Continue reading “Reliable Bluetooth Comms Between Arduino and MIT App Inventor (AI2)”

Advertisements

Simple Debugging for Arduino Sketches

Bug_TrackingDespite the advent of source level debuggers for Arduino code, one of the most accessible ways to debug Arduino projects is still the Serial.print() statement. It is how most beginners will start when trying to debug their code.

But what do you do with all the print() statements sprinkled through the code once your application is working?

Continue reading “Simple Debugging for Arduino Sketches”

Parola A to Z – Multi Zone Displays

Parola_Controlled_ZoneA very powerful feature of the Parola library is the ability to separate a display into a number of zones. This allows the implementation of sophisticated animations schemes and is a key part of being able to create double height displays.

This post explains what they are, how they are set up, and how to manage them.

Continue reading “Parola A to Z – Multi Zone Displays”

Parola A to Z – Adapting for Different Hardware

Parola_ModuleAn ongoing question on many Arduino forums is the adaptation of software to the different types of matrix modules. Usually the poster has tried some LED matrix software and the display is reversed or upside down, or animations are disjointed across the module boundaries.

There are clear reasons this happens, and the Parola library has software configuration parameters that allow you to adapt how the software operates to suit your hardware module.

Continue reading “Parola A to Z – Adapting for Different Hardware”

Parola A to Z – Double Height Displays

parola_dh_single_doubleUsing the Parola library for double height displays is becoming increasingly popular with library users. Setting up the hardware and the library is not difficult, but it can cause problems if not done correctly. This article will explain the hardware and software setup considerations for trouble-free double height displays.

Continue reading “Parola A to Z – Double Height Displays”

Parola A to Z – Managing Animation

azparola_animationAs the main function of the Parola library is to enable text animations, it is important to understand how these are set up and managed to completion from user code.

From a user perspective, Parola animation consist of 3 parts – setting up, running and resetting the animation. The process is not complex and is illustrated in the numerous library examples. This article breaks these down and explains how the Parola class methods apply in each phase.

Continue reading “Parola A to Z – Managing Animation”

Parola A to Z – Text Animation

azparola_animationThe key function of the Parola library is to display text using different animations. These animations are built around a core supporting framework and largely follow the same patterns. This article explores how Parola animations code is constructed so that advanced users of the library have enough information to be able to write (and contribute!) their own new animations.

Continue reading “Parola A to Z – Text Animation”

What is 00101010?

binaryI frequently see see novice programmers asking “how to change variable from hex to binary” or similar questions. Leaving aside the simple number base conversion, these questions are, frustratingly, usually about not understanding fundamental computing concepts.

Continue reading “What is 00101010?”

ATTiny Getting Started and Code Benchmarking

attiny_bo_built-upOnce I had some hardware to test with, the next steps were to work out how to get a program onto the ATTiny and how to write efficient code. As 1kb of flash memory is not much to play with, space efficiency was a likely programming challenge!

Continue reading “ATTiny Getting Started and Code Benchmarking”

ATTiny Breakout Board

attiny_bo_built-upIn some upcoming projects I intend to embed some processing intelligence into small devices. The smaller Arduino boards are too big and expensive for these applications.

After some investigation, I settled on using the ATTiny series of 8 pin microcontrollers. These processors vary in capability (from a very low end) and all provide 6 I/O ports. Tools compatible with the Arduino ecosystem are also available.

As a first step, I designed a small breakout board for the SOP8 version of these MCUs.

Continue reading “ATTiny Breakout Board”