Welcome to %s forums

BrainModular Users Forum

Login Register

Converting CC value to DMX values

General Discussion about whatever fits..
Post Reply
noise2sine
Member
Posts: 458
Contact:

Converting CC value to DMX values

Unread post by noise2sine » 04 Jan 2023, 10:55

Hello,

Is it possible in Usine to convert from a CC value module data into DMX values ? I have a patch which send CC values but i need that this patch can send CC values converted to DMX ?

Help !!!!

Thank you !

User avatar
senso
Site Admin
Posts: 4424
Location: France
Contact:

Unread post by senso » 04 Jan 2023, 13:16

I'm not sure to understand.
In Usine DMX is a value in the range [0..1] and CC is a value in the range [0..127]. So a simple change scale does the trick?

see
demo CC 2 Dimmer.wkp
(121 KiB) Downloaded 1199 times

noise2sine
Member
Posts: 458
Contact:

Unread post by noise2sine » 04 Jan 2023, 13:55

Thank you for your answer ! i'm sorry not to be clear ... If i understand well , there 's a DMX module that already do the job ? My need is to be able to send DMX values ? i have read that they are from 0 to 255 ? Do they can be sent through Midi out ? with a classic midi cable ?

Thank you !

joffo78
Member
Posts: 1033
Contact:

Unread post by joffo78 » 04 Jan 2023, 16:24

Hi
If you want to strictly convert all CC input in dmx you can use the following script ( see example)
//////////////////////////////////////////////////////
// MIDI CC to ARRAY
//////////////////////////////////////////////////////

//////////////////////////////////////////////////////
// Paramters declaration
//////////////////////////////////////////////////////
var input : Tparameter;
var output: Tparameter;
var reset : Tparameter;

//////////////////////////////////////////////////////
// initialisation procedure
//////////////////////////////////////////////////////
procedure init;
begin
input := CreateParam('midi in',ptMIDI,pioInput);

output := CreateParam('array out',ptArray,pioOutput);
output.Min(0);
output.Max(1);
output.Length(128);

reset := CreateParam('reset',ptButton,pioInput);

ModuleColor($FF3298DB);

end;

// Global Variables
var MIDI : TMIDI;

//////////////////////////////////////////////////////
// Main Loop procedure
//////////////////////////////////////////////////////
Procedure Process;
var i: integer;
begin
output.Length(128);
if reset.equal1
then begin
for i:=0 to 127
do output.asArray(i,0);
reset.asFloat(0);
end;
for i := 0 to getLength(input)-1
do begin
MIDI := input.asMidi(i);
if (MIDI.msg=176)

then begin
output.asArray(MIDI.data1,MIDI.data2/127);
end
else
if (MIDI.msg=128)
then begin
output.asArray(MIDI.data1,0);
end;

end;
end;
Attachments
CONVERT CC TO DMX.wkp
(135.87 KiB) Downloaded 454 times

User avatar
oli_lab
Member
Posts: 1261
Location: Brittany, France
Contact:

Unread post by oli_lab » 04 Jan 2023, 23:05

Dmx won't go thru midi output
You'll need a dmx interface
Check dmx king
http://oli-lab.org

Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces

follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social

noise2sine
Member
Posts: 458
Contact:

Unread post by noise2sine » 07 Jan 2023, 14:15

Thank you for your precious help . My need was to generate a CC automation curve in usine and send it to a machine that only get DMX input . i thought that it would have be possible to convert the CC signal but i didn't think about the cable issue !!! So in fact i need to still send CC values through midi but in a midi to DMx box !

Can you give me advice for a midi to DMX box ?

Thanks again

User avatar
oli_lab
Member
Posts: 1261
Location: Brittany, France
Contact:

Unread post by oli_lab » 07 Jan 2023, 20:15

The easy and robust Way is with a dmx king edmx artnet to dmx interface.
Comes with a cost for sure.
There's a usb to dmx thingo from dmx King that is a cheaper alternative.
http://oli-lab.org

Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces

follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social

joffo78
Member
Posts: 1033
Contact:

Unread post by joffo78 » 13 Jan 2023, 11:29

Midi To dmx interface doesn't exist. It's too much different protocols .
You have to make the conversion with usine and send dmx flow directly on a dmx interface.

Post Reply

Who is online

Users browsing this forum: No registered users and 32 guests