RandomCrapMess(4) – added fonctionalities

Random stuff is great, but I also have  70% of FLASH and 80% RAM left. What a waste. So I decided to add drum patterns. The patterns are coming from the Zularic Repetitor of Noise Engeneering.

Patterns that you can find in the manual (link at the end). Really easy to implement on its own, the harder part would be to put it with the original program. Find a way to make them cohabit and easy to select. I only have a pushbutton and a 7 segment display.

here’s the file : https://github.com/ThebigDickhead/AVR_PROG/blob/master/drum_pattern.h

    uint8_t a;
static uint8_t  b;

a = funk1_pattern[c][0][b];
if(a)     output_reg |= 1<<0;
else    output_reg &=~(1<<0);

a = funk1_pattern[c][1][b];
if(a)     output_reg |= 1<<1;
else    output_reg &=~(1<<1);

a = funk1_pattern[c][2][b];
if(a)     output_reg |= 1<<2;
else    output_reg &=~(1<<2);

a = funk1_pattern[c][3][b];
if(a)     output_reg |= 1<<3;
else    output_reg &=~(1<<3);
if(b>=16) b = 0;

//c is incrementing via a button in main loop.




Leave a comment

Filed under Uncategorized

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s