public GuiWindow() {
		try {
            for (LookAndFeelInfo info : UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (Exception e) {
            // If Nimbus is not available, you can set the GUI to another look and feel.
        }
		setIconImage(Toolkit.getDefaultToolkit().getImage(GuiWindow.class.getResource("/com/sun/java/swing/plaf/windows/icons/Computer.gif")));
		setResizable(false);
		setTitle("Beyond Sol - CPU Emulator");
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setBounds(100, 100, 655, 650);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		contentPane.setLayout(new BorderLayout(0, 0));
		setContentPane(contentPane);
		
		ScreenPeripheral sc = new ScreenPeripheral();
		contentPane.add(sc, BorderLayout.CENTER);
		sc.init();
		sc.start();
		
		JPanel panel = new JPanel();
		contentPane.add(panel, BorderLayout.EAST);
		panel.setLayout(new MigLayout("", "[]", "[][][][][][][][][][][][][][]"));
		
		Component horizontalStrut = Box.createHorizontalStrut(90);
		panel.add(horizontalStrut, "cell 0 0,alignx center,aligny center");
		
		Component verticalStrut_3 = Box.createVerticalStrut(20);
		panel.add(verticalStrut_3, "cell 0 1,alignx center,aligny center");
		
		JLabel lblProgram = new JLabel("Program");
		lblProgram.setFont(new Font("Tahoma", Font.BOLD, 14));
		panel.add(lblProgram, "cell 0 2,alignx center,aligny center");
		
		lblLoaded = new JLabel("Not Loaded");
		lblLoaded.setForeground(Color.RED);
		panel.add(lblLoaded, "cell 0 3,alignx center,aligny center");
		
		JButton btnOpen = new JButton("Open");
		btnOpen.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				//load program
				 JFileChooser chooser = new JFileChooser();
				 FileNameExtensionFilter filter = new FileNameExtensionFilter("Beyond Sol Programs", "bsol");
				    chooser.setFileFilter(filter);
				    int returnVal = chooser.showOpenDialog(getParent());
				    if(returnVal == JFileChooser.APPROVE_OPTION) {
				    	try {
							Loader.loadFile(chooser.getSelectedFile().getPath());
						} catch (IOException e1) {
							e1.printStackTrace();
						}
				    }
			}
		});
		panel.add(btnOpen, "cell 0 4,alignx center,aligny center");
		
		JButton btnRun = new JButton("Run");
		btnRun.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent arg0) {
				if(!Loader.loaded){
					Except.emulator.noFileLoaded();
				}
				Executer.execute(Loader.file);
			}
		});
		panel.add(btnRun, "cell 0 5,alignx center,aligny center");
		
		JButton btnReset = new JButton("Reset");
		btnReset.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				Executer.stop();
				Executer.clear();
				Executer.execute(Loader.file);
			}
		});
		panel.add(btnReset, "cell 0 6,alignx center,aligny center");
		
		JButton btnKill = new JButton("Kill");
		btnKill.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent arg0) {
				Executer.stop();
			}
		});
		panel.add(btnKill, "cell 0 7,alignx center,aligny center");
		
		Component verticalStrut_1 = Box.createVerticalStrut(20);
		panel.add(verticalStrut_1, "cell 0 8,alignx center");
		
		JLabel lblStatus = new JLabel("Status");
		lblStatus.setFont(new Font("Tahoma", Font.BOLD, 14));
		panel.add(lblStatus, "cell 0 9,alignx center,aligny center");
		
		JLabel lblStopped = new JLabel("Stopped");
		lblStopped.setForeground(Color.RED);
		panel.add(lblStopped, "cell 0 10,alignx center,aligny center");
		
		Component verticalStrut_2 = Box.createVerticalStrut(50);
		panel.add(verticalStrut_2, "cell 0 11,alignx center,aligny center");
		
		JButton btnClearLog = new JButton("Clear Log");
		btnClearLog.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent arg0) {
				textArea.setText("");
			}
		});
		panel.add(btnClearLog, "cell 0 12,alignx center,aligny center");
		
		JPanel panel_1 = new JPanel();
		contentPane.add(panel_1, BorderLayout.SOUTH);
		panel_1.setLayout(new MigLayout("", "[][grow]", "[grow]"));
		
		Component verticalStrut = Box.createVerticalStrut(80);
		panel_1.add(verticalStrut, "cell 0 0");
		
		JScrollPane scrollPane = new JScrollPane();
		panel_1.add(scrollPane, "cell 1 0,grow");
		
		textArea = new JTextPane();
		textArea.setEditable(false);
		scrollPane.setViewportView(textArea);
		
	}