GithubHelp home page GithubHelp logo

godbless876 / keyboard Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ast/keyboard

0.0 0.0 0.0 54 KB

Teensy (Arduino clone) 88 key velocity sensitive midi keyboard

License: MIT License

C++ 82.17% Objective-C 17.83%

keyboard's Introduction

Update 2017-10-14

I can't believe it's already been four years since I published this!

This repo has generated considerable interest and I regularly receive email about it. However, I do not longer actively work on this project. I'm not able to help you with your keyboard project.

I have stopped using the Teensy for my keyboard and switched to the ucapps project. Might publish something about that in the future.

Other keyboard project that I know about

These might be helpful.

Arduino clone midi keyboard

A Teensy (Arduino clone) powered velocity sensitive USB MIDI keyboard with sustain pedal. Works with diode matrix keybeds. I used one from Fatar (also known as Studiologic).

Using the teensy USB MIDI library it works as a class compliant USB MIDI device.

I have only included the source and a very basic schematic here. Feel free to contact me if you have any questions.

Circuit

As you can see on the keyboard matrix schematic, the 88 keys are arranged in to two diode matrices. There are actually 176 switches in the matrix. The reason for this is that there are two switches under each key. When a key is pressed, one of the switches closes slightly before the other one. By measuring the time of flight between the switches we can derive the velocity.

I've included a rudimentary schematic how I use 3 74ls138 demultiplexers to address the rows. With this arrangement I use 8 + 5 pins to scan the keybed.

TODO / Bugs

This is a bit of a hack but it works quite well for now.

If you have any insights to these questions please let me know!

  • Is a scanning frequency of 1000Hz too low? I've heard somewhere commercial keyboard use 2000Hz. Perhaps someone can measure one with a scope?
  • Right now the velocity response is linear and quite low resolution. What is a good velocity response curve?
  • Is it a bad idea to join the two matrices? Perhaps it's a better idea to use a separate micro controller for each matrix and let them talk together using i2c? This approach would be more modular and allow for stacking a lot of keys (in an organ i.e..)
  • I'm using the Teensy USB MIDI library. I'm not sure how this interferes with the timing of the scanning interrupt routine.

Resources

keyboard's People

Contributors

ast avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.