Skip to content

GameWeaver/Tornado

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tornado

OP-1 Controls an effect on the iPad

Overview

  1. What is it?
  2. Video
  3. How the Tornado effect was made
  4. Running the code
  5. CoreMidi
  6. Communications
  7. Minimum Requirements
  8. Optional Requirements
  9. Questions and Answers
  10. Links
  11. Things I'd like to know
  12. Things to change

What is it?

The OP-1 is an amazing synthesizer from Teenage Engineering. One of the cool things about it are the effects, like NITRO(My Favourite), DELAY, GRID, PHONE, PUCH and SPRING. They all have a unique user interface, and I wanted to make my own for iOS, controlled by the OP-1.

Video

Vimeo link: https://vimeo.com/60339682

How the Tornado effect was made

The tornado swirls are created by calculating a bezier in 2d space, top-down. This 2d space is then rotated approximately 70 degrees on the x-axis. After rotation, I use CGPointApplyAffineTransform to work out the 2d CGPoint from the 3D rotation, I then draw the bezier using these points.

Running the code

This line of code searches for and connects to the OP-1

[[MidiManager instance] findAndCreateOP1];

Turn on your OP-1 and go into MIDI mode Shift+Com->Option 2(CTRL)

Make sure the App is completely closed and not running, plug in the cable, then open the app.

If you get: "Accessory Unavailable: The attached accessory uses too much power", you need to restart your iPad, and charge your iPad/OP-1 to 100%. If anyone knows of a cable that can charge and use the camera connection kit at the same time, can they let me know?

CoreMidi

OP-1 Settings - from CoreMidi

I've changed the code so that now it will pick up the OP-1 device automatically

Communications

I tried to use the Redpark cables (DB9 and DB9V) to connect to an iPod Touch 4th Gen, but I just couldn't get it to work. In the end I used a iPad Camera Connection Kit, this ONLY works on an iPad.

Camera Connection Kit

  • OP-1 ->
  • OP-1 (Mini-USB to USB Cable) ->
  • iPad Camera Connection Kit ->
  • iPad 2

Redpark Cable

When using the Redpark cable, this was my setup, it didn't work for me. I think the problem is that, there are too many adapaters.

  • OP-1 ->
  • OP-1 (Mini-USB to USB Cable) ->
  • Female to Female USB Adapter ->
  • USB to Serial Cable ->
  • Female to Female serial adapter ->
  • RedPark Serial to iPhone connector ->
  • iPod Touch 4th Gen

Minimum Requirements

Optional Requirements

  • Redpark cable - www.redpark.com (Again, I couldn't get this to work, if you can get it working, please show me how!)

Questions and Answers

Why didn't you use OpenGL ES?

I don't know how to use it, and I wanted to play with CoreGraphics :-)

Why not draw the bezier in 2d space, then rotate the layer and be done with it?

Well, if you do that, the layer has no-depth and the bezier looks flat, doing it this way, the bezier appears to have depth.

Links

Things I'd like to know

  • Can anyone get the Redpark cable working?
  • Is there a cable that can supply power to the iPad/OP-1 with the camera kit connected?

Things to change

  • Change code to just use just us CALayers.
  • Change frame rate configuration

Releases

No releases published

Packages

No packages published