저작자표시 2.0 대한민국 이용자는 아래의 조건을 따르는 경우에 한하여 자유롭게 l 이 저작물을 복제, 배포, 전송, 전시, 공연 및 방송할 수 있습니다. l 이차적 저작물을 작성할 수 있습니다. l 이 저작물을 영리 목적으로 이용할 수 있습니다. 다음과 같은 조건을 따라야 합니다: l 귀하는, 이 저작물의 재이용이나 배포의 경우, 이 저작물에 적용된 이용허락조건 을 명확하게 나타내어야 합니다. l 저작권자로부터 별도의 허가를 받으면 이러한 조건들은 적용되지 않습니다. 저작권법에 따른 이용자의 권리는 위의 내용에 의하여 영향을 받지 않습니다. 이것은 이용허락규약(Legal Code)을 이해하기 쉽게 요약한 것입니다. Disclaimer 저작자표시. 귀하는 원저작자를 표시하여야 합니다.
1
A DISSERTATION FOR
THE DEGREE OF DOCTOR OF PHILOSOPHY
Novel Platform for the Development of
Refrigerator Operating Software Using
Virtualization, Automation, and
Remote Control
냉장고 운영 소프트웨어 개발을 위한
가상화, 자동화, 원격제어 기반의 플랫폼 구축
February, 2014
Department of Agricultural Biotechnology
Seoul National University
Sang Oh Kim
2
Novel Platform for the Development of Refrigerator Operating Software Using Virtualization, Automation, and Remote Control
냉장고 운영 소프트웨어 개발을 위한 가상화, 자동화, 원격제어 기반의 플랫폼 구축 지도교수 최 영 진 이 논문을 박사학위논문으로 제출함 2012 년 10 월 서울대학교 대학원 농생명공학부 김 상 오 김상오의 박사학위논문을 인준함 2013 년 1 월 위 원 장 장 판 식 (인) 부위원장 최 영 진 (인) 위 원 강 동 현 (인) 위 원 김 용 노 (인) 위 원 고 상 훈 (인)
3
Novel Platform for the Development of Refrigerator
Operating Software Using Virtualization, Automation,
and Remote Control
By
Sang Oh Kim
Department of Agricultural Biotechnology
Seoul National University
i
Abstract
Food is material mainly consisting of protein, carbohydrate, and fat used
in the body of an organism to sustain processes essential for growth,
recovery and life support and to furnish energy. In general, food is obtained
through collecting plants or animals, hunting, farming and livestock breeding.
Various methods have been developed and implemented to preserve food for
a long period of time. The most common way to preserve food almost in the
raw is to use a refrigerator or a freezer.
Currently, most freezers are operated after installing hardware and then
software. And, in the current development process, it is very difficult to
verify software before hardware is completely developed. In order to solve
this problem, this study is to seek and establish an environment where
software can be developed and verified by reflecting both values of the
virtual environment simulation and the freezer emulation.
One of the requirements of a competitive and favored freezer wanted by
customers is low electric power consumption. Some countries restrict the
amount of energy consumed and prevent the sales of the home appliance
with energy consumption exceeding the standards. In order to optimize the
electric power consumption, many tests should be conducted by changing
ii
and human resources and time can be wasted during the process. To solve
this problem, software which is developed in the virtual environment will be
ported into an actual freezer, and the optimized parameter will be found
through an automatic experiment solution.
Even though the refrigerator was developed though the perfect processes
stated above, and all the required tests were executed under the strict test
condition, unexpected errors can appear when it is used by consumers in the
real environment. In an effort to analyze these errors, data from the initial
products is collected for a certain period of time. However, it is hard to
respond to problems in real time with a method of collecting data only after
problems are found. Therefore, data will be analyzed in real time, and errors
will be responded through the remote monitoring method. Also, this big data
will be reflected in the better user experience (UX) of the next- generation
refrigerator.
Studies on new methods to develop a refrigerator and a freezer were
executed well, and in the future, this technique will be applied to diverse
home appliances and will provide the better to the customers.
Key Words: Refrigerator, Freezer, Simulation, Emulation, Virtualization,
Optimization, Automation, Electric Power Consumption, Remote Control,
iii Student number: 2000-30735
iv
CONTENTS
ABSTRACT...i CONTENTS...iv LIST OF TABLES...x LIST OF FIGURES...xi CHAPTER 1 Freezer Program Emulation Method in the Virtual Simulation Environment Using Virtual Product Software Development Process (VPSDP) Abstract...2I. Introduction...4
1.1. Review...4
1.2. Environmental virtualization...8
1.3. The objective of this study...12
I I . M a t e r i a l s a n d M e t h o d s . . . 2 0 2.1. Model system and equations...20
2.2. The characteristics of the air and equations...27
2.3. Designable food and equations...29
2.4. Experimental system configuration...32 2 . 5 . Vi r t u a l i z a t i o n c o n c e p t . . . 4 0 2 . 6 . A l g o r i t h m d e s i g n f o r t h e v i r t u a l s y s t e m . . . 4 2 2 . 7 . O v e r a l l s o f t w a r e a r c h i t e c t u r e . . . 4 6
v
2.8. GUI composition...50
2.8.1. Chart Area...50
2.8.2. Indicators Area...50
2.8.3. Communication and Data Storage Settings Area...51
2.8.4. Virtual Environment Settings area and The Food Area...51
2.9. Program flow to emulate the freezer controller (or PLC)...53
2.10. Program flow to simulate the virtual environment...65
2.11. How to exchange the data of emulator and simulator ...66
III. Results a nd Discussion...69
3.1. The simulated experiment system...69
3.2. The developed virtual system program...74
3.3 . Co mp l e te d mo de l F unc t i o ns. ... ... .. ... ... ... ... ... .. ... ... .. ... ... .. ... ... .. ... ...7 8 3.4. Node No.1 Calculation Function...79
3.5. Node fro m No.2 to No.(n-2) Calc ulat ion Functio n...80
3 . 6 . N o d e N o .( n-1 ) C a l c ul a t i o n F unc t i o n. . . .. . . .. . . .. . . .. .8 1 3.7. Node No.n Calculation Function...82
3.8. T he numerical data vs. the actual data...83
I V. C o n c l u s i o n . . . 8 7 V. N o m e n c l a t u r e . . . 8 8 V I . R e f e r e n c e s . . . 8 9
vi
CHAPTER 2
Novel Method to Optimize the Energy Efficiency of Freezer using Automatic
Test Software
A b s t r a c t . . . 9 5 I . I n t r o d u c t i o n . . . 9 7
1.1. Review...97
1.2. History of refrigeration system...101
1.3. History of domestic freezer and refrigerator...104
1.4. History of optimum designs...110
I I . M a t e r i a l s a n d M e t h o d s . . . 1 1 3 2.1. Experimental system’s control...113
2.2. Choice of methods and factors...115
2.3. In-depth test algorithm flow...121
2.4. GUI of the automatic experiment program...123
2.5. Test optimization method...125
2.6. Annual electric power consumption calculation method...133
I I I . R e s u l t s a n d D i s c u s s i o n . . . 1 3 5 3 . 1 . C o m p l e t e d p r o g r a m . . . 1 3 5 3 . 2 . E x p e r i m e n t a l a n a l y s i s . . . 1 3 7 3.2.1. P artial Lea st Squares...13 7 3 .2 .2 . M ul t i p l e R e gr e s s i o n Ana l ys i s . . . .. .. . .. . .. . .. . .. .. . .. .. . .. . .. .. . .. .. . .. 1 50 3.2.3. Two-level Full Factorial Designs...157
vii
I V. C o n c l u s i o n . . . 1 7 7 V. R e f e r e n c e s . . . 1 7 9
viii
CHAPTER 3
The Remote Monitoring System Construction in Order to Verify the Field
Test of the Developed Refrigerator and Acquire the Big Data Used for the
Improvement of User Experience (UX)
A b s t r a c t . . . 1 8 8
I. Introduction...189
1.1. Review...189
I I . M a t er i a l s a n d M eth o d s . .. . .. .. .. . .. .. .. .. . .. .. .. . .. . .. .. . .. .. .. .. . .. .. .. . .. .. .. . .. .. 1 9 2 2.1. Hardware design...192
2.2. Server, clients and networks...197
2.3. Software development...200
2.3.1. The software for operating the FSF...200
2.3.2. Client data acquisition software...202
2 . 3 . 3 . We b S e r v i c e . . . 2 0 5 I I I . R e s u l t s a n d d i s c u s s i o n . . . 2 0 7 3.1. Operation condition...207
3.2. The use pattern analysis...209
I V. C o n c l u s i o n . . . 2 1 6 V. R e f e r e n c e s . . . 2 1 8
ix Appendices A p p e n d i x A . S i m u l a t i o n s o u r c e w i t h V i s u a l C + + . . . 2 2 1 [ V i r t u a l F r e e z e r D l g . h ] . . . 2 2 1 [ V i r t u a l F r e e z e r D l g . c p p ] . . . 2 2 6 A p p e n d i x B . E m u l a t i o n s o u r c e w i t h C + + . . . 2 5 6 [ m o a c o n . c p p ( w i t h s i m u l a t o r ) ] . . . 2 5 8 [ E m u l a t o r . c p p ] . . . 2 6 4 Korean Abstract 초 록 . . . .. . . . .. . . .. . . . ... . . .. . . . .. . . . .. . . .. . . . .. . . . .. . . .. . . . .. . . . .. . . . .. . . .. . 28 2
x
LIST OF TABLES
Table 1-1. Common properties of air at atmospheric pressure ...28
Table 1-2. The converted PLC functions to be used in Visual C++...54
Table 1-3. The experiment result of actual and virtual temperature...54
Table 3-1. The data flow table of the developed overall system ...199
Table 3-2. The defined communication protocol between the remote FSF server and the client ...201
Table 3-3. The comparison of the use time between a refrigerator and a freezer compartment...213
xi
LIST OF FIGURES
Figure 1-1. Ideal embedded system development process...13
Figure 1-2. The comparison chart of the development process between the traditional method (a; left) and the new VPSDP method (b; right)...17
Figure 1-3. The difference of between the planned development process and the actual d e ve l o p me nt p r o c e s s . . . 1 9 Figure 1-4. The various energy flows inside the freezer...22
Figure 1-5. The specific heat capacity curve of the air in relation to the temperature...29
Figure 1-5. The actuators installed on the experimental freezer system...33
Figure 1-6. The sensors installed on the experimental freezer system ...35
Figure 1-7. The measuring instruments connected with the experimental freezer system to acquire data...37
Figure 1-8. Overall experimental freezer system...39
Figure 1-9. The concept diagram of the VPSDP (Virtual Product Software Development Process)...41
Figure 1-10. The feedback relation between the environment simulator and the freezer emulator... 44
Figure 1-11. The basic algorithm flow chart of the freezer program ... 45
Figure 1-12. The architectural view of the simulator system and the emulator system ... 47
Figure 1-13. The modified functions provided by the manufacturer to operate in MFC...49
Figure 1-14. The simulator program GUI...52
Figure 1-15. The virtual socket concept for communication between the simulator system and the emulator system; the detail drawings in the perspective of the emulator...64
xii
Figure 1-16. The virtual socket concept for communication between the simulator system and the emulator system; the detail drawings in the perspective of the
simulator ...66
Figure 1-17. The sent and received protocol format of the virtual communication ...68
Figure 1-18. The dimensions of the actual freezer system...70
Figure 1-19. The picture of the completed experimental freezer system...73
Figure 1-20. The completed simulation program and the operational state ...75
Figure 1-21. The numerical analysis results shown in the console display...76
Figure 1-22. The freezer temperature chart measured by the numerical analysis and the real temperature...84
Figure 1-23. The experiment result analysis of actual and virtual temperature...86
Figure 2-1. Experiment system block diagram detailed in the target Programmable Logic Controller...114
Figure 2-2. The complete refrigeration cycle with the four basic components: compressor, condenser, evaporator, and expansion device. And the temperature control chart...117
Figure 2-3. Experiment system block diagram detailed in the intelligent and automatic experiment proceeding software ...119
Figure 2-4. The detailed program algorithm flowchart in the intelligent and automatic experiment proceeding software ...122
Figure 2-5. The initial GUI design of the intelligent and automatic experiment program ...124
Fi gur e 2-6. T he grap hi c al tes t res ul ts o f t he i nitial proposed e xperi me nt algorithm ...127 Figure 2-7. The test progression using the initial proposed experiment algorithm in relation
xiii
to time ...128
Figure 2-8. The modified advanced stabilization method to reduce the stabilization time in the experiment algorithm ...129
Figure 2-9. The advanced measurement method to reduce the measurement time in the experiment algorithm ...131
Figure 2-10. The graphical result of the final automatic and intelligent experiment proceeding software algorithm ...132
Figure 2-11. The automatic and intelligent experiment proceeding software developed using LabVIEW ...136
Figure 2-12. Partial Least Squares standard coefficient plot...140
Figure 2-13. Partial Least Squares distance plot...142
Figure 2-14. Partial Least Squares residual versus leverage...143
Figure 2-15. Partial Least Squares loading plot...145
Figure 2-16. Partial Least Squares model selection plot...147
Figure 2-17. Partial Least Squares response plot...149
Figure 2-18. Residual plots for the electric power consumption calculated with all factors...153
Figure 2-19. Residual plots for the electric power consumption calculated with selected factors ...156
Figure 2-20. Normal plot of the standardized effects...161
Figure 2-21. Pareto chart of the standardized effects...163
Figure 2-22. Residual plots for the electric power consumption ...165
Figure 2-23. Main effects plot for the electric power consumption ...167
Figure 2-24. Interaction plot for the electric power consumption ...169
xiv
Figure 2-26. Response Optimization Result #1; Notch: -23.6364, Differential: 1.0, Compressor_Delay: 423.0303, Fan_Speed: 3000.0, Fan_Delay: 1.2121 (when the target of the electric power consumption is 1,000,000 Whr) ...174 Figure 2-27. Response Optimization Result #2; Notch: -28.1336, Differential: 1.0, Compressor_Delay: 420.0, Fan_Speed: 22128.0257, Fan_Delay: 0.0 (when the target of electric power consumption is 1,000,000 Whr) ...175 Figure 2-28. Response Optimization Result #3; Notch: -27.6340, Differential: 3.7607, Compressor_Delay: 720.0, Fan_Speed: 23000.0, Fan_Delay: 120.0 (when the target of electric power consumption is 1,000,000Whr) ...176 Figure 3-1. The hardware structure and the input-output port of the FSF system ...193 Figure 3-2. The overall connectivity of the experiment network system ...196 Figure 3-3. The flow chart of the data exchange between the FSF and the client software ...204 Figure 3-4. The web service is supported...206 Figure 3-5. The client software gathers the remote condition data and the image data ...208 Figure 3-6. The chart drawn by the received data and the use pattern between (a) and (b). ...210 Figure 3-7. The diverse analysis charts about the use time ...212
1
Chapter 1
The Freezer Program Emulation Method in the
Virtual Simulation Environment Using the
Virtual Product Software Development Process
2
Abstract
The freezer is essential for freezing and preserving food for a long period
of time and maintaining the quality of the raw food to the maximum level at
room temperature. The general process to develop a freezer and other home
appliances with software was to develop hardware first and then develop
software for hardware. However, this was accompanied with a problem that
enough time was not given to test the software quality in case the hardware
development was delayed.
Hence, the virtual external environment will be constructed, and the effect
same as developing the software on the actual hardware will be realized
through both of the emulated freezer system and the simulated external
environment. In order to simulate the heat transfer of the virtual environment,
the freezer will be calculated through the numerical analysis, and the
temperature change of this virtual environment will be controlled by the
output state of the emulated freezer software.
The software developed in this way was ported into a freezer which was
actually developed and was controlled equally with the result from operating
the virtual machine.
3 Virtual Machine, Virtualization, Porting.
4
I. Introduction
1.1. Review
The previous definition of a Virtual Machine could be described as a
'Completely isolated guest operating system installation within a normal host
operating system" [1]. However, current definition of a virtual machine
includes both the software emulation and the hardware virtualization.
Popek and Goldberg defined the basis of the virtual machine as "an
efficient, isolated duplicate of a real machine". Today, it includes virtual
machines taking no direct correspondence to any real hardware [2, 3].
Virtual machine is divided into system virtual machine based on system
and processor virtual machine based on processor [4]. The system virtual
machine has the concept of installing the virtual machine software on the
main Operating System (OS) and then installing other OS in the top of the
installed virtual machine. VirtualBox (Oracle, CA, USA), VMware (VMware,
CA, USA) and Parallels (Parallels, WA, USA) are considered as typical
system virtual machine products. Using system virtual machines, several
types of OS can be operated at the same time and variety of software
development platforms can be supported. However, system virtual machines
induce processing speed degradation, because hardware resources can be not
5 machine software.
The process virtual machine is also called application virtual machine
because of the concept of operating only the application area in a software
structure [5]. Typical process virtual machines are platform independent
languages such as Java (Oracle, CA, USA), C# language (Microsoft, WA,
USA) and etc. When source code is compiled, an intermediate binary code
instead of an execution binary code is generated, and the run-time machine
executes the program with real-time interpretation. This virtual machine can
be driven without source code changes on any operating system that supports
run time machine. An intermediate binary code has also the shortcomings
that it is slower compared to an executable-compiled file operated on a
specific OS, but such virtual machines are widely adopted because of the
greatest advantage of them being platform independent.
In all kinds of virtual machines, the word 'emulation' is frequently used.
Emulation supports a real environment of any actual system through
virtualization. An emulator is an imitation of the behavior of a computer or
other electronic systems through the help of another computer or a system [6,
7].
Even if an executable file is not in the actual hardware, an emulator in the
virtual hardware system can provide the same action as the actual
6
developing smartphone applications, emulation is a commonly used
technique in platforms such as Android, iOS and Windows Mobile, and
called the software Development Kit (SDK) s.
The virtual development follows the usual procedure in which a program
is firstly developed in the virtual hardware environment and then is operated
and debugged in the actual hardware environment. Initially, the developed
software in the virtual hardware environment can be tested without the actual
hardware, and then the tested software is debugged when the completed
actual hardware is produced. Both the virtual development environment and
the cross-compiling technique which enables the program to operate on other
OS applications are applied among various devices.
Simulator is a machine that conducts simulation in a virtual environment.
Simulation can be defined as a process or behavior which imitates an actual
machine [9, 10]. To conduct simulation, a behavior model imitating the
actual system must be developed. The model represents both major
characteristics and the behaviors of the physical and abstract system. In this
study, the temperature changes of the freezer according to the difference in
the volume and the physical properties of the surrounding environments are
represented through numerical analysis.
Historically, the conduct of simulation has been developed independently
7
the cybernetics research using simulation have become more systematic
through the growth of computer industries and improvement of program
techniques.
Physical simulation means that real objects are transferred to physical
objects. The physical objects are often selected because it is smaller and
cheaper than real objects. The interactive simulation is a special kind of
physical simulation. Instead, a person must be used as an operator to do the
simulation. Simulators such as flight simulators or driving simulators mainly
belong to physical simulation. Through physical simulation, a human is
trained in the virtual environment that simulates actual environment, and
when he is sent in the actual environment, he will be able to adapt to the
8
1.2. Environmental virtualization
A numerical analysis study of the heat transfer is also necessary to
virtualize the external environment of the freezer. These tasks are managed
using a computer called the Computational Fluid Dynamics (CFD) [11, 12].
Technicians such as Leonardo da Vinci who is known as a great artist made
the initial attempts on testing fluid dynamics and the flow of the natural
world in detail. He recognized the shape and structure of the fluid, and
precisely represented it with accurate diagrams, and has observed natural
phenomena in the world of substances. He contributed in the fluid dynamics
such as the surface of the water, the movement of water, waves, swirl, ebb,
free jet, the interference of the waves, and also has dealt with many other
phenomenons observed in the recent world. His related works are expressed
in part of nine different publications [13].
These achievements by Da Vinci are inherited by Sir Isaac Newton in the
second half of the 17th century. Through his basic Newtonian theories,
Newton tried to predict and measure the fluid flow phenomena.
In 18th and 19th centuries, researchers have attempted to mathematically
describe the movement of the fluid. By Daniel Bernoulli (1700-1782), a
famous Bernoulli equation was introduced. Leonhard Euler (1707-1783)
introduced the Euler equations describing the law of conservation of mass
9 also proposed the velocity potential theory.
French researcher Claude Louis Marie Henry Navier (1785-1836) and
Irishman George Gabriel Stokes (1819-1903) introduced the movement of
viscous with Euler equations, which is established as the Navier-Stokes
equations. This theory established almost 200 years ago now forms the
foundation of the modern CFD industry [15]. It includes the expression of
the preservation of mass, momentum, pressure, and the turbulent surface.
This equation is difficult to find answers to, but after digital computers were
introduced in the 1970, the problem of the actual fluid was able to be solved
by them.
In the 19th century, researchers such as Jean Le Rond d'Alemert,
Simeon-Denis Poisson, Joseph Louis Lagrange, Jean Louis Marie Poiseuille, John
William Rayleigh, M. Maurice Couette, Osborne Reynolds, and Pierre
Simon de Laplace have all made contributions in expressing the fluid
dynamics.
In the early 20th century, Fluid flow has been performed to establish the
theory of the boundary layer and the turbulent layer. Ludwig Prandtl
(1875-1953) have proposed the boundary layer theory, which establishes the
concept of mixing length, compression flow, Prandtl number, and many more
things which we take for granted today. Theodore von Karman (1881-1963)
10
Geoffrey Ingram Taylor (1886-1975) proposed the statistical theory of
turbulence and the Taylor micro-scale. Andrey Nikolaevich Kolmogorov
(1903-1987) introduced the concept of the universal energy spectrum and the
Kolmogorov scale of turbulence. George Keith Batchelor (1920-2000)
contributed to the theory of homogeneous turbulence.
The beginning of CFD was initiated by Britain's Lewis Fry Richardson
(1881-1953), who developed the first numerical weather prediction system.
Calculating the fastest numerical solution to the flow passing of a cylinder
was performed by Thom has in the UK, 1933.
In 1953, Kawaguti of Japan calculated the cylindrical fluid flow by using
mechanical desk calculator, working 20 hours per week for 18 months.
In 1960, many numerical calculations such as Particle-In-Cell (PIC),
Marker-and-Cell (MAC), Vorticity-Stream function methods, Arbitrary
Lagrangian-Eulerian (ALE) methods and the ubiquitous k-e turbulence
model that are still being used in the CFD in NASA's theory division located
in Los Alamos in the United States have been established.
In 1970, At Imperial College London, k-equations’ SIMPLE algorithm and
TEACH code were developed by researchers lead by D. Brian Spalding
(Spalding & Launder, 1972). They continued to develop the updraft, and
combustion models such as 'Eddy breakup' and 'presumed PDF' were
11
In 1980, ‘Numerical Heat Transfer and Fluid Flow’ written by professor
Suhas V. Patankar was published. This book is the most influential book in
the CFD, and has created thousands of CFD codes. In the early 1980s,
commercial CFD codes were introduced into the open market by Patankar’s
12
1.3. The objective of this study
Designing a firmware system includes both hardware and software design.
Often also mechanics design is needed. The diagram shown in Figure 1-1 is
the best ideal firmware development model [16]. In many cases the final
hardware cannot be defined until very late in a project. This means that most
of the time the software development is done on different hardware than the
13 Figure 1-1. Ideal embedded system development process.
14
In the field of home appliances using MICOM installed with the firmware
software, there has been much progress on utilizing simulation and
simulators. However, in the current situation, the emulator device for
developing the software of the microcomputer mounted in home appliances
are configured separately from surrounding environment. This study will
develop both the simulated system of external environment and the emulated
freezer control software, and their data are synchronized with each other and
through this research, more advanced research paradigms will be created.
Among software developers of home appliances, the main issue is always
related to the need for researching the parallel development process shown in
Figure 1-x. In the development process, the last schedule is assigned to the
software developer, and by many software errors and software problem,
much delay is induced due to lack of the software test time. However, the
proceeding process of the hardware developers is the bigger issue rather than
the willingness of the software developers. Software is difficult to develop
without the hardware, and if hardware eventually is provided without enough
time, the software verification tasks cannot be satisfied, which will cause the
porting to eventually contain errors.
If the ideal development process is applied, the developed software can be
verified, debugged and completed at the hardware completion time because
15
Therefore, this helps in shortening the mass production considerably.
The objective of this research is to develop the system program in the
virtual environment to simulate a real-world environment that reflects the
flow of these technologies. A virtual environment reflecting the actual
surroundings is built for the sake of this study, and there is a need to emulate
the virtual freezer system. The former virtual environment is called a
simulator, and the latter virtual freezer system is called emulator. Such a
development process is named as Virtual Product Software Development
Process (VPSDP).
If more systematic approaches of VPSDP methodology are possible, the
property of the common resemblance is founded, and the software function
library can be made, and it will have a positive value to the entire software
development system.
Actually, the development process in the electronic business is shown in
Figure 1-2 (a). However, if the embodied VPSDP techniques through this
study are used, a lot of time can be saved as shown in Figure 1-2 (b). This
development environment is used by implementing the most advanced
mobile development environment.
However, generally the equipment used in the food industry such as
refrigerators and freezers must follow the (a) process of the development.
16
means that until the final hardware development is completed, the software
17
(a) Common Method (b) VPSDP
Figure 1-2. The comparison chart of the development process between
18
As shown in the Figure 1-3, the actual schedule compared to the initial
plan is always delayed from a few months to a few years. The schedule delay
that accounts for the biggest portion of delay is software error. Even if the
freezer system has 100% integrity, the integrity can also become 0% because
of one error in the operation of the software loaded in the system.
Therefore, the importance of the software in the system is heavily
emphasized, but the time to test the software on the hardware is not given in
the development locus.
When pre-production is finished, hardware system is revealed, and
software test is enabled. The responsibility of the delayed schedule of this
problem is given to the software developer, which implies much stress on
them. To solve these problems, this research resolves the production
schedule delays and improves software quality.
Through Chapter 1 of this study, and after building a virtual environment
without hardware, the possibility and feasibility of the software development
19
Figure 1-3. The difference of between the planned development process
20
II. Materials and Methods
2.1. Model system and equations
The freezer is simulated through the implemented model system. The
thermal conductivity (k) of the freezer heat insulation material, the heat
transfer area, the speed of the fan, the volume, and the convective heat
transfer coefficient (hin, hout) can be changed through the GUI of the
developed simulator program. Whether the virtualization will be successful
of not will be known through being compared with a modified actual system,
FD-170-SF freezer (Unique Daesung Co., Ltd, Gyunggi, South Korea) [18].
The flow of energy from the freezer is designed as shown in the Figure 1-4
From the energy balance, we can calculate the energy of air (Qair) and food
(Qfood) in the freezer by the value of eliminated energy from the evaporator
(Wevaporator) minus the sum of the incoming heat through the insulation
material (Qinsulation) and the food respiration heat (Qrespiration) [19-25].
To solve this problem, the following assumptions are given. Heat transfer
is composed as one-dimensional because of the wall thickness of the freezer
is significantly related. Thermal properties, heat transfer coefficients, and
outdoor temperature are constant. Radiant heat is ignored. During this period,
21
barometric pressure is 1 atm. The food and corner space is ignored. Incoming
22
α: diffusivity Tn : nodal temperature Δx : nodal space
23
Various properties that are used for calculation is obtained by user-defined
manner through the GUI of the program. The incoming flow of heat through
the heat insulation will be solved through explicit finite element method [27].
(1-1)
The number of nodes, M, is determined by the insulation thickness from
the program given by the Equation 1-1, M = L / Δx +1.
In this analysis, because the unknown n-1 nodal temperature will be given,
four formulas are generated. The range of the interior node is from 2 to n-1.
To solve them, the general explicit finite difference relation uses the
following Equation 1-2.
(1-2)
Nodes from 1 to n-1 related to the convection and radiation can be defined
24
As the heat transfer is made through convection, an expression derived
through the following Equation 1-3, 1-4 can be created about Node1.
(1-3)
(1-4)
Node 2 to Node n-2are calculated by using the following Equation 1-5,
because the thermal conductivity is made through the interior properties.
(1-5)
Node n-1 is achieved through the process of convection heat transfer to the
final inside wall. Therefore, the final expression can be derived through the
25
(1-6)
(1-7)
The mesh Fourier number is obtained through the following Equation 1-8:
(1-8)
The weight of the air can be obtained through the following equation 1-9:
26
The final equation in the energy balance Node n section about the air
space of the freezer can be derived through the following Equation 10,
1-11.
(1-10)
27
2.2. The characteristics of the air and equations
The following Table 1-1 and Equations 1-12~1-16 are re-made by being
based on all existing references for simulation with computer [27].
Specific heat capacity:
(1-12) Thermal conductivity: (1-13) Density: (1-14) Kinematic viscosity: (1-15) Prantl’s number (1-16)
28
29 2.3. Designable food and equations
The model food is generally assumed to be a rectangular parallelepiped
figure. The properties such as width, height, length, protein, fat, carbohydrate,
water, ash, respiration heat, etc., are freely changed by the developed
program through GUI. Through this many different varieties of food can be
simulated. Whether a model food is success or not will be evaluated by the
test package used commonly as refrigeration load tester.
In order to reflect the freezing characteristics of food, the heat transfer
algorithm of food is designed. Governing equation follows the steady-state
heat conduction equation, and it reflects considering surrounding
temperature and the heat exchange rate. Because food has the various
complex physical properties and special characters, the numerical analysis
equation using the test package which simulates food is calculated.
Numerical analysis result is compared with the actual load result using the
test package(TYPE 1250”, -1℃; MADI, ITALY).
The refrigeration load represents the total calories that need to be removed
from the object of any kind until it reaches the desired temperature. In order
to effectively freeze the object, the used freezer must have enough ability to
remove the calories of the refrigeration load.
Refrigeration load can be divided into two groups, refrigeration load of
30
calories that need to be removed in order to maintain a constant temperature
storeroom. On the other hand, unsteady state refrigeration load is the
removal rate of the calories to freeze an object stored in a freezer for a
limited time until the desired temperature [12, 28-33].
Calories in food requirements can be obtained through the following
Equation 1-17.
(1-17)
Because food material can be set freely through the program, an
expression can predict the specific heat required. This is predicted through
the following Equation 1-18 [34, 35].
(1-18)
In addition, the ratio of the material must always satisfy 1, as shown in the
31
(1-19)
Because fruits and vegetables breathe, the respiration heat must be
included in the refrigeration load. As respiration heat is a function of
temperature, it can be expressed as shown in the following Equation 1-20. If
weight is multiplied with the equation, the respiration calories can be
calculated.
32 2.4. Experimental system configuration
The experimental verification is progressed through the system shown in
the Figure 1-5. Of the existing product under sale, only the outer part and the
cycle are used, while the control part is separately made and used [36].
A fan to simulate both the direct and indirect cooling freezer by
controlling the mass flow rate is installed in the freezer of the direct cooling
method. The evaporator to exchange heat is installed on all four sides, and
the discharge temperature of the capillary tube can be as low as -50℃.
A FD-170-SF deep-freezer will be used as the target freezer. A small
cabinet for freezing the food is installed to monitor the food temperature
change associated with the freezer temperature change. Also, Programmable
Logic Controller (PLC) is installed to replace the existing control unit.
The compressor, the AC fan of the machine room, and the freezer DC fan
shown in Figure 1-8 are controlled by the newly designed controller using
PLC. The compressor and the machine room fan are driven with the on/off
operation through relays. The DC fan is controlled by the variable through
33
34
The room temperature and the freezer temperature are measured with the
thermoresistor (PT100Ω) sensor shown in Figure 1-6, while the room
humidity and the freezer humidity is measured with the humidity sensor
35
36
A WT120 (Yokogawa, Japan) power meter shown in Figure 1-7 is used to
measure the electric power consumption. In order to acquire operation state
data, a general personal computer is used to connect with controllers and
measurement devices [38].
For communication shown in Figure 1-7, RS-232C serial communication
is used [39]. In order to allow remote measurement, wired signal is
37
Figure 1-7. The measuring instruments connected with the experimental
38
As shown in the Figure 1-8, actuators, sensors, instrumentation, and
39
40 2.5. Virtualization concept
The virtual system for emulating the freezer as shown in Figure 1-9 is
made using the Microsoft Windows environment. The freezer program is
developed and executed directly in the virtual environment, while the
freezing time is predicted using the influence of the virtual food. After
completion of the development process, it will be ported in the actual freezer
system and compared to evaluate how well it is suited to the system.
The simulator program is made by using the model equation. The virtual
temperature of the simulator is quantified in conjunction with the compressor
of the emulator and the fan output. This will in turn be reflected in the
temperature of the emulator.
The emulation program is virtualized in the simulator to logically
controlled using the provided temperature value. Since this emulator is the
virtual program that represents the actual control machine, it must be
programmed using the grammar of the control program. Therefore, the
control program must be written in C language, and the library must also be
virtualized because only the libraries provided by the manufacturer can be
used. The manufacturer's library used in this program is changed by using
the virtualization program rule. The list and description of the converted
41
42
2.6. Algorithm design for the virtual system
Machine like freezers generally use the feedback control method which
controls the output through the input value. This can be classified according
to the control type such as simple on/off control, proportional control, PI
control, PID control, and etc. In our model, the simple on/off control and
PID control are used in conjunction because the composed actuators of the
freezer are a recipro-type compressor and a variable DC-type fan.
Parameters used for configuring a freezer are divided into two types, the
input type and the output type shown in Figure 1-10. Input types are
temperature and humidity, while output types are fan and compressor.
Predicting the temperature change between two types is composed as the
simplified frozen load change algorithm.
All input and output ports are virtualized, and all freezer processor
programs are input/output through the virtualized ports. The basic algorithm
of the freezer firmware program is constituted as follows and Figure 1-11 is
the program flow chart.
[Basic Algorithm] If current sensor temperature is greater than
<setting temperature + differential>, fans and the compressor become ON. If current sensor temperature is less than <setting temperature + differential>, fans and the compressor become OFF
43
The virtualization environment software and the freezer processor
software are programmed by using Visual C++ (Microsoft, USA). The
freezer processor software is implemented through redesigning and porting a
c-based manufacturer providing functions used in MOACON PLC (Comfile
44
Figure 1-10. The feedback relation between the environment simulator
and the freezer emulator.
45
46
2.7. Overall software architecture
The virtual system shown in Figure 1-12 is divided with the system
emulator part and the freezer program part. When the freezer program is
executed, the system emulator part calculates the effects of freezer outputs
on the system. Using these output influences, the system input values are
changed. To express these area values in detail, it is continuously calculated
using the heat transfer equation presented earlier. Also, the heat transfer
algorithm of the virtual food is included for calculating the temporal frozen
47
48
This virtualization program is designed on the MFC library based on
Windows OS. To constitute the Windows program based on GUI, the
program is produced using Microsoft Visual C++ [43]. The freezer program
area is constituted by C language as the program area operated with PLC,
and this program is operated in the virtual system like as the actual system.
After the development is completed, it is programmed with library supported
in PLC because it must later be ported in the actual freezer system. The
standard functions in MFC and C does not maintain specific functions for
PLC management. To embody the special PLC function in the virtual system,
the PLC library function for the virtual system like as Figure 1-13 will be
49
Figure 1-13. The modified functions provided by the manufacturer to
50 2.8. GUI composition
The GUI interface will be constituted like shown in Figure 1-148, and the
program linked with the PLC program will monitor the operation state of the
virtual system. Interfaces are composed with the area of Chart, Indicators,
Communication and Data Storage Settings, and Virtual Environment Settings.
This program can also be used for communication with the actual system.
2.8.1 Chart Area
Chart area draws a graphical representation of the state of load and
temperature over time. These values may be expressed from the result of the
simulation or the actual system. This depends on whether 'Virtual System
Usage' item is checked in the area of 'Communication and Data Storage
Settings'.
Through this area, the cumulative series changes of the system are
understood visually.
2.8.2. Indicators Area
Through the indicators area, status of the current points such as
51
2.8.3. Communication and Data Storage Settings Area
If ‘Use Virtual System’ is checked, the freezer program based on the
virtual freezer system and the system simulator is operated. Otherwise, it will
communicate with the actual developed freezer.
2.8.4. Virtual Environment Settings area and The Food Area
This area is the configuration part of the virtual freezer system. By setting
various parameters, the freezer is simulated. The already determined virtual
foods are simulated depending on its size. If the food model is not
determined, it provides a pop-up window so that a user-defined food can be
52
(a) Main Program GUI
(b)Model Food Maker Program GUI
53
2.9. Program flow to emulate the freezer controller (or PLC)
The following Table 1-2 is the list of new library functions for
cross-compiling between different systems. If this function file does not exist,
compilation in Visual C++ environment cannot be executed properly
cross-compilation cannot be done on C or C++ of other OS.
The freezer program shown in Figure 1-15 is composed of the basic
algorithm described previously. In this section, the program is analyzed in
the logic associated with PLC emulator in more detail. Basically, variables
are initialized and the watchdog is set in the program start point. The
program is looped infinitely by a ‘while(1)’ instruction and whenever the
program reaches the initiation point, the program announces the watchdog
reset to the emulator to notify that the program is operating without problems.
Through the use of virtual communication with the virtual simulation
environment, the freezer algorithm is performed to control the values of the
environment, and the final load state is also decided. The load output values
and other reset variables value are processed and fed back to the virtual
54
Table 1-2. The converted PLC functions to be used in Visual C++.
(a) System Emulation Functions
void delay(u32 interval)
Parameters
interval: Number of milliseconds to pause Pauses execution for interval milliseconds. void statusLED(u8 onoff)
Parameters
onoff: 0=Off, 1=ON
Turns the status LED on the CPU Module on or off. void wdtOn(u8 timeout)
Parameters
timeout: A number corresponding to a specified timeout (0 ~ 6) Enables the watchdog timer with a specified timeout, timeout. void wdtClear (void)
55
(b) Event Emulation Functions
void startTimerEvent (u16 interval)
Parameters
interval: The amount of time between each event in milliseconds (1 ~ 65,535)
Starts a timer that triggers events every interval milliseconds. void timerEvent (void)
This is the function that is called when a timer's event fires. void stopTimerEvent (void)
56
(c) MCU Digital Output Emulation Functions
void portInit(u8 portBlockNumber, u8 mode)
Parameters
portBlockNumber: Port Block Number (e.g. 0 for ports 0~7, 1 for ports 10~17, etc...)
mode: 0 or 1 (0=Output, 1=Input)
Initializes a port block's I/O mode as either Input or Output. void portOff (u16 portNumber)
Parameters
portNumber: The port number to turn off
Sets the output state of the given port, portNumber, to off. void portOn (u16 portNumber)
Parameters
portNumber: The port number to turn on
Sets the output state of the given port, portNumber, to on. void portReverse (u16 portNumber)
Parameters
portNumber: The port number to toggle
Toggles the output state of the given port, portNumber. u8 portOutStat (u16 portNumber)
Parameters
portNumber: The port number to read current state.
Returns
57
Read the output state of the given port, portNumber. void portOut (u16 portNumber, u8 value)
Parameters
portNumber: Port Number of an individual port (not a port block)
value: 0 or 1 (0=Off, 1=On)
58
(d) Temperature Input Module Emulation Functions
int getTemp (u8 tempId, u8 tempCh)
Parameters
tempId: The ID of the Temperature Input Module (0 ~ 9) tempCh: The channel on the Temperature Input Module (1 ~ 2)
Returns
the temperature in °C multiplied by 10. (-1000 ~ 5000)
Gets the temperature read from a PT100 sensor connected to Temperature Input Module tempId on channel tempCh.
59
(e) Communication Emulation Functions
void openCom (u8 comCh, u32 comBaud, u8 comMode)
Parameters
comCh: Channel number comBaud: Baud rate
comMode: Communication mode (data bits, parity, and stop bits) Opens the port on channel comCh with the given baud rate, comBaud, and the communication mode, comMode.
short comGets(u8 comch, u8 * dest, u16 length)
Parameters
comCh: Channel number
dest: Pointer to where data that is read should be stored length: The amount of data (in bytes) to read.
Returns
–1 if data is read; 0 if data is not read.
Reads length bytes from the receive buffer on channel comCh, and stores the data in memory at address dest.
void comPuts(u8 comch, u8 * src, u16 length)
Parameters
comCh: Channel number
src: Pointer to data that should be sent
length: The amount of data (in bytes) to send.
Transmits length bytes of data from memory address src out channel comCh.
60
u16 comLen (u8 comCh)
Parameters
comCh: Channel number
61
(f) LCD Emulation Functions
void clcdI2cInit(u8 clcdAdr)
Parameters
clcdAdr: The I2C slave address of the CLCD module
Initializes the CLCD library to use slave address clcdAdr for all function calls.
void clcdPower(u8 onOff)
Parameters
onOff: 0=Off, 1=On
A 5V power source is supplied by the MOACON to the CLCD display
module.
void clcdCsr(u8 onOff)
Parameters
onOff: 0=Off, 1=On
Shows or hides the cursor on the CLCD module.
void clcdPrint(u8 cx, u8 cy, char *formatString[, arg0, ..., argn])
Parameters
cx: x-position (column) of first character to be printed cy: y-position (row) of first character to be printed
formatString: A character string to be printed that can optionally contain format
specifiers
arg0,...,argn: An optional set of arguments to be used by format specifiers.
62
Prints a character string, formatStrng, on the CLCD device at location cx, cy. F
void clcdCls()
63
(g) PWM Emulation Functions
void pwm(u8 pwmChannel, u16 pwmDuty, u16 pwmWidth)
Parameters
pwmChannel: PWM channel
pwmDuty: Duration for which the pulse is ON pwmWidth: Pulse period
Sets the duty cycle and period of the pulse width modulator (PWM) on channel pwmChannel.
void pwmOff(u8 pwmChannel)
Parameters
pwmChannel: PWM channel
64
Figure 1-15. The virtual socket concept for communication between the
simulator system and the emulator system; the detail drawings in the
65
2.10. Program flow to simulate the virtual environment
The virtual environment simulator program calculates the heat transfer
value using the load output value and previous state environment values that
are given by the logic program of emulator like as Figure 1-16. The
numerical analysis results are automatically databased and transferred to the
emulator logic through virtual communication socket. The numerical
analysis at this point relates not only to compartment temperature of the
66
Figure 1-16. The virtual socket concept for communication between the
simulator system and the emulator system; the detail drawings in the
67
2.11. How to exchange the data of emulator and simulator
In order to hold the state data and the environment data in common
between the emulator program and simulator program, a 50 bytes array data
is configured by assigning each of the variables like as Figure 1-21. The real
freezer actually initiates communication. Therefore it is programmed using
the communication functions and defined as the virtual socket. In order to
make it look like being communicated, they are connected with each other
using virtual communication socket, and data are read and written within in
68
Figure 1-17. The sent and received protocol format of the virtual
69
III. Results and Discussion
3.1. The simulated experiment system
The numerical values shown in the Figure 1-18 is that of the simulated
freezer. The upper part of the Figure 1-18 is the measured values of the inner
space of the freezer, and lower is the measured values of the evaporator area.
An experiment system shown in the Figure 1-19 is a completed form that
consists of freezer, control system, and measurement system. In the freezer, a
fan and a load simulating a food model is installed. This actual freezer
controller is successfully operated by the previous developed freezer
program in the simulation environment program.
At regular time intervals, the data of the freezer system is gathered by the
measurement system after starting operation. The data collected from the
actual hardware was compared and analyzed with the virtual environment
70
71
(a)The modified freezer circuitry
72
(c) The completed PLC controller (Up)
73
(e) The completed PLC controller (Right)
(f)An installed fan and model food in the freezer.
74
3.2. The developed virtual system program
The developed program as shown in Figure 1-20 has different
characteristics compared with the design specification of the previous
designed program shown in Figure 1-14. However, in the overall context, the
program can be seen as the same. The GUI arrangement is improved for ease
of use in the actual experiment.
Using the theoretically presented virtualization methods and the numerical
analysis, the simulation software and the emulation software is made, and the
simulation assigned by the necessary parameters is carried out. This is the
freezer program made by the VPSDP method. Inside this program, the
program that needs to be ported to the actual freezer hardware is included.
The result shown in Figure 1-21 is the arithmetic progression based on the
75
Figure 1-20. The completed simulation program and the operational
76
Figure 1-21. The numerical analysis results shown in the console
77
In the future, more research will be done, as the data calculated with the
numerical analysis cannot accurately reflect the actual environment as 100%.
Processes that acquire experimental data are also required, and we believe
that through trial and error, more results can be acquired.
The completeness of the program will be strengthened by applying various
controllable parameters and equations. Through this, the program will be
78
3.3. Completed model Functions
The equations using the numerical analysis reflected in the program
directly calculates the environment values through the high speed operation
of the computer. Each calculation functions must be written so that it can be
79
3.4. Node No.1 Calculation Function
float CVirtualFreezerDlg::FutureFirstNodeMeshTemperature( float h0, float k, float roC, float outTemp, float selfTemp, float nextTemp, float meshSize, float timeInterval) { float fValue = (h0*(outTemp-selfTemp)+k*(nextTemp -selfTemp)/meshSize)*2*timeInterval/(roC*meshSize) + selfTemp; return fValue; }
80
3.5. Node from No.2 to No.(n-2) Calculation Function
float CVirtualFreezerDlg::FutureMiddleNodeMeshTemperautre( float prevTemp, float selfTemp, float nextTemp, float tau) {
float fValue = tau*(prevTemp+nextTemp)+(1-2*tau)*selfTemp; return fValue;
81
3.6. Node No.(n-1) Calculation Function
float CVirtualFreezerDlg::FutureLastNodeMeshTemperature( float hi, float k, float roC, float prevTemp, float selfTemp, float inTemp, float meshSize, float timeInterval) { float fValue = (hi*(inTemp-selfTemp)+k*(prevTemp- selfTemp)/meshSize)*2*timeInterval/(roC*meshSize) + selfTemp; return fValue; }
82
3.7. Node No.n Calculation Function
float CVirtualFreezerDlg::FutureTargetNodeMeshTemperature( float hi, float Ai, float prevTemp, float selfTemp, float m1, float C1, float m2, float C2, float timeInterval, float watt, float rH) { float newTemp = (hi*Ai*(prevTemp-selfTemp)- -watt/1000+rH/1000)*timeInterval/(m1*C1 + m2*C2) + selfTemp; return newTemp; }
83
3.8. The numerical data vs. the actual data
The configuration values for the simulation environment are that the notch
temperature is -20 ℃ and the differential temperature is ±3℃. This
emulated software is ported to the PLC of the actual freezer, and the result
data of both environments are compared. As shown in the Figure 1-22, the
chart of both temperatures is not accorded to 100%, but in control aspects, it
can be safely assumed that it is controlled properly.
With various case analysis results shown in Table 1-3 and Figure 1-23, in
the -20℃ temperature zone, simulated the average temperature was
controlled within 90% to 92% regardless of the differential temperature like
as the actual average temperature, and in the -30℃ temperature zone, it was
in accord with 96% to 98% level. In the -40℃ temperature zone, it was
controlled in accord with 98% to 101% level as shown in Table 1-3.
The virtual system was operated properly between the -30℃ and the -40℃
temperature zone if it was assumed that confident level is great than 95%. In
the future, ongoing study will be made to the confident level in the -20℃
84
Figure 1-22. The freezer temperature chart measured by the numerical