EE 478 Final Project

Post on 31-Dec-2015

15 views 0 download

Tags:

description

EE 478 Final Project. 49-key MIDI keyboard. Jonathan Feucht, Whitney James. Introduction. 49-key touch insensitive keyboard Utilizes the ATSAM2195 Low-power Single Chip Synthesizer with Effects Adjustable settings using an LCD 16×2 character Crystalfontz CFA-533 display. Introduction. - PowerPoint PPT Presentation

Transcript of EE 478 Final Project

EE 478 Final Project

49-key MIDI keyboard

Jonathan Feucht, Whitney James

Introduction

49-key touch insensitive keyboard Utilizes the ATSAM2195 Low-power

Single Chip Synthesizer with Effects Adjustable settings using an LCD 16×2

character Crystalfontz CFA-533 display

Introduction

Topics covered in this presentation: Project description Design specification Hardware / Software implementation Design procedure Challenges encountered Design improvement ideas

Design requirements

Low key latency (< 800 µs) USB or battery powered (< 2.5 Watts total) Adjustable volume, reverb, chorus levels Adjustable reverb / chorus types Pitch-bend mode Transposition Selection of 100+ instrument sounds 3.3 V 150 mA supply for keyboard controller / Atmel

synthesizer chip 5 V supply for LCD screen, audio amp, and

speakers.

Design requirements

Communication protocols Parallel communication with

ATSAM2195 chip I²C communication between Keyboard

controller and LCD driver LCD menu master Keyboard controller slave

RS-232 communication with LCD screen

Hardware implementation

Keyboard controllerPIC18LF4525

(I²C Slave)

78

I²C

SynthesizerATSAM2195 Speaker

Audio Amplifier

49 Keys, organized as button matrix with 7 columns, 8 rows

User InterfaceATMEGA328(I²C Master)

LCD / Keypad Module

CFA-533RS232

Row dataColumn selector

8Parallel MIDI

Pitch Bend Optoelectronic Device

2Y0A21

Hardware implementation

Crystalfontz CFA-533 LCD 16×2 character Uses 19200 RS-232 6 navigation buttons

Hardware implementation

User front end - Seeeduino 16 MHz ATMEGA328P Controls LCD display EEPROM used for saving settings after

powerdown I2C Master

Hardware implementation

ATSAM2195 Atmel synthesizer chip QFN-44 package with ground plane

Measures 0.7×0.7×0.2 cm3

Hardware implementation

Operates 3.3 V supply 2.2 Vpp analog output signal Configured in parallel implementation

Hardware implementation

Amplifier stage for driving on-board speakers:

Software implementation

Crystalfontz CFA533 driver Data sent out and received in

“packets” Command Data length Data CRC checksum

For every command sent out, return packet is sent back

Software implementation

Buttons used for navigating tree-style menu Left: Follow to parent menu Right: Follow to child menu Up: Navigate up the menu list Down: Navigate down the menu list Okay: If selectable, execute command or select

setting; otherwise, navigate to child menu Cancel: Go to main menu

Software implementation

Button polling Command is issued to display to return

states of buttons Return packet is 3 bytes, indicating:

Buttons pressed down since last poll Buttons released since last poll Buttons currently being held down

Data ended up being NOISY Filtered data by debouncing keys Adjusted for smooth menu navigation

Software implementation

Software implementation

Tree menu Implemented as tree of menu nodes Used for modifying all keyboard settings Each menu node consists of a complex

data structure Each node has pointers to parent node,

and an array of pointers to children nodes

Menu node data structure:

Software implementation

Software implementation

I2C Arduino / Pic communication Synchronization on boot-up Arduino sends settings to PIC using 2

bytes of data After sending setting, Pic sends

acknowledge code back

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Design procedure

Results

Results

Measurements Key polling: Max 250 µs I2C setting transfer: 179 ms Power consumption: 1.2 Watts

Keyboard controller / synth chip: 0.216 Watts Speakers / audio amplifier: 0.200 Watts LCD display: 0.505 Watts Seeeduino board: 0.279 Watts

Challenges encountered

Reflow soldering for QFN-44 package Procedure Testing

3.3 V vs. 5 V Using program memory for menu drivers ATSAM2195 initialization LCD driver communication Frustrations with Arduino environment

No μs delays Arduino environment I²C drivers would not trigger

interrupts on the PIC during reads

Project status

Working as is Planning to add more features;

perhaps include second instrument package, enable drum patch, or something else.

Ideas for improvement

More keys!!! More features Free up pins on the

keyboard controller Touch-sensitive key

action Incorporate

everything on only one microcontroller

Conclusion

We successfully implemented a prototype for a keyboard instrument for midgets

Still has room for more features and creativity

Our project is way cooler than Torin, Daniel, and Russell’s project

DEMO