Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Notifications
Login / Register
Community
Community
Notifications
close
  • Forums
  • Knowledge Center
  • Events & Webinars
  • Ideas
  • Blogs
Help
Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Login / Register
Sustainability
Sustainability

We Value Your Feedback!
Could you please spare a few minutes to share your thoughts on Cloud Connected vs On-Premise Services. Your feedback can help us shape the future of services.
Learn more about the survey or Click here to Launch the survey
Schneider Electric Services Innovation Team!

Cold Room control

HVAC and Pumping Forum

Support Forum for HVAC and pumping machines, Modicon M17x and EcoStruxure Machine Expert HVAC software for chillers, AHU, CRAC units for datacenters or process chillers applications - from design, implementation to troubleshooting and more, by Schneider Electric.

cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Home
  • Schneider Electric Community
  • Industrial Automation
  • HVAC and Pumping Forum
  • Cold Room control
Options
  • Subscribe to RSS Feed
  • Mark Topic as New
  • Mark Topic as Read
  • Float this Topic for Current User
  • Bookmark
  • Subscribe
  • Mute
  • Printer Friendly Page
Invite a Co-worker
Send a co-worker an invite to the portal.Just enter their email address and we'll connect them to register. After joining, they will belong to the same company.
You have entered an invalid email address. Please re-enter the email address.
This co-worker has already been invited to the Exchange portal. Please invite another co-worker.
Please enter email address
Send Invite Cancel
Invitation Sent
Your invitation was sent.Thanks for sharing Exchange with your co-worker.
Send New Invite Close
Top Experts
User Count
FedericoM
Commander FedericoM Commander
68
Bastian_Schmitz
Admiral Bastian_Schmitz Admiral
47
LeTomas
Lt. Commander LeTomas Lt. Commander
14
View All
Related Products
product field
Schneider Electric
EcoStruxure™ Machine Expert - HVAC

Invite a Colleague

Found this content useful? Share it with a Colleague!

Invite a Colleague Invite
Back to HVAC and Pumping Forum
otrotabi
Lt. Commander otrotabi
Lt. Commander

Posted: ‎2022-10-19 01:04 PM

0 Likes
2
869
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2022-10-19 01:04 PM

Cold Room control

While most of our uses of the TM171/TM172 line have been on chillers, we do from time to time need to apply them to a cold room where there´s a need to perform a time-based or temperature-based evaporator defrost strategy, besides controlling cold room temperature.

 

A typical cycle goes like this:

 

cycle.jpg

F19, F47,F13 are temperature variables and F20, F45, F44, F14 and F18 are time variables. 

 

Is there any function block or program developed for this use ? 

Labels
  • Labels:
  • HVAC
  • Tags:
  • ecostruxure
  • english
  • hvac
  • TM171
  • TM172
Reply

Link copied. Please paste this link to share this article on your social media post.

  • All forum topics
  • Previous Topic
  • Next Topic
Replies 2
Bastian_Schmitz
Admiral Bastian_Schmitz Admiral
Admiral

Posted: ‎2022-10-19 10:12 PM

0 Likes
1
860
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2022-10-19 10:12 PM

Hi, 

Try this code.

 

FUNCTION_BLOCK FB_Defrost

