Jump to content

BLM 16x16+X build guide


latigid on

Recommended Posts

On 4/20/2020 at 4:42 AM, Hawkeye said:

Thanks, @xarolium, @latigid on already completed the boards - we're now working on the case and the software.

That is wonderful news, Hawkeye!  I am happy to hear we may get a second chance.  I’m still kicking myself for missing that first group buy.

Edited by Blatboy
  • Like 1
Link to comment
Share on other sites

  • 1 month later...
  • 2 weeks later...
  • 2 months later...
On 12/26/2015 at 10:33 AM, sbm said:

Well, from bad to worse, looks like my board is shorted now.  Not sure how that happened but I measure 2.5 ohms resistance between ground and 5V.  That was a waste. :-/

Should have updated this....an air-driven reflow station is your friend when it comes to making fixes to SMD parts! :happy:

 

This was a lot of fun to do and get working.  Looking forward to building another one day. :cheers:

Link to comment
Share on other sites

  • 7 months later...

hey @latigid on ... do you know how to: offset the DIN-SR-NR (Code > 32bit) ? >  i need a DINx4, in the start of the SR-Chain > then after this the BLM...

i ask because the BLM has no "Thru" Port...

i already put the blm_scalar.c and blm_scalar.h into my project (so i can change it - if necessery)

 

( i dont need any info about the LED-Part --- there i dont need a offset)

TMV4.thumb.jpg.76d4bee8cc817e809bf99523286251de.jpg

 

Link to comment
Share on other sites

to add an DINx4 module in front of the BLM16x16+x-Module, do following...

blm_scalar.c   

add  the     SR_off     Part....

/////////////////////////////////////////////////////////////////////////////
//! This function gets the DIN values of the selected row.
//! call it from APP_SRIO_ServiceFinish() hook!
/////////////////////////////////////////////////////////////////////////////
s32 BLM_SCALAR_GetRow(void) {
		
		// decrememt debounce counter if > 0
		if( blm_scalar_button_debounce_ctr )	{ --blm_scalar_button_debounce_ctr; }
		
		// since the row line of the buttons is   identical to   the row line of the LEDs,
		// we can derive the button row offset from blm_scalar_selected_row                  909  >>>>>>>>>>>>>>>>   here is the offset?
		int selected_row = (blm_scalar_selected_row-1) & 0x7; // &: bitwise AND     0x7: 7
		
		// check DINs
		int mod;
		for(mod=0; mod<5; ++mod) {	// 5: Module-Nr
									int sr = blm_scalar_config.din[mod];
									
									static u8 SR_off = 4;		// Shiftregistor Offset -- if you have a DINx4 Module before the BLM-Module
									if( sr ) {	MIOS32_DIN_SRChangedGetAndClear(sr-1 + SR_off, 0xff); // ensure that change won't be propagated to normal DIN handler
												u8 sr_value = MIOS32_DIN_SRGet(sr-1 + SR_off);
												
												// ignore as long as debounce counter != 0
												if( !blm_scalar_button_debounce_ctr ) {
													
																// determine pin changes
																u8 changed = sr_value ^ blm_scalar_button_row_values[mod][selected_row];
																
																if( changed ) {
																				// add them to existing notifications
																				blm_scalar_button_row_changed[mod][selected_row] |= changed;
																				
																				// store new value
																				blm_scalar_button_row_values[mod][selected_row] = sr_value;
																				
																				// reload debounce counter if any pin has changed
																				blm_scalar_button_debounce_ctr = blm_scalar_config.debounce_delay;
																				}
																}
												}
									}
		
		return 0;
}

 

Link to comment
Share on other sites

Hello,

 

man this is a huge setup, i think i am going to built one of those kits for myself.

I just signed up to the mailinglist in the midiphy shop.

But as soon es one is available feel free to hit me up personally, i also cold be some kind of beta tester :)

I did built the Midibox SID, it seems to work :) and the Midibox sequencer.

If i understand right this matrix controller only works together with the sequencer.

 

Thanks a lot for all that effort.

Best wishes.

Link to comment
Share on other sites

3 hours ago, mex said:

f i understand right this matrix controller only works together with the sequencer.

Best wishes.

