Switch Panel Tabs with incoming midi message

HaHa! We're in the same boat :laughing:
I did make a lot of progress today (with jean-emmanuel's help!). I now have everything working as hoped. Here's the link to our discussion:

Here's the current Custom Module I'm using:

module.exports = {

    oscInFilter:function(data)
	{
        var {address, args, host, port} = data
		if (address === '/control' && args[1].value == 127) {
			send('midi', 'OSCtoCUBASE', '/control', 1,126,1)
			receive('/panel_articulations', 0)
			receive('/panel_controls', 0)
			return
		}
		if (address === '/control' && args[1].value == 117) {
		if (args[2].value === 0) {
			receive('/panel_articulations', 0) // 0 = first tab			
		} else if (args[2].value === 1) {
			receive('/panel_articulations', 1)
			receive('/panel_controls', 1)
		} else if (args[2].value === 2) {
			receive('/panel_articulations', 2)
			receive('/panel_controls', 2)	
		} else if (args[2].value === 3) {
			receive('/panel_articulations', 3)
			receive('/panel_controls', 3)	
		} else if (args[2].value === 4) {
			receive('/panel_articulations', 4)	
		} else if (args[2].value === 5) {
			receive('/panel_articulations', 5)	
		} else if (args[2].value === 6) {
			receive('/panel_articulations', 6)			
    }
		return // bypass  cc 117
}
	return {address, args, host, port}
	},
}
1 Like