99b8066f4
김태훈
V0.1.1
|
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
|
currentStep_ = index;
}
int AbstractCook::stepCount()
{
return stepCount_;
}
Cook::Step AbstractCook::step(int index)
{
if (index < stepCount_)
{
Cook::Step s = stepList[index];
for (int idx = 0; idx < 5; idx++)
if (configurations[idx] != NULL)
s = configurations[idx]->configureStep(s);
return s;
}
else
return Cook::Step { Cook::Invalid, Cook::SteamMode, 0, 0 };
}
Cook::StepClass Cook::classify(Cook::StepType type)
{
switch (type)
{
case Preheat:
return PreheatClass;
case PutThermometer:
case Load:
case Cut:
case Pour:
return DoorClass;
case Bake:
case Dry:
case Ferment:
case BlowSteam:
case CoolDown:
case Steam:
case Roast:
case Boil:
case Thicken:
case WarmUp:
case MakeCrispy:
case Finish:
case Damp:
case Defer:
case Grill:
case End:
case Burn:
case Fry:
case HeatUp:
case Ripen:
case RipenKeep:
case BoilSteadily:
case CookGratin:
case Brown:
case Simmer:
case Moisten:
return CookClass;
default:
return InvalidClass;
}
}
Cook::Configuration AbstractCookConfig::type()
{
return type_;
}
QString AbstractCookConfig::icon()
{
return icon_;
}
QString AbstractCookConfig::overlayIcon()
{
return overayIcon_;
}
QString AbstractCookConfig::minLabel()
{
return minLabel_;
}
QString AbstractCookConfig::maxLabel()
{
return maxLabel_;
}
QString AbstractCookConfig::currentLabel()
{
return currentLabel_;
}
int AbstractCookConfig::count()
{
return count_;
}
void AbstractCookConfig::setCount(int value)
{
count_ = value;
if (current_ > count_)
current_ = count_;
}
int AbstractCookConfig::current()
{
return current_;
}
void AbstractCookConfig::setCurrent(int value)
{
current_ = qBound(1, value, count_);
}
int AbstractCookConfig::standard()
{
return standard_;
}
void AbstractCookConfig::setStandard(int value)
|
99b8066f4
김태훈
V0.1.1
|
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
|
standard_ = qBound(1, value, count_);
setCurrent(standard_);
}
int AbstractCookConfig::configureTime(int standardTime)
{
return standardTime;
}
int AbstractCookConfig::configureInterTemp(int standardInterTemp)
{
return standardInterTemp;
}
Cook::Step AbstractCookConfig::configureStep(Cook::Step standardStep)
{
return standardStep;
}
BrightnessConfig::BrightnessConfig()
{
type_ = Cook::Brightness;
icon_ = ":/images/images/auto/gau_icon_01.png";
overayIcon_ = ":/images/images/auto/gau_icon_01_ov.png";
minLabel_ = "연한색";
maxLabel_ = "진한색";
}
Cook::Step BrightnessConfig::configureStep(Cook::Step standardStep)
{
int dVal = current_ - standard_;
qreal m = 1.0 - 0.05 * dVal;
standardStep.humidity =
qBound(0, (int) round(standardStep.humidity * m), 100);
return standardStep;
}
TimeConfig::TimeConfig()
{
type_ = Cook::Time;
icon_ = ":/images/images/auto/011_icon_03.png";
overayIcon_ = ":/images/images/auto/011_icon_03_ov.png";
minLabel_ = "단시간";
maxLabel_ = "장시간";
}
int TimeConfig::configureTime(int standardTime)
{
int dVal = current_ - standard_;
qreal m = 1.0 + 0.1 * dVal;
standardTime = qBound(0, (int) round(standardTime * m), 24 * 60 * 60);
return standardTime;
}
BurnDegreeConfig::BurnDegreeConfig()
{
type_ = Cook::BurnDegree;
icon_ = ":/images/images/auto/gau_icon_02.png";
overayIcon_ = ":/images/images/auto/gau_icon_02_ov.png";
minLabel_ = "중간 익힘";
maxLabel_ = "완전 익힘";
}
Cook::Step BurnDegreeConfig::configureStep(Cook::Step standardStep)
{
int dVal = current_ - standard_;
qreal m = 1.0 + 0.03 * dVal;
standardStep.temp =
qBound(30, (int) round(standardStep.temp * m), 300);
return standardStep;
}
int BurnDegreeConfig::configureInterTemp(int standardInterTemp)
{
int dVal = current_ - standard_;
qreal m = 1.0 + 0.03 * dVal;
standardInterTemp = qBound(0, (int) round(standardInterTemp * m), 99);
return standardInterTemp;
}
QString Cook::name(Cook::StepType type)
{
switch (type)
{
case Cook::Roast:
return "로스팅";
case Cook::Grill:
return "그릴";
case Cook::Boil:
return "끓이기";
case Cook::BoilSteadily:
return "뭉근하게 끓이기";
case Cook::HeatUp:
return "온도 높이기";
case Cook::Thicken:
return "걸쭉하게 만들기";
case Cook::WarmUp:
return "데우기";
case Cook::Simmer:
return "약한 불로 끓이기";
case Cook::End:
return "종료";
case Cook::MakeCrispy:
return "바삭함 주기";
case Cook::Brown:
return "브라우닝(갈색 내기)";
case Cook::BlowSteam:
return "스팀 쏘이기";
case Cook::Damp:
return "습윤 주기";
case Cook::Finish:
return "피니싱";
case Cook::Burn:
return "그을리기";
case Cook::CookGratin:
return "그라탱 요리";
case Cook::CoolDown:
return "식히기";
case Cook::Defer:
return "보류";
case Cook::RipenKeep:
return "숙성 & 보존";
case Cook::Bake:
return "베이킹";
case Cook::Fry:
return "기름에 재빨리 볶기";
case Cook::Steam:
return "찌기";
case Cook::Ripen:
return "촉촉하게";
case Cook::Ferment:
return "숙성";
case Cook::Moisten:
return "발효";
case Cook::Dry:
return "건조시키기";
default:
return "";
}
}
QString Cook::icon(Cook::StepType type)
{
switch (type)
{
case Cook::Roast:
case Cook::Grill:
return ":/images/images/auto/sys_icon_01.png";
case Cook::Boil:
case Cook::BoilSteadily:
case Cook::HeatUp:
case Cook::Thicken:
case Cook::WarmUp:
case Cook::Simmer:
return ":/images/images/auto/sys_icon_02.png";
case Cook::End:
return ":/images/images/auto/sys_icon_03.png";
case Cook::MakeCrispy:
case Cook::Brown:
case Cook::BlowSteam:
case Cook::Damp:
return ":/images/images/auto/sys_icon_04.png";
case Cook::Finish:
return ":/images/images/auto/sys_icon_05.png";
case Cook::Burn:
case Cook::CookGratin:
return ":/images/images/auto/sys_icon_06.png";
case Cook::CoolDown:
return ":/images/images/auto/sys_icon_07.png";
case Cook::Defer:
case Cook::RipenKeep:
return ":/images/images/auto/sys_icon_08.png";
case Cook::Bake:
return ":/images/images/auto/sys_icon_09.png";
case Cook::Fry:
case Cook::Steam:
return ":/images/images/auto/sys_icon_10.png";
case Cook::Ripen:
case Cook::Ferment:
case Cook::Moisten:
return ":/images/images/auto/sys_icon_11.png";
case Cook::Dry:
return ":/images/images/auto/sys_icon_12.png";
default:
return "";
}
}
QString Cook::icon(Cook::CookType type)
{
switch (type)
{
case Poultry:
return ":/images/images/auto/005_auto_icon_01_ov.png";
case Meat:
return ":/images/images/auto/005_auto_icon_02_ov.png";
case Fish:
return ":/images/images/auto/005_auto_icon_03_ov.png";
case Desert:
return ":/images/images/auto/005_auto_icon_04_ov.png";
case Vegetable:
return ":/images/images/auto/005_auto_icon_05_ov.png";
case Bread:
return ":/images/images/auto/005_auto_icon_06_ov.png";
case Etc:
return ":/images/images/auto/005_auto_icon_07_ov.png";
default:
return "";
}
}
FriedRice::FriedRice()
{
name_ = QCoreApplication::tr("볶음밥");
currentStep_ = 0;
stepCount_ = 4;
stepList[0] = { Cook::Preheat, Cook::CombiMode, 100, 150 };
stepList[1] = { Cook::Load, Cook::CombiMode, 0, 0 };
stepList[2] = { Cook::Roast, Cook::CombiMode, 80, 130 };
stepList[3] = { Cook::Roast, Cook::DryMode, 30, 170 };
}
ChickenCook::ChickenCook()
{
type_ = Cook::Poultry;
name_ = QCoreApplication::tr("닭고기 요리");
currentStep_ = 0;
stepCount_ = 5;
stepList[0] = { Cook::Preheat, Cook::CombiMode, 100, 230 };
stepList[1] = { Cook::Load, Cook::CombiMode, 0, 0 };
stepList[2] = { Cook::Roast, Cook::CombiMode, 90, 210 };
stepList[3] = { Cook::Roast, Cook::CombiMode, 50, 173 };
stepList[4] = { Cook::Roast, Cook::DryMode, 50, 200 };
time_ = 39 * 60;
interTempEnabled_ = true;
interTemp_ = 88;
BrightnessConfig *brightness = new BrightnessConfig;
brightness->setCount(5);
brightness->setStandard(3);
brightness->setCurrent(3);
configurations[0] = brightness;
BurnDegreeConfig *burnDegree = new BurnDegreeConfig;
burnDegree->setCount(3);
burnDegree->setStandard(3);
burnDegree->setCurrent(3);
configurations[1] = burnDegree;
}
MeatPie::MeatPie()
{
type_ = Cook::Meat;
name_ = QCoreApplication::tr("고기 파이");
currentStep_ = 0;
stepCount_ = 5;
stepList[0] = { Cook::Preheat, Cook::DryMode, 100, 211 };
stepList[1] = { Cook::Load, Cook::DryMode, 0, 0 };
stepList[2] = { Cook::Bake, Cook::DryMode, 100, 191 };
stepList[3] = { Cook::CoolDown, Cook::DryMode, 100, 120 };
stepList[4] = { Cook::Bake, Cook::DryMode, 40, 120 };
|
99b8066f4
김태훈
V0.1.1
|
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
|
interTempEnabled_ = true;
interTemp_ = 62;
BrightnessConfig *brightness = new BrightnessConfig;
brightness->setCount(5);
brightness->setStandard(3);
brightness->setCurrent(3);
configurations[0] = brightness;
BurnDegreeConfig *burnDegree = new BurnDegreeConfig;
burnDegree->setCount(3);
burnDegree->setStandard(2);
burnDegree->setCurrent(2);
configurations[1] = burnDegree;
}
Croissant::Croissant()
{
type_ = Cook::Bread;
name_ = QCoreApplication::tr("크로와상/페이스트리");
currentStep_ = 0;
stepCount_ = 6;
stepList[0] = { Cook::Preheat, Cook::CombiMode, 100, 180 };
stepList[1] = { Cook::Load, Cook::DryMode, 0, 0 };
stepList[2] = { Cook::BlowSteam, Cook::SteamMode, 100, 98 };
stepList[3] = { Cook::Bake, Cook::DryMode, 100, 170 };
stepList[4] = { Cook::Bake, Cook::DryMode, 70, 170 };
stepList[5] = { Cook::Bake, Cook::DryMode, 20, 170 };
time_ = 18 * 60;
interTempEnabled_ = false;
interTemp_ = 0;
BrightnessConfig *brightness = new BrightnessConfig;
brightness->setCount(5);
brightness->setStandard(3);
brightness->setCurrent(3);
configurations[0] = brightness;
TimeConfig *timeConf = new TimeConfig;
timeConf->setCount(3);
timeConf->setStandard(2);
timeConf->setCurrent(2);
configurations[4] = timeConf;
|