ELEC2645 (2015/16) / Mbed 2 deprecated Main_code_ver18

Dependencies:   FATFileSystem N5110_mod SDFileSystem USBDevice mbed

Embed: (wiki syntax)

« Back to documentation index

Sequencing

Sequencing

Variables and functions used to adress the step sequencer. More...

Namespaces

namespace  Sequence_struct
 

generates the variables requred for a sequence


Functions

void Sequence_init ()
 # Sequence functions
void Sequence_write ()
 writes input data to sequence gate
void Sequence_increment_ISR ()
 interrupt call for sequence increment
void Sequence_increment ()
 increments sequencer

Variables

char * inst_names []
 # Sequence data
Ticker Sequence_increment_tkr
 # Sequence IO & interrupts
int Seq_current_inst = 0
 # flags & variables
int Seq_current_seq = 0
 currently selected sequence
int Seq_prev_inst = 0
 previously selected instrument channel (used when skip button is pressed)
int Seq_current_step = 15
 current sequence step
volatile int Seq_flag = 0
 flag to indicate step increment
float tempo = 60
 current tempo value
bool running = 1
 flag to indicate if the sequence is currently running
bool inst_flag = 0
 indicates whether system is waiting for instrument channel selection
bool pattern_flag = 0
 indicates whether system is waiting for sequence pattern selection
bool skip_flag = 0
 indicates whether in skip setup mode

Detailed Description

Variables and functions used to adress the step sequencer.


Function Documentation

void Sequence_increment (  )

increments sequencer

update LED matrix

update outputs

midi output

audio output

trigger output

no output

update step position display

set tempo

detach increment ticker

Definition at line 337 of file main.cpp.

void Sequence_increment_ISR (  )

interrupt call for sequence increment

Definition at line 332 of file main.cpp.

void Sequence_init (  )

# Sequence functions

initialises sequencer

Definition at line 328 of file main.cpp.

void Sequence_write (  )

writes input data to sequence gate

Definition at line 378 of file main.cpp.


Variable Documentation

bool inst_flag = 0

indicates whether system is waiting for instrument channel selection

Definition at line 320 of file main.h.

char* inst_names[]
Initial value:
 {
    "Kick",
    "Snare",
    "Crash",
    "HH Cl",
    "HH Op",
    "Clap",
    "Ride",
    "Cowbl",
    "Skip"
}

# Sequence data

channel names (to be displayed to LCD)

Definition at line 240 of file main.h.

bool pattern_flag = 0

indicates whether system is waiting for sequence pattern selection

Definition at line 322 of file main.h.

bool running = 1

flag to indicate if the sequence is currently running

Definition at line 318 of file main.h.

# flags & variables

currently selected instrument channel

Definition at line 306 of file main.h.

int Seq_current_seq = 0

currently selected sequence

Definition at line 308 of file main.h.

int Seq_current_step = 15

current sequence step

Definition at line 312 of file main.h.

volatile int Seq_flag = 0

flag to indicate step increment

Definition at line 314 of file main.h.

int Seq_prev_inst = 0

previously selected instrument channel (used when skip button is pressed)

Definition at line 310 of file main.h.

# Sequence IO & interrupts

ticker to increment sequence position

Definition at line 301 of file main.h.

bool skip_flag = 0

indicates whether in skip setup mode

Definition at line 324 of file main.h.

float tempo = 60

current tempo value

Definition at line 316 of file main.h.