• Posts
  • RSS
  • ◂◂RSS
  • Contact

  • Goodbye ChucK; hello straight C with JACK

    May 1st, 2010
    looper, tech, music  [html]
    The chuck-using looper software was being too annoying. I couldn't figure out why latency was being slightly off and variable between runs, I couldn't figure out how to get it to run realtime, and chuck kept crashing when I went to record long loops, giving:
    subgraph starting at RtApiJack timed out (subgraph_wait_fd=9, status = 0, state = Running, pollret = 0 revents = 0x0)
    I decided to have a look at writing this in straight C against the JACK api. Which seems to have worked quite well. It wasn't that much work, and now I know exactly what's going on. Chuck was good for prototyping, and really easy to get started with, but I have a lot more trust in this new version. One downside is that unless OSX has /dev/input/mouse then this is linux only. Which is sad. If there's an easy fast way to get mouse events on OSX I could add it.

    So. This requires at leas the following:

    $ sudo apt-get install jackd libjack-dev
    $ gcc -std=c99 -o looper_sync -ljack -lpthread -lrt looper_sync.c
    $ sudo chmod ugo+r /dev/input/mouse*
    $ jackd -d alsa -p 256 &
    $ ./looper_sync
    Unfortunately, while I was testing this one last time before writing it up, I managed to get the exact same "subgraph timed out" error in the C version that I'd gotten in the chuck version. I don't get it as easily in the new version; sometimes I can record three full length loops and not get it. Perhaps, though, this error means I'm trying to do too much work on one processing cycle? I need to look at it more. On my desktop it runs great, so I'm thinking it has to do with the eeepc being substantially less powerful.

    Comment via: facebook

    Recent posts on blogs I like:

    The Limit of Circles in the Suburbs

    In dense urban cores, it’s valuable to run circular rail lines. They connect dense near-center neighborhoods to one another without going through the more congested center, and help make transferring between parallel lines more efficient, again through av…

    via Pedestrian Observations September 6, 2020

    Collections: Bread, How Did They Make It? Addendum: Rice!

    As an addendum on to our four-part look at the general structures of the farming of cereal grains (I, II, III, IV) this post is going to briefly discuss some of the key ways that the structures of rice farming differ from the structures of wheat and barle…

    via A Collection of Unmitigated Pedantry September 4, 2020

    Notes on “Anthropology of Childhood” by David Lancy

    I read David Lancy’s “The Anthropology of Childhood: Cherubs, Chattel, and Changelings” and highlighted some passages. A lot of passages, it turns out. [content note: discussion of abortion and infanticide, including infanticide of children with disabilit…

    via The whole sky August 27, 2020

    more     (via openring)


  • Posts
  • RSS
  • ◂◂RSS
  • Contact