#include "aero_doc.h"
#include "MainWindow.h"
#include <QApplication>
#include <QTimer>
#include <QtWidgets/QApplication>
#include <wiringPi.h>
#include <wiringSerial.h>

int main(int argc, char *argv[])
{
	if (wiringPiSetup() == -1)
	{
		fprintf(stdout, "Unable to start wiringPi: %s\n", strerror(errno));
		return 1;
	}
	///PIN SETUP
	wiringPiSetupGpio();
	pinMode(LS1,INPUT);
	pinMode(LS2,INPUT);
	pinMode(LS3,INPUT);
	pinMode(RL1, OUTPUT);
	pinMode(RL2, OUTPUT);
	pinMode(RL3, OUTPUT);
	pinMode(RL4, OUTPUT);
	pinMode(RL5, OUTPUT);
	pinMode(RL6, OUTPUT);
	pinMode(RL7, OUTPUT);
	pinMode(RL8, OUTPUT);
	pinMode(18, PWM_OUTPUT);
	digitalWrite(RL1, HIGH);
	digitalWrite(RL2, HIGH);
	digitalWrite(RL3, HIGH);
	digitalWrite(RL4, HIGH);
	digitalWrite(RL5, HIGH);
	digitalWrite(RL6, HIGH);
	digitalWrite(RL7, HIGH);
	digitalWrite(RL8, HIGH);
	///
	
	QApplication a(argc, argv);
	MainWindow w;
	w.setWindowState(Qt::WindowFullScreen);
	w.show();
    
	return a.exec();
}
