Hi
I try to fetch the bpm from the Midi Clock, and stumble over "jitter".
So I start to collect data for a larger amount of time, but it wouldn't
help.
Here is what I do:
else if ((in_event.buffer[0] ) == 0xf8) { // midi beat clock
clock_gettime(CLOCK_MONOTONIC, &ts1);
time0 = (ts1.tv_sec*1000000000.0)+(ts1.tv_nsec);
static int collect = 0;
static int bpm = 0;
bpm += ((1000000000 / (time0-time1) / 24) * 60); // nanosec
to bpm
collect+=1;
if (collect >=30) {
set_bpm_val(bpm/collect);
collect = 0;
bpm = 0;
}
timed = time0-time1;
// printf("Midi clock event %X time0 %f time1 %f timed %f
ts1.tv_nsec %lu\n",in_event.buffer[0], time0, time1, timed, ts1.tv_nsec);
time1 = time0;
} else if ((in_event.buffer[0] ) == 0xfa) { // midi clock start
printf("Midi clock start\n");
//set_ctr_val(MIDICLOCK, 1);
} else if ((in_event.buffer[0] ) == 0xfb) { // midi beat
clock continue
//set_ctr_val(MIDICLOCK, 1);
printf("Midi clock continue\n");
}else if ((in_event.buffer[0] ) == 0xfc) { // midi beat clock
stop
//set_ctr_val(MIDICLOCK, 0);
printf("Midi clock stop\n");
} else {
printf("CC number %x\n", in_event.buffer[0] );
}
tim0 and time1 are set as double.
I experience jitter around 1 or 2 beats around the "original bpm set in
the master.
When master is set to 360 I receive 374.
How do you usually fetch the bpm from Midi Clock, any pointer will be
welcome.
regards
hermann
Hi LADs
This is an invitation for all those who are interested in the Control Chain system, the MOD approach to external hardware controllers.
The Control Chain interface was conceived with the LV2 control ports properties in mind. It tries to dis-abstract the LV2 Control structure in tangible (and material) form.
The first purpose of the Control Chain was to connect the MOD and its external peripherals. The MIDI system is very generalistic and we didn’t want to design a “MIDI Clone”. As the LV2 standard enables the developers to add important metadata to describe the Control Ports, the MOD platform makes use of all this info to offer a good user experience to the musicians.
A good example is the footswitch. The Control Chain footswitch has built in its firmware different behaviours depending on port properties. It alternates the state of toggles controls, it can trigger an event, it can run the items of an enumeration list and it can also measure time and offer TapTempo for time based units.
All this is accomplished with the same physical actuation - the pressing of the button - but according to the control that has been addressed to it. The GUI decides which actuator it offers the user for each of the Controls.
The physical interface of the Control Chain devices is an RS-485 full-duplex serial line running at 1Mbit/sec. Currently up to eight devices can be daisy chained and by use of the RJ-45 cable we also power the devices ( 1 pair for input,1 for output and 1 for power supply).
After some development we came to the conclusion that such a protocol could be extended for virtual devices in the GUI as well and this would make the development of plugins interfaces much easier.
The reason for sharing this with the Linux Audio community is to involve as much people as possible in electing the needed features for the plugins.
At this current state, the Control Chain supports only Input ControlPorts. People have been asking about the Tuner and other plugins that have Control Outputs.
So we’re opening up the discussion to set the requirements and possibilities that shall be implemented.
The discussion is to happen on our mailing list:
http://portalmod.com/cgi-bin/mailman/listinfo/developers <http://portalmod.com/cgi-bin/mailman/listinfo/developers>
and at the #portalmod IRC channel @ freenode.
Hope to see you all there
Kind regards
Gianfranco
The MOD Team
Good morning lads,
among the people still using LADSPA, either directly or wrapped into
more fashionable plugin APIs, is anyone actually dependent on
run_adding()?
(Asking, of course, because I intend to drop support for it.)
Thank you,
Tim
MFP -- Music For Programmers
Release 0.05, "Mighty Fine Patching"
I'm pleased to announce a new version of MFP, containing many new
features, fixes and improvements. This is still a very early
release that is missing a lot of expected functionality, but it's
a significant step forward from 0.04 in every way and I thought
it might be of interest to the wider community.
A summary of changes is below. Please see the GitHub issue tracker
for complete details:
http://github.com/bgribble/mfp
This version is still source-code-only, but the new build system
should make it a bit easier for those who would like to try it.
Significant changes since release v0.04
----------------------------------------
* MFP patches can be saved as LV2 plugins that can be
live-edited while loaded in a host (see doc/README.lv2)
* New build system using 'waf' for one-line build and install
(see doc/README.build)
* Support for user patches with dynamic creation of
inlets/outlets and other objects at instantiation time (with
examples) using the "@clonescope" method
* Lazy evaluation of expressions using a leading "," syntactic
sugar is available in message boxes (i.e. the message
"datetime.now()" is a constant, but ",datetime.now()" is
evaluated each time the message is emitted)
* More sample patches, including a basic tutorial covering app
interaction, "hello, world", and patterns for things like
iteration, conditionals, etc
* Improvements to stability and error handling
* Many other bugfixes and improvements. The complete list of
60+ tickets closed since the 0.04 release is in the 0.05
milestone:
http://github.com/bgribble/mfp/issues?q=milestone%3A%22mfp+0.05%22+is%3Aclo…
About MFP
----------------------------------------
MFP is an environment for visually composing computer programs,
with an emphasis on music and real-time audio synthesis and
analysis. It's very much inspired by Miller Puckette's Pure Data
(pd) and Max/MSP, with a bit of LabView and TouchOSC for good
measure. It is targeted at musicians, recording engineers, and
software developers who like the "patching" dataflow metaphor for
coding up audio synthesis, processing, and analysis.
MFP is a completely new code base, written in Python and C, with
a Clutter UI. It has been under development by a solo developer
(me!), as a spare-time project for several years.
Compared to Pure Data, its nearest relative, MFP is superficially
pretty similar but differs in a few key ways:
* MFP uses Python data natively. Any literal data entered in the
UI is parsed by the Python evaluator, and any Python value is a
legitimate "message" on the dataflow network
* MFP provides fairly raw access to Python constructs if desired.
For example, the built-in Python console allows live coding of
Python functions as patch elements at runtime.
* Name resolution and namespacing are addressed more robustly,
with explicit support for lexical scoping
* The UI is largely keyboard-driven, with a modal input system
that feels a bit like vim. The graphical presentation is a
single-window style with layers rather than multiple windows.
* There is fairly deep integration of Open Sound Control (OSC), with
every patch element having an OSC address and the ability to learn
any other desired address.
* MFP has just a fraction of the builtin and addon functionality
provided by PD. It's not up to being a replacement except in
very limited cases!
The code and issue tracker are hosted on GitHub:
https://github.com/bgribble/mfp
You can find the LAC-2013 paper and accompanying screenshots,
some sample patches, and a few other bits of documentation in the
doc directory of the GitHub repo. The README files at the top
level of the source tree contain dependency, build, and
getting-started information.
Thanks,
Bill Gribble <grib(a)billgribble.com>
Hi,
I developed an aSoC driver for MOD-Duos Sound Card and i can aplay and
arecord, but when calling jackd (jackd -dalsa -r48000 -p256 -P hw:0 -C hw:0
&) i get an alsa format error.
I get this message:
--
Rafael Guayer
www.portalmod.com <http://www.portalmod.com.br>
Hi Linux Audio Users and Developers
Last week the MOD Duo kickstarter campaign was successfully funded and we’re now heading towards turning the Duo into a reality!
As most, if not all, of our software is related to Linux Audio we would like to have the community involved in the development as much as we can.
To do so we created a mailing list and registered an IRC channel.
The mailing list located at http://portalmod.com/cgi-bin/mailman/listinfo/developers
and the IRC channel is #portalmod at freenode.
We’re soon to start discussions regarding the ControlChain (our LV2 hardware communication protocol) and also methods of optimizing the plugin graph cpu usage and we’d like to have as many people involved as we can.
Of course the discussion is not limited to those topics and any thing regarding the MOD can be discussed at such places.
Hope to see you guys on our lists.
Best wishes to everyone
Gianfranco
The MOD Team
Hi
If this
// calculate the next sample: phase ranges from 0 -> 1, but sin()
// expects its input in radians. Just multiply by 2 PI to convert it!
// We also multiply by volume so its not extremely loud.
output[pos] = sin( self->phase * 2 * PI ) * volume;
Sends a sine wave to output (this is the standard sin
<http://www.cplusplus.com/reference/cmath/sin/> math function, right?)
then what would send a square wave? What would send noise?
Thanks -Phil
--
Philippe "xaccrocheur" Coatmeur
http://bitbucket.org/xaccrocheur / https://github.com/xaccrocheurhttp://opensimo.org/play/
-------- Forwarded Message --------
Subject: Re: [LAD] How can an LV2 plugin UI get the value of a control
port from the plugin?
Date: Mon, 20 Oct 2014 01:27:10 +0100
From: Philippe Coatmeur <philcm(a)gnu.org>
Organisation: GNU
To: Harry van Haaren <harryhaaren(a)gmail.com>
On 17/10/14 15:56, Harry van Haaren wrote:
> On Fri, Oct 17, 2014 at 1:30 PM, Phil CM <philcm(a)gnu.org
> <mailto:philcm@gnu.org>> wrote:
>
> Also each time the UI is opened, the widgets are reset at maximum
> (not the values).
>
> Hi Phil,
>
> Glad to see you're excited and working hard on learning LV2! Checkout
> the example plugins: they show how things work.
>
> In the UI, there is a port_event() function. It tells the UI what
> port changed, and what its current value is. Use this to do
> widget->setValue( newValue ); and you're done ;)
For this I had to write my own
int setValue(int value) {
// this->scrollvalue(value);
cout << "Called with value " << value << endl;
}
And it does get called by port_event() now
* what do I put in this setValue() in order to /actually//update/ the
widget value?
There is a int scrollvalue(int pos,int size,int first,int total); in
Fl_Slider.H but can't call it from the class, witch is not explicitely
extending Fl_Slider
<https://bitbucket.org/xaccrocheur/kis/src/8c3a85a9899f117d2fa273b6c7948402d…>
from what I can see... Is it?
Thanks everybody
--Phil
PS - Apparently Sorcer is using AvTK on top of FLTK, I was under the
impression that Sorcer's UI was using NTK, am I mistaking?
>
> Eg (from OpenAV's ArtyFX, Bitta plugin)
> https://github.com/harryhaaren/openAV-ArtyFX/blob/master/bitta/gui/ui.cxx#L…
>
> How can I /get/ the control ports values from the UI perspective?
>
> In answer to your Q, how to "get", you don't: you're told when there's
> a new value.
>
> HTH, Cheers, -Harry
>
> --
>
> http://www.openavproductions.com
--
Philippe "xaccrocheur" Coatmeur
http://bitbucket.org/xaccrocheur /https://github.com/xaccrocheur
http://opensimo.org/play/
Hi folks,
I'm trying to write a small utility in python that will help me
redirect and route midi and osc to various software through jack. I'm
finding that mididings, which I am a big fan of, doesn't quite fit for
this particular task, so I started to look for other midi manipulation
modules.
Though there seems to be a dizzying array of modules that are designed
for handling various midi tasks from python, I have settled on the two
separate rtmidi ports: python-rtmidi
(http://trac.chrisarndt.de/code/wiki/python-rtmidi) and rtmidi-python
(https://github.com/superquadratic/rtmidi-python).
My question is for those that have used either or both modules for
their software:
Can you recommend one over the other, and for what reasons?
So far in my experimentation I've had trouble running rtmidi-python in
a Python3 environment.
NOTE:
As these kinds of threads tend to digress here quite frequently, I'd
like to emphasize that I'm not interested in whether python is the
right language for this kind of thing, or whether midi on linux is
bad/good, etc. -- I really don't care. I'm just interested in whether
anyone has used the abovementioned modules and if they have pros/cons
for one or the other.
Many thanks.