ELEC2645 (2015/16) / Mbed 2 deprecated Main_code_ver18

Dependencies:   FATFileSystem N5110_mod SDFileSystem USBDevice mbed

Embed: (wiki syntax)

« Back to documentation index

LED matrix

LED matrix

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

Namespaces

namespace  shift_LED
 

LED above the shift button on the PCB.


namespace  LED_buffer
 

# Flags, maps & variables


namespace  LED_pos
 

stores the current position of the LED_bus scan, in order to select the correct value for the output from the LED_buffer array


namespace  LED_write
 

updates the values within LED_buffer to those required for the current output


Functions

BusOut LED_bus (PTC0, PTC9, PTC5, PTC7, PTC2, PTA2, PTB23, PTA1)
 # IO & interrupts
void LED_scan_ISR ()
 # LED functions
void LED_write (uint16_t value)
 Matrix refresh routine.
void LED_init ()
 initialises LEDs

Variables

Ticker LED_scan_tkr
 ticker used to scan through the LED matrix values

Detailed Description

Variables and functions used to adress the step LEDs.


Function Documentation

BusOut LED_bus ( PTC0  ,
PTC9  ,
PTC5  ,
PTC7  ,
PTC2  ,
PTA2  ,
PTB23  ,
PTA1   
)

# IO & interrupts

bus used to adress the LED matrix

void LED_init (  )

initialises LEDs

Setup matrix scan ticker

output values for test

scan through output test values

clear shift LED

Definition at line 262 of file main.cpp.

void LED_scan_ISR (  )

# LED functions

ISR for LED matrix scan

Sends buffer value to bus output

Increment scan position

limit range

Definition at line 274 of file main.cpp.

void LED_write ( uint16_t  value )

Matrix refresh routine.

initialise LED_loadBuffer

Run loop 4 times

write LED_loadBuffer nibble to FSM

Rotate row

rotate LED_loadBuffer

Definition at line 280 of file main.cpp.


Variable Documentation

Ticker LED_scan_tkr

ticker used to scan through the LED matrix values

Definition at line 154 of file main.h.