ee 478 final project

44
EE 478 Final Project 49-key MIDI keyboard Jonathan Feucht, Whitney James

Upload: kelsie-love

Post on 31-Dec-2015

17 views

Category:

Documents


0 download

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

Page 1: EE 478 Final Project

EE 478 Final Project

49-key MIDI keyboard

Jonathan Feucht, Whitney James

Page 2: EE 478 Final Project

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

Page 3: EE 478 Final Project

Introduction

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

Page 4: EE 478 Final Project

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.

Page 5: EE 478 Final Project

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

Page 6: EE 478 Final Project

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

Page 7: EE 478 Final Project

Hardware implementation

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

Page 8: EE 478 Final Project

Hardware implementation

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

powerdown I2C Master

Page 9: EE 478 Final Project

Hardware implementation

ATSAM2195 Atmel synthesizer chip QFN-44 package with ground plane

Measures 0.7×0.7×0.2 cm3

Page 10: EE 478 Final Project

Hardware implementation

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

Page 11: EE 478 Final Project

Hardware implementation

Amplifier stage for driving on-board speakers:

Page 12: EE 478 Final Project

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

Page 13: EE 478 Final Project

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

Page 14: EE 478 Final Project

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

Page 15: EE 478 Final Project

Software implementation

Page 16: EE 478 Final Project

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

Page 17: EE 478 Final Project

Menu node data structure:

Page 18: EE 478 Final Project

Software implementation

Page 19: EE 478 Final Project

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

Page 20: EE 478 Final Project

Design procedure

Page 21: EE 478 Final Project

Design procedure

Page 22: EE 478 Final Project

Design procedure

Page 23: EE 478 Final Project

Design procedure

Page 24: EE 478 Final Project

Design procedure

Page 25: EE 478 Final Project

Design procedure

Page 26: EE 478 Final Project

Design procedure

Page 27: EE 478 Final Project

Design procedure

Page 28: EE 478 Final Project

Design procedure

Page 29: EE 478 Final Project

Design procedure

Page 30: EE 478 Final Project

Design procedure

Page 31: EE 478 Final Project

Design procedure

Page 32: EE 478 Final Project

Design procedure

Page 33: EE 478 Final Project

Design procedure

Page 34: EE 478 Final Project

Design procedure

Page 35: EE 478 Final Project

Design procedure

Page 36: EE 478 Final Project

Design procedure

Page 37: EE 478 Final Project

Design procedure

Page 38: EE 478 Final Project

Results

Page 39: EE 478 Final Project

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

Page 40: EE 478 Final Project

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

Page 41: EE 478 Final Project

Project status

Working as is Planning to add more features;

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

Page 42: EE 478 Final Project

Ideas for improvement

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

keyboard controller Touch-sensitive key

action Incorporate

everything on only one microcontroller

Page 43: EE 478 Final Project

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

Page 44: EE 478 Final Project

DEMO