liinnerd Posted August 13, 2009 Report Posted August 13, 2009 It's been a long time since I posted a question on this board but this is one I can't figure out on my own. So I hop someone can point me in the right direction. I'm configuring my MidiBox 64e to use 16 Ledbars as ledrings and connected them as shown in the DOUT example (http://www.ucapps.de/mbhp/mbhp_doutx4_ledrings.pdf)I've configure the setup file and everything works. But since one ledbar only uses 8 leds I thought let's disable the 4th register in the setup #define LEDRINGS_SR_ENC1_16_CATHODES_1 1 ; first shift register 16 LED rings for module 1 cathodes - #define LEDRINGS_SR_ENC1_16_CATHODES_2 2 #define LEDRINGS_SR_ENC1_16_ANODES_1 3 #define LEDRINGS_SR_ENC1_16_ANODES_2 0 ** edit: somehow the whitespace between cathode and register numer was lost in the code display above. FIXED IT! **But when I upload this configuration the ledbars won't light up. When I change the LEDRINGS_SR_ENC1_16_ANODES_2 to SR 4. everything is okay. Is it possible to disable it somehow? Not that its really necessary but I'm just curious. I will extend my box to 32 ledbars which leads me to my other question....Is it possible to share the cathodes from the next 16 bars with SR 1+2 and drive them with the 4th register to connect 32 LEDBARS on one DOUTX4?Hope someone can help me thanks!,Richard Quote
liinnerd Posted August 16, 2009 Author Report Posted August 16, 2009 Let me refrase the above. If I only use 8 Leds for a Ledring, would it be possbile to use one DOUTX4 for 32 Ledrings?And if so, do I need to change something in the sourcecode or can I just configure the correct SR settings in the main.asm? Richard Quote
/tilted/ Posted August 16, 2009 Report Posted August 16, 2009 You should be able to do 8 LED ledrings, and this would mean you could do more ledrings.But:You'd need 5 SRs to do this, (1 for anodes, 4 for cathodes, or vice versa), so this means you couldn't really do it all on one DOUTx4, if that was the question.I'm not sure about whether you'd need to change source, you would probably be OK to change SR settings in main.asm .You'd probably need to increase the refresh rate, as 32 of any size ledrings on the same SR line would likely have a noticable flicker.In terms of current, you should be OK... depending on whether you're using a dot indicator (lowest current), or a line, negative line, width, etc.Have fun. Quote
liinnerd Posted August 17, 2009 Author Report Posted August 17, 2009 Tilted> thanks for your input... but if you look at the example pdf (http://www.ucapps.de/mbhp/mbhp_doutx4_ledrings.pdf)the 4the register is use for leds 9,10,11 so it should be possible to drive the next 16 ledrings with this SR and connectthe cathodes on SR 1 and 2.Or am I missing something? Maybe I should just try it... but i'm afraid i'll just mess things up ;-) I had already a lot of probs to get thing working :) Quote
/tilted/ Posted August 18, 2009 Report Posted August 18, 2009 OK, I think I see where you're heading now.you want to make a 16x16 matrix, thus making 4 sub-matrices of 8 8-LED ledrings.This should be workable.The coding will be interesting. Quote
liinnerd Posted August 18, 2009 Author Report Posted August 18, 2009 YES you're right.. maybe I wasn't clear on that ;-)I have the hardware already finished and I could just use 2 DOUTx4, but if it could be done with one DOUTx4 it would be more efficient. My asm coding skills are very limited and I don't know if it's hard to do. Do you think it needs a lot of programming? Quote
liinnerd Posted August 18, 2009 Author Report Posted August 18, 2009 Okay i took a peek at the code. I removed all references to ledring handler (mb64_ledrings.inc) and configured the system (main.inc) to use 1+2 x 3 (SR 1+2 cathodes, SR 3 annodes) for the first 16 ledbars and sr 1+2 x 4 for the second 16 ledbars.Compiled it... uploaded it..... but as I thought it doesnt work ???Can it be done this way? or am I miles off... ;-) Quote
/tilted/ Posted August 19, 2009 Report Posted August 19, 2009 I'm not really they guy to talk to about the programming, but for updating ledrings individually you'll need to do a fair portion of bit masking.Pretty sure this is doable in C.I hate to be a bore, but the easiest way to do this is definitely to use 5 SRs. Any big reason why you can't do it this way? Quote
liinnerd Posted August 19, 2009 Author Report Posted August 19, 2009 oh no reason at all, thought it might be easier, but it aint :-)And when I use 5 SRs how would i configure it then? I suppose it also needs some coding Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.