
#ifndef _SCREG_H_
#define _SCREG_H_

#include "my_interfaces.h"
#include "systemc.h"
#include "global.h"
#include "secbus_lib.h"


SC_MODULE(DataRegister)
{
	public:

	sc_in<bool> clk;
	sc_in<bool> reset;

	//register inputs
	DATA_REGISTER_WRITE_IN in;
	//register outputs
	DATA_REGISTER_READ_OUT out;

	sc_signal<int> *data_s;
	sc_signal<unsigned int>	be_s;
	sc_signal<addr_t>	address_s;

	//synchrone process
	void ps();
	//comb process
	void pc();

	ofstream *output;

	//Constructor
	DataRegister(sc_module_name name, ofstream * file);

	SC_HAS_PROCESS(DataRegister);


};
#endif


