LAMPIRAN 1
A. Gambar Inkubator
(Bahan Inkubator) (Ukuran dan Massa Inkubator)
(Lapisan isolator Inkubator) (Inkubator dilapisi bahan isolator kayu)
B. Gambar Rangkaian Power Supply
(Trafo pada Rangkaian Power Supply (Rangkaian Power Supply)
C. Gambar Inkubator dan Rangkaian Pemanas Induksi
(Inkubator tampak dari depan)
1. Program Alat Pada Mikrokontroler dengan Code Vision AVR
/***************************************************** This program was produced by the
CodeWizardAVR V1.25.9 Standard Automatic Program Generator
© Copyright 1998-2008 Pavel Haiduc, HP InfoTech s.r.l. pranala:http://www.hpinfotech.com
Project : Version :
Date : 10/20/2016
Chip type : Atmega8535 Program type : Application
AVR Core Clock frequency : 16.000000 MHz Memory model : Small
// Declare your global variables here
void main(void) {
//PORTA initialization
PORTD=0x00; DDRD=0xFF;
//Time/counter 1Initialization //Clock Source : System Clock //Clock Value : 10800 Khz //Mode : Fast PWM Top = 00FFh //OC1A output : Non-Inv
//OC1B output : Non-Inv //Noise canceler : Off
//Input Capture on Falling edge //Timer1 overflow interruption : Off TCCR1A = 0xA1
TCCR1A = 0xA1
#define heater1 PORTC.6 #define heater2 PORTC.7
// Alphanumeric LCD Module functions #asm
.equ __lcd_port=0x15 ;PORTC #endasm
#include <alcd.h>
// Standard Input/Output functions #include <stdio.h>
#include <delay.h>
#define ADC_VREF_TYPE 0x40
// Read the AD conversion result
ADMUX=adc_input | (ADC_VREF_TYPE & 0xff);
// Delay needed for the stabilization of the ADC input voltage delay_us(10);
// Start the AD conversion ADCSRA|=0x40;
// Wait for the AD conversion to complete while ((ADCSRA & 0x10)==0);
ADCSRA|=0x10; return ADCW; }
// Declare your global variables here
void main(void)
// Timer/Counter 0 initialization // Clock source: System Clock // Clock value: Timer 0 Stopped // Mode: Normal top=FFh // OC0 output: Disconnected TCCR0=0x00;
// Timer/Counter 1 initialization // Clock source: System Clock // Clock value: Timer 1 Stopped // Mode: Normal top=FFFFh // OC1A output: Discon. // OC1B output: Discon. // Noise Canceler: Off
// Input Capture on Falling Edge // Timer 1 Overflow Interrupt: Off // Input Capture Interrupt: Off // Compare A Match Interrupt: Off // Compare B Match Interrupt: Off TCCR1A=0x00;
// Timer/Counter 2 initialization // Clock source: System Clock // Clock value: Timer 2 Stopped // Mode: Normal top=FFh // OC2 output: Disconnected ASSR=0x00;
OCR2=0x00;
// External Interrupt(s) initialization // INT0: Off
// INT1: Off // INT2: Off MCUCR=0x00; MCUCSR=0x00;
// Timer(s)/Counter(s) Interrupt(s) initialization TIMSK=0x00;
// USART initialization
// Communication Parameters: 8 Data, 1 Stop, No Parity // USART Receiver: On
// USART Transmitter: On // USART Mode: Asynchronous // USART Baud Rate: 9600
// Analog Comparator initialization // Analog Comparator: Off
// Analog Comparator Input Capture by Timer/Counter 1: Off ACSR=0x80;
SFIOR=0x00; // ADC initialization
// ADC Clock frequency: 750.000 kHz // ADC Voltage Reference: AVCC pin // ADC High Speed Mode: Off
2. Program Antarmuka Komputer menggunakan Software Visual Basic 6.0.
/***************************************************** Private Sub Form_Load()
Timer1.Enabled = False MSComm1.PortOpen = True
Text1(0).Text = 99 - VScroll2.Value Text1(1).Text = 59 - VScroll1.Value Text2(0).Text = "" VScroll1.Value = 58 VScroll2.Value = 99
Label1(5).Caption = Chr(176) & "C" End Sub
Private Sub Command1_Click() 'Run/Stop
Timer1.Interval = (Val(Text1(0).Text) * 60 + Val(Text1(1).Text)) * 1000 If Timer1.Enabled = False Then
Timer1.Enabled = True Command1.Caption = "Stop" Command2.Enabled = False Command3.Enabled = False Else
End Sub
Private Sub MSComm1_OnComm() xx = MSComm1.Input
On Error GoTo errhand
Text2(0).Text = Asc(Left(xx, 1)) Text2(1).Text = Asc(Right(xx, 1)) With Adodc1.Recordset .
AddNew ! jam = Time !
suhu = Val(Text2(0).Text) !. Update
End With
Adodc1.Recordset.Requery Adodc1.Recordset.MoveLast errhand: