CDJ BPM Question

191 views
Skip to first unread message

Kevin

unread,
Nov 23, 2020, 4:30:32 PM11/23/20
to Lightjams
Hi all,

In the past with a friend of mine, which was using a HOG4 we build a bridge between the Pioneer CDJ/DJM gear and his HOG leveraging Beat-Link-Trigger and OSC commands.

We build a beat Expression in Beat Link Trigger that per defined beat (1-4) send a OSC command to his HOG where we had chases build with steps. Each OSC command send the HOG to the next step in the chase. Giving us a "poor mans BPM sync".

I'm now trying to follow the same approach with Lightjams, but I'm not completely following the concept yet in that regard. The whole idea of Lightjams seems to have a different approach in general if we talk about chases, steps and all that.

I was able to successfully map an OSC command against "Power", but that off course doesn't give the desired outcome besides turning a light on/off pretty brutal. But it's a start! 

After that I've mapped it against Master Speed, but as you can expect it get's all wonky because Master Speed ranges from 0x-5x where my OSC commands do not, but even if they did I cannot make sure only 1 step of a chase gets executed and we'll wait till the next beat.

So, my question:
Is there a different way to build that same approach where a chase gets build within Lightjams and I can send a per OSC command "next step" in the chase command? Or do I need to try and go nuts with the formula's, sending the current BPM over OSC and trying to recalculate to something that makes sense on the 0-5 scale?

I've tried the Music inputs, but with not having an ASIO device and the lights came a bit late to the party and I do see more future in leveraging this poor mans solution, or even something like Ableton Link to send a general Tempo control.

On a side note:
I've noticed that when leveraging OSC I needed to add a sleep of 40 MS in the OSC commands that follow each other. So if I only want a flash on the 1st and 3th beat I'd do this:

(when (#{1 3} beat-within-bar)
(osc/osc-send (:Magic @globals) "/magic/0" 1)
(Thread/sleep 40)
(osc/osc-send (:Magic @globals) "/magic/0" 0))

If I would remove that Sleep, Lightjams OSC retrieval stays at 0, even though I see the 1 and 0 incoming. That's not a problem we've encountered with other software so far. I am still in demo mode by the way and truth be told, it doesn't really matter since this is still quick enough.

Thanks in advanced for reading this and thinking with me!

Kevin

Mathieu

unread,
Nov 23, 2020, 4:53:14 PM11/23/20
to Lightjams
Hi,

For cue lists and going to the next step, look at the sequencer examples on this forum (https://groups.google.com/u/1/g/lightjams/search?q=sequencer) or in the sample projects: https://www.lightjams.com/tutorial.html#projectsSection. There's also a video tutorial showing the main concepts.

In many cases, the sequencer is made by moving a source forward when receiving a signal. In your case, the signal would be via OSC. For example, one formula you could use for the source's x slider is:

xtopercent(counter(0, grid.lastx, osc.onreceived(0)))

This way, each time you send a message on osc channel 0, the source would move forward.

Then the answer as to why when you send two osc messages without waiting, the final value is the latest value, it's because the osc function returns the latest value - the most up to date value.

Like in the previous formula, if you want to do something each time a osc message has been received, then use the osc.onReceived function.

Hope this helps!

Kevin

unread,
Nov 23, 2020, 5:17:26 PM11/23/20
to Lightjams

D'oh! That looks to be the trick yes, but you knew that already off course.
Sorry that I didn't go patiently through all the video tutorials, would've saved asking this question.

And regarding sending OSC 1 and 0 without waiting, we needed to do that on the HOG to mimic the key press for "next step" in the chase, otherwise it didn't register as pressed. And off course when the OSC command was bound against the powerslider it just sets the OSC value to the amount. So yeah, that makes sense it did throw us off for a while though.

It just seems I really need to let go the things we did with the HOG and why and reset myself to embrace the concept of Lightjams.

Thanks a lot for the quick response and honestly it's impressive software as far as I've seen now!

Kind regards,

Kevin

Kevin

unread,
Dec 22, 2020, 5:45:11 AM12/22/20
to Lightjams

Just wanted to let you know, I've been trying this and works like a charm!

I've created multiple "Chase" grids, enabled them for Mapping and enabling them using attribute ID's.
Then I created a general "Chase Selector" grid, which let's me trigger specific chases based on the OSC command I trigger it.

To let the source walk over the grid in the chases:
In the chase grids I've mapped the the X axis of the source to OSC, making it walk the grid based on the OSC trigger, getting triggered by Beat Link Trigger per Beat: xtopercent( counter(0, grid.lastx, onbeat(osc.onreceived(0))))

To choose the correct chase:
On this grid I've patched the activation of the grids, I'm calling it the chase selector grid. Here I've mapped the X axis of the source to OSC: xtopercent( osc(1) )
Meaning if I send and OSC message on channel 1, with the value of 0 it goes to the first X position, if I send OSC value of 3 it goes to the 4th X position.

Unsure if it's the right way, but for me this seems to work pretty good so far!

Thank you for pushing me in the right direction, I've still got a few small hurdles to cross to be done with my POC. But once I understand those things and get some descent chases in there it'll be very cool to have Beat Link Trigger send OSC messages based on location in a track, triggering the right scene/chase for that moment in the track.

Kind regards,

Kevin

tfm...@gmail.com

unread,
Mar 14, 2023, 1:44:55 AM3/14/23
to Lightjams
Hi @Kevin,

I just saw this post mentioning about Beat Link Trigger which I understand to integrate with various DJ controllers to send OSC messages to a network.

This is probably way over my head and may not even be possible in my case but I thought I'd ask anyway.

I'm using djay PRO AI controlled via a DDJ-SB3. I'm also using LightJams for my lights and other fixtures. Given I have various lighting effects on LJ I was hoping it's possible to get some control messages from my gear into LJ. But given the DDJ is simply an extension of the software this is probably a question for djay PRO AI.

Is this kind of setup reserved for professional settings?

Kevin

unread,
Mar 19, 2023, 2:30:37 PM3/19/23
to Lightjams
Hi,

Sorry this was redirected to my spam folder for some reason.

Beat Link Trigger works only on Pioneer equipment that works on Pro-DJ-Link from Pioneer (network protocol).
This means controllers (and some all-in-ones) are sadly not support (but more can be found at the github page from beatlink trigger).

Kind regards,

Kevin

isaac

unread,
Mar 19, 2023, 3:40:26 PM3/19/23
to Lightjams
I would ask this over on the Djay Pro AI forums, but it does appear it can natively send MIDI out messages which could be supported by Lightjams.

tfm...@gmail.com

unread,
Mar 20, 2023, 11:56:11 PM3/20/23
to Lightjams
Thanks @Kevin,

Beat Link Trigger is dead for me as entry level controllers don't support this but it appears there's a possibility over on the Algoriddim forums at the post @isaac referenced. Will check that out.

Thanks guys :)

Reply all
Reply to author
Forward
0 new messages