logo

A single wire broadcast protocol for the plug and play of sensors, actuators, and microcontrollers.

Authors: J. Devine, M. Moskal, P. Halleux, T. Ball, S. Hodges, J. Finney, T. Seyed

WARNING: JACDAC is very much still under development and subject to change. If you would like to contribute features and ideas, please visit the github repository and file an issue.

What is JACDAC?

JACDAC (Joint Asynchronous Communications; Device Agnostic Control) is a single wire broadcast protocol for the plug and play of sensors, actuators, and microcontrollers (MCUs) for use within the contexts of rapid prototyping, making, and computer science education. JACDAC operates in a bus topology and requires devices have a microcontroller with UART, Timer, and GPIO interrupt capabilities.

Read the full specification.

JACDAC in action

Gaming

Physical Computing

"Meow Meow Chain" (4 meow meows), thanks to JACDAC c.c: @pelikhan @MSMakeCode pic.twitter.com/SZRVprkhg9

— πŸ›°οΈ Sabas.uf2πŸš€ @ The Inventors House (@Sabasacustico) December 27, 2018

Debugging

Modern debugging over WebUSB.

Motivation

The popularity of the maker movement has lead to a diverse set of applications, and an even more diverse set of users of microcontroller boards. These boards are now used by novices to monitor and actuate our environments (the Internet of Things), to prototype new products for consumers, to enhance the creations of hobbyist-makers, and even to educate children on the fundamentals of computer science.

Microcontroller-boards are as diverse as their users: boards come in many shapes and sizes, can feature sensors, and even feature different communication protocols. Whatever the board, users will want to enhance their chosen microcontroller-board with additional functionality. Realising this, electronics manufacturers are producing external peripheral boards that are compatible with existing popular microcontroller-boards.

Widely used and highly efficient, I2C and SPI are the wired protocols of choice when connecting onboard sensors to microcontrollers. Since these protocols are supported as standard by many microcontrollers, they are now the defacto way of connecting external peripheral boards to microcontrollers too. Limitations in the I2C and SPI protocols affect users in subtle but major ways:

  1. Assumes a Central-Peripheral paradigm –– I2C and SPI both assume that there is a Central microcontroller responsible for reading, writing and configuring a number of peripheral devices; For applications like local networking of microcontrollers, microcontroller to microcontroller communications are required. multi-Central operation is not well-supported. If the networking of two Central devices is required, novice users have to create a custom protocol using UART or use a different communication medium. Limiting of potential applications

  2. Static addressing –– In I2C, each peripheral has an address which is shared with peripherals of the same make (i.e. all MMA8653 accelerometers will have the same address), and in some cases, shared across different types of peripheral. If two peripherals with the same address are connected to the microcontroller its unclear which peripheral should respond.

  3. Static configuration –– The programming interface provided by I2C and SPI is low-level, using addresses and registers to communicate with peripherals. Each I2C or SPI component has its own register layout that is chip specific–each different model of accelerometer will have a different register map. Therefore, a user cannot swap a different accelerometer accessory without reprogramming the Central microcontroller plug and play.

  4. Difficult to wire –– Connecting four wires is simple if you are competent with basic electronics and are not easily distracted, however, in the classrooms of educators both concentration and knowledge of basic electronics are lacking: it is very easy for children (and adults) to destroy peripherals through incorrect wiring.

  5. Debugging requires specialist equipment –– When debugging I2C or SPI a logic analyser is required. A logic analyser enables the user to determine if the values and data format transmitted on the bus are correct, but these tools are complex and requires a fundamental understanding of the protocol for which they are designed.

Aside from the impacts on usability we extend the following observation: with the wide-adoption of web technologies and the huge growth in the Internet of Things (IoT) the worlds of the feature rich and highly capable modern microcontroller and the Internet should be closer together, yet they are not.

We present JACDAC (Joint Asynchronous Communications, Device Agnostic Control): a single wire, multi-Central, broadcast protocol for the plug and play of microcontroller-based devices. JACDAC requires no additional hardware by reusing peripherals common to nearly all microcontrollers: UART, GPIO and a Timer. It abstracts hardware as a set of reusable high-level services (rather than low-level registers and addresses) that can be shared with other connected devices and uses dynamic addressing so that multiple of the same device can be connected simultaneously. It (non-exclusively) operates over 3.5mm audio jack for easy wiring for novices. JACDAC embraces the world of the microcontroller and modern Web technologies by utilising Web USB allowing users to debug and prototype JACDAC services entirely from a webpage.

Repositories