Commit 60597f4e authored by Ozmen O's avatar Ozmen O
Browse files

Tmin and Tmax are added

parent 257b1ca2
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -66,6 +66,10 @@ class FMUModel:
			std::ostringstream strs;
			if (request == "HVAC"){
				strs << ((get_home1_y()*9/5)+32); // get home temperature
				strs << ",";
				strs << get_home1_Tmin(); // These will be assigned from a schedule file
				strs << ",";
				strs << get_home1_Tmax();
				str = strs.str();
	                        str = str+"\n";
			}
@@ -97,7 +101,7 @@ class FMUModel:
				str = strs.str();
				str = str+"\n";
			}
			char* buffer = new char[str.length()];
			char* buffer = new char[str.length()+1];
			strcpy(buffer, str.c_str());
			computer_io_type* c = new computer_io_type(buffer,str.length());
			IO_Type out(send,c);
+6 −2
Original line number Diff line number Diff line
@@ -10,7 +10,7 @@ using namespace std;
using namespace adevs;

// Number of computers to connect via network **************************************************************
const int numComputers = 8;
const int numComputers = 9;

class FMUModel:
	public TransactiveSystemWholeSystem
@@ -66,6 +66,10 @@ class FMUModel:
			std::ostringstream strs;
			if (request == "HVAC"){
				strs << ((get_home1_y()*9/5)+32); // get home temperature
				strs << ",";
				strs << get_home1_Tmin(); // These will be assigned from a schedule file
				strs << ",";
				strs << get_home1_Tmax();
				str = strs.str();
	                        str = str+"\n";
			}
@@ -97,7 +101,7 @@ class FMUModel:
				str = strs.str();
				str = str+"\n";
			}
			char* buffer = new char[str.length()];
			char* buffer = new char[str.length()+1];
			strcpy(buffer, str.c_str());
			computer_io_type* c = new computer_io_type(buffer,str.length());
			IO_Type out(send,c);
+289 −285

File changed.

Preview size limit exceeded, changes collapsed.

Loading