Rancang Bangun Alat Pendeteksi Kualitas Minyak Goreng Berdasarkan Warna RGB Berbasis Mikrokontroler ATMega 8535

43

DAFTAR LAMPIRAN

Universitas Sumatera Utara

43

LAMPIRAN 1
Skematik Keseluruhan Rangkaian

Universitas Sumatera Utara

44

LAMPIRAN 2
PROGRAM
/*******************************************************
Project : baca warna
Version :
Date

: 5/26/2017
Author : Roby Y.Jaya
Company : J-Tech
Comments: punya kak Anie Afrilla
Chip type
: ATmega8535
Program type
: Application
AVR Core Clock frequency: 1.000000 MHz
Memory model
: Small
External RAM size
: 0
Data Stack size
: 128
*******************************************************/
#include
#include
#include
#include

#include







// Declare your global variables here
unsigned int R, G, B;
unsigned char buff1[16];
//unsigned char buff2[16];
float x, y, z;
float x1, y1, z1;
#define ADC_VREF_TYPE ((0