Proj 324 Final

Fork of ELEC351_Group_T by Plymouth ELEC351 Group T

SETUP.hpp

Committer:
thomasmorris
Date:
2018-07-16
Revision:
56:bc5345bc6650
Parent:
55:e0e684531825
Child:
57:aba1296e51b1

File content as of revision 56:bc5345bc6650:

/*
Setup file for the main
*/

#ifndef SETUP_HPP//Header Guards Prevents Multiple includes
#define SETUP_HPP

//Libraries and header includes
#include "rtos.h"
#include "LED.hpp"
#include "SERIAL.hpp"
#include "TIME.hpp"
#include "SERIAL_COMMANDS.hpp"
#include "THREADS.hpp"
#include "LED_LOGGING.hpp"
#include "STEPPER_MOTOR.hpp"
#include "SPI.hpp"
#include "ALGORITHM.hpp"
#include <iostream>
#include <bitset>

using namespace std;
//Time definitions


LED Red_led(PE_15);
LED Green_led(PB_11);

//Forward Declarations of functions

void Serial_Comms();
void Console_Output_ISR();    
void Serial_Comms_Data_Get();
void Console_Output_ISR();
void Rotate_Steps();

//Object creations
static STEPPER_MOTOR STEPPER_MOTOR_1(D0,D1);//step then direction
static STEPPER_MOTOR STEPPER_MOTOR_2(D2,D3);//step then direction
static STEPPER_MOTOR STEPPER_MOTOR_3(D4,D5);//step then direction
static STEPPER_MOTOR STEPPER_MOTOR_4(D6,D7);//step then direction
static STEPPER_MOTOR STEPPER_MOTOR_5(D8,D9);//step then direction
static STEPPER_MOTOR STEPPER_MOTOR_6(D10,D11);//step then direction

//Sets up the sides of the cube
static SIDE SIDE1();
static SIDE SIDE2();
static SIDE SIDE3();
static SIDE SIDE4();
static SIDE SIDE5();
static SIDE SIDE6();


/*
0 White
1 Orange
2 Blue
3 Red
4 Green
5 Yellow
These are the faces of the cube then there are the 3x3 cubelets within each face
*/

#endif