VAR
	t_udiTime : UDINT;
	t_xDefrost_1_active : BOOL;
	t_xDefrost_2_active : BOOL;
	t_xDefrost_3_active : BOOL;
	t_xDefrost_4_active : BOOL;
	TON_defrost_time_1 : TON;	(* Timer Abtaudauer #1 *)
	TON_defrost_time_2 : TON;	(* Timer Abtaudauer #2 *)
	TON_defrost_time_3 : TON;	(* Timer Abtaudauer #3 *)
	TON_defrost_time_4 : TON;	(* Timer Abtaudauer #4 *)
	TON_defrost_time_manual : TON;	(* Timer Abtaudauer Manuell *)
	R_TRIG_manual_defrost : R_TRIG;	(* Flanken Auswertung Start Abtauung Manuell *)
	t_xDefrost_manual_active : BOOL;
	F_TRIG_defrost_1 : F_TRIG;	(* Flanken Auswertung Ende Abtauung 1 *)
	F_TRIG_defrost_2 : F_TRIG;	(* Flanken Auswertung Ende Abtauung 2 *)
	F_TRIG_defrost_3 : F_TRIG;	(* Flanken Auswertung Ende Abtauung 3 *)
	F_TRIG_defrost_4 : F_TRIG;	(* Flanken Auswertung Ende Abtauung 4 *)
	F_TRIG_defrost_manual : F_TRIG;	(* Flanken Auswertung Ende Abtauung 5 *)
	TP_drain_time : TP;	(* Puls Timer Abtropfzeit *)
	F_TRIG_drain_time : F_TRIG;	(* Flanken Auswertung Ende Abtauung 5 *)
	Thermostat_defrost1 : FB_Thermostat;	(* Thermstat Abtauendtemperatur *)
	Thermostat_defrost2 : FB_Thermostat;	(* Thermstat Abtauendtemperatur *)
	Thermostat_defrost3 : FB_Thermostat;	(* Thermstat Abtauendtemperatur *)
	Thermostat_defrost4 : FB_Thermostat;	(* Thermstat Abtauendtemperatur *)
	Thermostat_defrost5 : FB_Thermostat;	(* Thermstat Abtauendtemperatur *)
END_VAR

VAR_INPUT
	xActive : BOOL;
	iAV_coil_temperature : INT;	(* Verdampfer Paket Temperatur *)
	iSP_defrost_endtemperature : INT;	(* Sollwert Abtauendtemperatur *)
	iHYS_defrost_endtemperature : INT;	(* Hysterese Abtauendtemperatur *)
	xDefrost_manual : BOOL;	(* Handabtauung (Flanke wird ausgewertet) *)
	xStop_manual_defrost : BOOL;
	xDefrost_blocked : BOOL;	(* Abtauung geblockt (Wenn Froster Modus) *)
	udiDefrost_time_1 : UDINT;	(* Uhrzeit für Abtauung #1 HH:MM *)
	uiDefrost_duration_1 : UINT;	(* Abtaudauer Abtauung #1 [min] *)
	udiDefrost_time_2 : UDINT;	(* Uhrzeit für Abtauung #2 HH:MM *)
	uiDefrost_duration_2 : UINT;	(* Abtaudauer Abtauung #2 [min] *)
	udiDefrost_time_3 : UDINT;	(* Uhrzeit für Abtauung #3 HH:MM *)
	uiDefrost_duration_3 : UINT;	(* Abtaudauer Abtauung #3 [min] *)
	udiDefrost_time_4 : UDINT;	(* Uhrzeit für Abtauung #4 HH:MM *)
	uiDefrost_duration_4 : UINT;	(* Abtaudauer Abtauung #4 [min] *)
	uiDefrost_duration_manual : UINT;	(* Abtaudauer Abtauung Hand [min] *)
	uiDrain_time : UINT;	(* Abtropfzeit [s] *)
END_VAR

VAR_OUTPUT
	xDefrost_heater : BOOL;	(* TRUE wenn Heizung aktiv *)
	xDrain_time_active : BOOL;	(* TRUE wenn abtropfzeit aktiv *)
	uiRest_time_defrost : UINT;	(* Restlaufzeit der Abtauung *)
	uiRest_time_drain : UINT;
	xDefrost_finished : BOOL := TRUE;	(* TRUE wenn kühlung aktiv werden kann und abtauung beendet *)
	uiLast_defrost_time : UINT;
END_VAR

VAR_EXTERNAL
	sysClock : TypeDataTime;	(* System Date and Time Read. It is a structure of type TypeDataTime composed 
by the following fields:
	seconds		: USINT; seconds [0...59]
	minutes		: USINT; minutes [0...59] 
	hours		: USINT; hours [0...23]
	dayweek		: USINT; day of week [0...6]
	daymonth		: USINT; day of month [1...31]
	month		: USINT; month [1...12]
	year		: USINT; year [10...99] *)
END_VAR

 

IF xActive
THEN


t_udiTime	:=	(TO_UDINT(sysClock.hours)*3600)+TO_UDINT(sysClock.minutes*60);

//Initialisiation defrost duration timer
TON_defrost_time_1();
TON_defrost_time_1.PT		:=	F_MUL1K(uiDefrost_duration_1)*60;
TON_defrost_time_2();
TON_defrost_time_2.PT		:=	F_MUL1K(uiDefrost_duration_2)*60;
TON_defrost_time_3();
TON_defrost_time_3.PT		:=	F_MUL1K(uiDefrost_duration_3)*60;
TON_defrost_time_4();
TON_defrost_time_4.PT		:=	F_MUL1K(uiDefrost_duration_4)*60;
TON_defrost_time_manual();
TON_defrost_time_manual.PT	:=	F_MUL1K(uiDefrost_duration_manual)*60;
R_TRIG_manual_defrost();
R_TRIG_manual_defrost.clk	:=	xDefrost_manual;

//Initialisiation defrost thermostat
Thermostat_defrost1();
Thermostat_defrost1.iActualvalue:=	iAV_coil_temperature;
Thermostat_defrost1.iHysteresis	:=	iHYS_defrost_endtemperature;
Thermostat_defrost1.iSetpoint	:=	iSP_defrost_endtemperature;
Thermostat_defrost1.xMode		:=	FALSE;
Thermostat_defrost1.xActive		:=	t_xDefrost_1_active;

Thermostat_defrost2();
Thermostat_defrost2.iActualvalue:=	iAV_coil_temperature;
Thermostat_defrost2.iHysteresis	:=	iHYS_defrost_endtemperature;
Thermostat_defrost2.iSetpoint	:=	iSP_defrost_endtemperature;
Thermostat_defrost2.xMode		:=	FALSE;
Thermostat_defrost2.xActive		:=	t_xDefrost_2_active;

Thermostat_defrost3();
Thermostat_defrost3.iActualvalue:=	iAV_coil_temperature;
Thermostat_defrost3.iHysteresis	:=	iHYS_defrost_endtemperature;
Thermostat_defrost3.iSetpoint	:=	iSP_defrost_endtemperature;
Thermostat_defrost3.xMode		:=	FALSE;
Thermostat_defrost3.xActive		:=	t_xDefrost_3_active;

Thermostat_defrost4();
Thermostat_defrost4.iActualvalue:=	iAV_coil_temperature;
Thermostat_defrost4.iHysteresis	:=	iHYS_defrost_endtemperature;
Thermostat_defrost4.iSetpoint	:=	iSP_defrost_endtemperature;
Thermostat_defrost4.xMode		:=	FALSE;
Thermostat_defrost4.xActive		:=	t_xDefrost_4_active;

Thermostat_defrost5();
Thermostat_defrost5.iActualvalue:=	iAV_coil_temperature;
Thermostat_defrost5.iHysteresis	:=	iHYS_defrost_endtemperature;
Thermostat_defrost5.iSetpoint	:=	iSP_defrost_endtemperature;
Thermostat_defrost5.xMode		:=	FALSE;
Thermostat_defrost5.xActive		:=	t_xDefrost_manual_active;


//drain time
F_TRIG_defrost_1();
F_TRIG_defrost_2();
F_TRIG_defrost_3();
F_TRIG_defrost_4();
F_TRIG_defrost_manual();
F_TRIG_drain_time();

F_TRIG_defrost_1.clk		:=	t_xDefrost_1_active;
F_TRIG_defrost_2.clk		:=	t_xDefrost_2_active;
F_TRIG_defrost_3.clk		:=	t_xDefrost_3_active;
F_TRIG_defrost_4.clk		:=	t_xDefrost_4_active;
F_TRIG_defrost_manual.clk	:=	t_xDefrost_manual_active;
F_TRIG_drain_time.clk		:=	TP_drain_time.Q;

TP_drain_time();
TP_drain_time.PT			:=	1+ F_MUL1K(uiDrain_time);

xDrain_time_active			:=	TO_BOOL(TP_drain_time.ET);

TP_drain_time.IN			:=	F_TRIG_defrost_1.q	OR
								F_TRIG_defrost_2.q	OR
								F_TRIG_defrost_3.q	OR
								F_TRIG_defrost_4.q	OR
								F_TRIG_defrost_manual.q;
								
IF	TP_drain_time.Q	
THEN
	uiRest_time_drain		:=	F_DIV1K(TP_drain_time.PT	-	TP_drain_time.ET);
ELSE
	uiRest_time_drain		:=	0;
END_IF;		

IF NOT xDefrost_blocked
THEN
	//start Defrost cycle 1
	IF (t_udiTime	= udiDefrost_time_1) AND TON_defrost_time_1.PT>0
	THEN
	t_xDefrost_1_active	:= TRUE;
	END_IF;	

	//start Defrost cycle 2
	IF (t_udiTime	= udiDefrost_time_2) AND TON_defrost_time_2.PT>0
	THEN
	t_xDefrost_2_active	:= TRUE;
	END_IF;	

	//start Defrost cycle 3
	IF (t_udiTime	= udiDefrost_time_3) AND TON_defrost_time_3.PT>0
	THEN
	t_xDefrost_3_active	:= TRUE;
	END_IF;	

	//start Defrost cycle 4
	IF (t_udiTime	= udiDefrost_time_4) AND TON_defrost_time_4.PT>0
	THEN
	t_xDefrost_4_active	:= TRUE;
	END_IF;	

	//Defrost Manual
	IF R_TRIG_manual_defrost.q AND TON_defrost_time_manual.PT>0
	THEN
	t_xDefrost_manual_active	:= TRUE;
	END_IF;
ELSE
t_xDefrost_1_active			:=	FALSE;
t_xDefrost_2_active			:=	FALSE;
t_xDefrost_3_active			:=	FALSE;
t_xDefrost_4_active			:=	FALSE;
t_xDefrost_manual_active	:=	FALSE;
	
END_IF;

//Defrost #1 function

IF t_xDefrost_1_active  
THEN
	TON_defrost_time_1.IN	:= TRUE;
	uiRest_time_defrost		:= F_DIV1K(TON_defrost_time_1.PT-TON_defrost_time_1.ET);
ELSE
	TON_defrost_time_1.IN	:= FALSE;
END_IF;

//Defrost #2 function

IF t_xDefrost_2_active  
THEN
	TON_defrost_time_2.IN	:= TRUE;
	uiRest_time_defrost		:= F_DIV1K(TON_defrost_time_2.PT-TON_defrost_time_2.ET);	
ELSE
	TON_defrost_time_2.IN	:= FALSE;
END_IF;

//Defrost #3 function

IF t_xDefrost_3_active  
THEN
	TON_defrost_time_3.IN	:= TRUE;
	uiRest_time_defrost		:= F_DIV1K(TON_defrost_time_3.PT-TON_defrost_time_3.ET);	
ELSE
	TON_defrost_time_3.IN	:= FALSE;
END_IF;

//Defrost #4 function

IF t_xDefrost_4_active  
THEN
	TON_defrost_time_4.IN	:= TRUE;
	uiRest_time_defrost		:= F_DIV1K(TON_defrost_time_4.PT-TON_defrost_time_4.ET);
ELSE
	TON_defrost_time_4.IN	:= FALSE;
END_IF;

//Defrost maunal function

IF t_xDefrost_manual_active AND NOT xStop_manual_defrost 
THEN
	TON_defrost_time_manual.IN	:= TRUE;
	uiRest_time_defrost			:= F_DIV1K(TON_defrost_time_manual.PT-TON_defrost_time_manual.ET);	
ELSE
	TON_defrost_time_manual.IN	:= FALSE;
END_IF;
	

// Start defrost heater	
IF t_xDefrost_1_active OR t_xDefrost_2_active OR t_xDefrost_3_active OR t_xDefrost_4_active	OR t_xDefrost_manual_active 
THEN
	xDefrost_heater			:=	TRUE;
	xDefrost_finished		:=	FALSE;
	
ELSE
		IF F_TRIG_drain_time.q
		THEN
		xDefrost_finished	:=	TRUE;
		xDrain_time_active  := False;
		END_IF;		
	xDefrost_heater			:=	FALSE;
	uiRest_time_defrost		:=	0;
END_IF;


// Deactivating defrosting


IF TON_defrost_time_1.Q OR Thermostat_defrost1.xOutput_Active
THEN
	uiLast_defrost_time		:=	TO_UINT(TON_defrost_time_1.ET/1000);
	t_xDefrost_1_active		:= 	FALSE;
	t_xDefrost_1_active		:=	FALSE;
	
END_IF;

IF TON_defrost_time_2.Q OR Thermostat_defrost2.xOutput_Active
	THEN
	uiLast_defrost_time		:=	TO_UINT(TON_defrost_time_2.ET/1000);	
	t_xDefrost_2_active		:= 	FALSE;
	t_xDefrost_2_active		:=	FALSE;	
END_IF;

IF TON_defrost_time_3.Q OR Thermostat_defrost3.xOutput_Active
	THEN
	uiLast_defrost_time		:=	TO_UINT(TON_defrost_time_3.ET/1000);	
	t_xDefrost_3_active		:= 	FALSE;
	t_xDefrost_3_active		:=	FALSE;
END_IF;

IF TON_defrost_time_4.Q OR Thermostat_defrost4.xOutput_Active
	THEN
	uiLast_defrost_time		:=	TO_UINT(TON_defrost_time_4.ET/1000);	
	t_xDefrost_4_active		:= 	FALSE;
	t_xDefrost_4_active		:=	FALSE;	
END_IF;	

IF TON_defrost_time_manual.Q OR Thermostat_defrost5.xOutput_Active
	THEN
	uiLast_defrost_time		:=	TO_UINT(TON_defrost_time_manual.ET/1000);	
	t_xDefrost_manual_active:= 	FALSE;
	t_xDefrost_manual_active:=	FALSE;	
END_IF;	




ELSE
xDefrost_heater			:= FALSE;
xDrain_time_active		:= FALSE;
xDefrost_finished		:= True;
uiRest_time_defrost		:= 0;
uiRest_time_drain		:= 0;
TON_defrost_time_manual.PT	:= 0;


END_IF;

Maybe not the best code.

But a customer use it since a few years in a serial buisness.

You could use Deepl.com to translate the comments.

 

best regards

 

Attachments
Defrost.zip
  • Tags:
  • Defrost
  • english
  • ESME HVAC
  • TM172
Reply

Link copied. Please paste this link to share this article on your social media post.

otrotabi
Lt. Commander otrotabi
Lt. Commander

Posted: ‎2022-10-20 04:06 AM

In response to Bastian_Schmitz
0 Likes
0
852
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2022-10-20 04:06 AM

Thanks for your feedback. I do know some German so it will help me practice a little bit 😅.

 

It is interesting to see a state machine (a CASE structure) is not used here. 

 

I will give it a try and see how it goes. I assume you would use the boolean outputs to disable compressor if electrical defrost is used?

 

 

 

 

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

Preview Exit Preview

never-displayed

You must be signed in to add attachments

never-displayed

 
To The Top!

Forums

  • APC UPS Data Center Backup Solutions
  • EcoStruxure IT
  • EcoStruxure Geo SCADA Expert
  • Metering & Power Quality
  • Schneider Electric Wiser

Knowledge Center

Events & webinars

Ideas

Blogs

Get Started

  • Ask the Community
  • Community Guidelines
  • Community User Guide
  • How-To & Best Practice
  • Experts Leaderboard
  • Contact Support
Brand-Logo
Subscribing is a smart move!
You can subscribe to this board after you log in or create your free account.
Forum-Icon

Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.

Register today for FREE

Register Now

Already have an account? Login

Terms & Conditions Privacy Notice Change your Cookie Settings © 2025 Schneider Electric

This is a heading

With achievable small steps, users progress and continually feel satisfaction in task accomplishment.

Usetiful Onboarding Checklist remembers the progress of every user, allowing them to take bite-sized journeys and continue where they left.

of