Git Product home page Git Product logo

Comments (8)

osune avatar osune commented on August 23, 2024

Yes :)

This is a known problem with the Version of Gambit you are using.
Unfortunately the guy having the same problem never reported back. So I don't know if this really fix things up.

The link gives you a dissection of the problem but I try to give a TL;DR version here:

First you have to link the midijoystick.scm file
$ gsc -link midijoystick

Then you need to compile and link it together with the remaining c-files
$ gcc -std=c11 -Wall -g -O0 -lgambc -lm -ldl -lutil $(pkg-config --cflags --libs jack) -o midijoystick joystick.c midijack.c midijoystick.c midijoystick_.c

Please note i still don't have access to a Debian Machine with Jack installed, so this is me flying blind.

from midijoystick.

pwqw avatar pwqw commented on August 23, 2024

Thanks for answering 👍

When..

$ gsc -link midijoystick
*** ERROR IN "/tmp/MidiJoystick/midijoystick.scm"@128.44 -- Undefined C type identifier

In the file, at line 128:44, I find the size_t element:

;;; Functions to interact with JackAudioServer
(define setup-jack (c-lambda () int "_setup_jack"))
(define send-midi (c-lambda (scheme-object size_t) int "int res = SEND_MIDI(___arg1, ___arg2);  ___return(res);"))

JACK verrsion 0.4.2 is correctly running

from midijoystick.

osune avatar osune commented on August 23, 2024

No problem!

So as far i can see it seems size_t was not available in gambit 4.2.8. (unfortunately the documentation seems not be only any more)

But send-midi and its c implementation is my own code so I think it is save to use int instead of size_t here (midi messages are quite short). I created a experimental branch containing the changes: gambit_4.2.8_experimental

Please have a look and excuse my situation of not being able to test it myself. :(

from midijoystick.

pwqw avatar pwqw commented on August 23, 2024

Calm friend, I'm helping and I don't charge you.. 😆
Literally, I think that others people found others solutions in pure C 😅 like me.. But I like test it.

Ok: gsc -link midijoystick works, but..

$ gcc -std=c11 -Wall -g -O0 -lgambc -lm -ldl -lutil $(pkg-config --cflags --libs jack) -o midijoystick joystick.c midijack.c midijoystick.c midijoystick_.c

see the output here

from midijoystick.

osune avatar osune commented on August 23, 2024

Tell what solutions did you found ? I tried scheme / gambit to get a powerfull configuration syntax so i've wondered how a pure C project will solve this.

I've made another commit 73fdd1bfb654cf56f3ccce955ec22e7824a5fcd9.
Just deleting the inclusion of 'gambit.h' in the glue.c file and hoping for the best.

Gambit 4.2.8 is now 9/10 years old so .... if that's not working for you i fear you might have more success by compiling gambit 4.8.4 yourself. At least that is the version i programmed against.

I've seen falkTx nooise repository. It has UDEV support but i don't know about the working state. But i'm thinking to base of this lib a SBCL Common Lisp implementation for Midijoystick (see enhancement issues here).

from midijoystick.

pwqw avatar pwqw commented on August 23, 2024

Yes, Gambit 4.8.4 is the real solution.. but I could not compile it either 🤒
First I need to change this linux distro.

Well.. the new gcc command output is here
Update README: "Never try with Gambit 4.2.x" haha

On the other hands, I tested:

  1. falkTX nooice: seems complete but doesn't work.
  2. gretchycat js2midi: the axes doesn't work and only takes some buttons.
  3. kevinmcglashan aseqjoy: the axes are working and the buttons change the midi channel.

then I found solutions in java/windows, python and nodejs too

from midijoystick.

osune avatar osune commented on August 23, 2024

Uff that's a bummer, that you weren't able to compile Gambit 4.8.4 =(

Oh well this output is somehow expected. I fear I've to give up and stop wasting your time.
I'll update it :D

I love falkTX for his work for the Linux Audio community.
aseqjoy unfortunatly uses ALSA. But it seems the most working.

Apart from just the fun of it I personally don't think a gamepad/joystick is a good MIDI input device.
Maybe a nice thing for live gigs and glitchy music.
But with libevdev support one could connect any peripheral and send MIDI (e.g. Trackball as an x/y fader etc...). Only disadvantage is the huge pile of obscure MIDI Commands and I wouldn't like to recompile just to change the Input Configuration. That's why I tried it in Gambit , the Lisp Lists are quite a powerful configuration syntax. I hope some day I will realize this Program in Common Lisp but it's not the most enduser friendliest Programming Language when distributing.

Anyways thanks for your interest in this Program :)

from midijoystick.

pwqw avatar pwqw commented on August 23, 2024

hhahaa no.. really isn't a good MIDI input device. But in some Latinoamerican places is most easy get a joytick to control the sounds programs than a real MIDI controller. So is a good application for newest.

Lisp is heard good. Be careful of choosing a version default in the ubuntu, raspbian and debian repositories for an easy implementation xD
A "command line graphical user interface" could be funny useful solution..

Thanks to you a lot!

from midijoystick.

Related Issues (8)

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.