Im fairly new to building stuff with arduino. I want to control pitch and maybe tone sustain from an osc with an usb tablet through max/msp.
I reckon i need to setup the osc with arduino and make max see the tablet as a midi controller. link it all up and get freaky with it.
Could anyone please advice me on this? maybe tell me if this is at all possible!
You can't connect your USB device to the arduino because they are both slaves. You possibly could using a USB host shield but the software that needs to be written for that is probably beyond you.
This is a project that is best done without an arduino's involvement using software on your PC, possibly in the free language called Processing. Getting support for your USB tablet is going to be your problem.
I was not planning on connecting the tablet to the arduino. My idea is using the tablet to control parameters in max msp, sending that to my arduino controlling an osc.
I am having trouble getting max to detect the tablet though..
I think It comes down to making a x/y controller with max and a controller. then i want to output the data from max into the arduino, controlling an oscillator. id like one parameter to control pitch and the other note length. I also wonder if there isnt an onboard oscillator on the mega 2560?
No on board oscillator but there are some timers. However an arduino isn't great at producing quality tones. Shame about the windows.
Would you not be better getting max to do it all?
Yes That would be easier, but the assignment says we have to build or use an external osc.. And this seemed a nice opportunity to get more aquainted with my arduino.
At the moment im also struggling with getting max to detect any HID's that are installed.strangely enough, the help patches or Hi tester dont detect any devices..
However, in a much simpler way, it's possible to get simple square waves, it's just toggling an output pin at the right frequency. This can be done manually, in loops with millis() or delayMicroseconds(), but there are also libraries that can do it automatically, like the tone library, or the tone() function built in to arduino.