or other midi devices... or you could program your own custom sequencer into the matrix (it is a32bit core now?...thats whaz i did with V1 off the blm16*16+x

Link to comment
Share on other sites

  • 6 months later...
  • 1 year later...
On 4/14/2021 at 4:05 PM, Phatline said:

to add an DINx4 module in front of the BLM16x16+x-Module, do following...

blm_scalar.c   

add  the     SR_off     Part....

/////////////////////////////////////////////////////////////////////////////
//! This function gets the DIN values of the selected row.
//! call it from APP_SRIO_ServiceFinish() hook!
/////////////////////////////////////////////////////////////////////////////
s32 BLM_SCALAR_GetRow(void) {
		
		// decrememt debounce counter if > 0
		if( blm_scalar_button_debounce_ctr )	{ --blm_scalar_button_debounce_ctr; }
		
		// since the row line of the buttons is   identical to   the row line of the LEDs,
		// we can derive the button row offset from blm_scalar_selected_row                  909  >>>>>>>>>>>>>>>>   here is the offset?
		int selected_row = (blm_scalar_selected_row-1) & 0x7; // &: bitwise AND     0x7: 7
		
		// check DINs
		int mod;
		for(mod=0; mod<5; ++mod) {	// 5: Module-Nr
									int sr = blm_scalar_config.din[mod];
									
									static u8 SR_off = 4;		// Shiftregistor Offset -- if you have a DINx4 Module before the BLM-Module
									if( sr ) {	MIOS32_DIN_SRChangedGetAndClear(sr-1 + SR_off, 0xff); // ensure that change won't be propagated to normal DIN handler
												u8 sr_value = MIOS32_DIN_SRGet(sr-1 + SR_off);
												
												// ignore as long as debounce counter != 0
												if( !blm_scalar_button_debounce_ctr ) {
													
																// determine pin changes
																u8 changed = sr_value ^ blm_scalar_button_row_values[mod][selected_row];
																
																if( changed ) {
																				// add them to existing notifications
																				blm_scalar_button_row_changed[mod][selected_row] |= changed;
																				
																				// store new value
																				blm_scalar_button_row_values[mod][selected_row] = sr_value;
																				
																				// reload debounce counter if any pin has changed
																				blm_scalar_button_debounce_ctr = blm_scalar_config.debounce_delay;
																				}
																}
												}
									}
		
		return 0;
}

 

 

 

now i need this for the DOUT-Registers... i got the 16x16 working with following code .... but the Extra-XY stay dark - any Idea? cant get forward, since Latigid Ons BLM has no J89 thru, i have to put the BLM at the end of the SR-Chain (3xDIN, 4xDOUT in front off the BLM)

 

/////////////////////////////////////////////////////////////////////////////
//! This function prepares the DOUT register to drive a row					DOUT-SR-OFFSET HERE!!!!!!!!!!!!!!!
//! should be called from   APP_SRIO_ServicePrepare()
/////////////////////////////////////////////////////////////////////////////
s32 BLM_SCALAR_PrepareCol(void)	{

		// increment row, wrap at 8
		if( ++blm_scalar_selected_row >= 8 )	{ blm_scalar_selected_row = 0; }

		// select next DOUT/DIN row (selected cathode line = 0, all others 1)
		u8 dout_value = ~(1 << blm_scalar_selected_row);

		// apply inversion mask
		dout_value ^= blm_scalar_config.cathodes_inv_mask;

		// output on CATHODES* registers
		u8 SRo_off = 4;	//Shiftregister offset

		int mod;
		for(mod=0; mod<5; ++mod) {	int sr = blm_scalar_config.dout_cathodes[mod];	// 5: Module-Nr

									if( sr )	{ MIOS32_DOUT_SRSet(sr-1 + SRo_off, dout_value); }	// SR-CHain: BLM > Dout....
									//if( sr )	{ MIOS32_DOUT_SRSet(sr+3, dout_value); }	// SR-Chain: DoutX4 > BLM
								}

		// output colours
		for(mod=0; mod<5; ++mod) {

									int colour;	// 5: Module-Nr
									for(colour=0; colour<2; ++colour) { // 2: Color-Nr

												int sr	= blm_scalar_config.dout[mod][colour];

																	// Module        8 Rows            Color   Blink
												u8 STEPs= blm_scalar_led[mod][blm_scalar_selected_row][colour][0];

												int val;

												if (blinky && BLM_BLINK_ACT) { 	// turn of the blinking Steps

																u8 FLAM = blm_scalar_led[mod][blm_scalar_selected_row][colour][1];

																// compare FLAM and STEPs    with   Bitwise XOR!
																val = FLAM ^ STEPs;
															}

												else { val = STEPs; }


												// Set it
												if( sr ) { 	MIOS32_DOUT_SRSet(sr-1 + SRo_off, val); }	//Shiftregister offset, val); }	// SR-CHain: BLM > Dout....
												//if( sr ) { 	MIOS32_DOUT_SRSet(sr+3, val); }	// SR-Chain: DoutX4 > BLM  Geht zumindest für ie Hauptmatrix 8080

												///  ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////777
									} }

		return 0;
}

 

Link to comment
Share on other sites

ok i got it...

if you have for example follwing Shiftregister Chain- Scenario:

DINx3 > DOUTx4 > BLM   (instead of BLM > DIN > DOUT... which is not possible because of not having a J8/9 output on the BLM)

go to blm_scalar.c

and change following:

/////////////////////////////////////////////////////////////////////////////
//! Initializes the BLM_SCALAR driver
//! Should be called from Init() during startup
/////////////////////////////////////////////////////////////////////////////
s32 BLM_SCALAR_Init(u32 mode)	{

	  // define default configuration (can be changed during runtime)
	  int mod;
	  for(mod=0; mod<5; ++mod) {// count thru Scalar Modules

								// DOUT
								int mod_sr_offset = (3 * mod) + 4;	// 4: DOUTX4 OFFSET      3: 1-Cathode, 2-Color1, 3-Color2

								blm_scalar_config.dout_cathodes[mod] = mod_sr_offset + 1;

								int colour;
								for(colour=0; colour<2; ++colour)
								blm_scalar_config.dout[mod][colour] = mod_sr_offset + colour + 2; // offset 2..3(..4)


								// DIN
								blm_scalar_config.din[mod] = mod + 1 + 3;	// 3 = DINX3 OFFSET

								}
  .......................................

have fun!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...