BERBASIS ARDUINO
LAPORAN AKHIR
Disusun oleh :
2019
HALAMAN PENGESAHAN
Oleh :
Tugas Akhir ini telah dipertahankan didepan dewan penguji pada tanggal … dan disahkan oleh :
NIP. 196202231991031001
NIP. 197711202005011002
NIP. 197503252005011001
NIP. 197409262003121001
Mengetahui, Menyetujui,
i
ABSTRAK
Febrian Nur Wardana dan Nur Erdian Refonanda Ramdhani,2020. Sistem
Kontrol Vacuum Pada Ruang Pendingin Berbasis Arduino. Laporan Akhir
progam Studi Teknik Elektronika, Jurusan Teknik Elektro, Politeknik Negeri
Malang 2020.
Pembimbing : Edi Sulistio Budi, ST., MT dan Sidik Nurcahyo, ST .,MT
Pengawetan adalah suatu teknik atau tindakan yang digunakan oleh
manusia pada bahan pangan sedemikian rupa sehingga bahan tersebut tidak
mudah rusak. Tujuan pengawetan yaitu menghambat atau mencegah terjadinya
kerusakan, mempertahankan mutu, menghindarkan terjadinya keracunan dan
mempermudah penanganan dan penyimpanan. Salah satu teknologi pengawetan
adalah ruang pendingin (freeze dryer). Teknologi ini memanfaatkan suhu minus
dan udara yang dikeluarkan oleh vacuum yang menyebabkan buah memiliki
kandungan air yang sedikit.
Pada tugas akhir ini dibuat kontrol vacuum pada ruang pendingin dengan
memanfaatkan keypad sebagai input set point, arduino mega sebagai
mikrokontrolernya, dimmer ac sebagai drivernya dan output akan ditampilkan
di LCD.
Kata Kunci : kontrol Vacuum, Arduino Mega
ABSTRACT
Febrian Nur Wardana and Nur Erdian Refonanda Ramdhani, 2020.
Arduino-Based Vacuum Control System in the Cold Room. Final Report of the
Electronic Engineering Study Program, Department of Electrical Engineering,
Malang State Polytechnic 2020.
Supervisor: Edi Sulistio Budi, ST., MT and Sidik Nurcahyo, ST., MT
Preservation is a technique or action used by humans on food ingredients
in such a way that the material is not easily damaged. The purpose of
preservation is to prevent or prevent damage, maintain quality, avoid poisoning
and facilitate handling and storage. One of the preservation technologies is the
freeze dryer. This technology utilizes the minus temperature and air released by
the vacuum which causes the fruit to have little water content.
In this final project, a vacuum control is made in the cooling room by
using the keypad as the input set point, Arduino Mega as the microcontroller, ac
dimmer as the driver and the output will be displayed on the LCD.
Keywords: Vacuum control, Arduino Mega
ii
KATA PENGANTAR
Puji syukur kehadirat Allah SWT. Atas segala nikmat rahmat serta karunia – Nya yang
diberikan kepada penulis. Sehingga penulis dapat menyusun dan menyelesaikan laporan akhir
yang berjudul “SISTEM KONTROL SUHU PADA RUANG PENDINGIN BERBASIS
ARDUINO”. Laporan Akhir ini disusun untuk memenuhi syarat menyelesaikan pendidikan
Diploma III Jurusan Teknik Elektro Program Studi Teknik Elektronika Politeknik Negeri
Malang.
Pada kesempatan kali ini dengan segala kerendahan hati penulis mengucapkan
terimakasih kepada pihak – pihak yang telah membantu dan membimbing dalam menyusun
Laporan Akhir, yaitu kepada :
1. Bapak. Drs. Awan setyawan, MM., selaku Direktur Politeknik Negeri Malang.
2. Bapak. Mochammad Junus, ST., MT., selaku Ketua Jurusan Teknik Elektro.
3. Bapak. Herwandi, S.T., MT., selaku Ketua Program Studi Teknik Elektronika.
4. Bapak. Edi Sulistio Budi,S.T.,M.T., selaku Pembimbing I.
5. Bapak. Sidik Nurcahyo, ST .,MT selaku Pembimbing II.
6. Kedua orang tua yang telah memeberikan doa restu dan saudara – saudaraku serta teman –
teman yang telah banyak memberikan doa dan dukungan.
Penulis menyadari bahwa masih banyak kekurangan dalam pembuatan Laporan Akhir ini,
maka dari itu penulis mengharapkan kritik dan saran yang bersifat membangun dan semoga
Laporan Akhir ini dapat membantu dan bermanfaat bagi yang membaca.
Penulis
iii
DAFTAR ISI
HALAMAN PENGESAHAN.....................................................................................................i
ABSTRAK.................................................................................................................................ii
KATA PENGANTAR..............................................................................................................iii
DAFTAR ISI.............................................................................................................................iv
DAFTAR GAMBAR...............................................................................................................vii
DAFTAR TABEL...................................................................................................................viii
BAB I.........................................................................................................................................1
PENDAHULUAN......................................................................................................................1
1.4 Tujuan..........................................................................................................................2
BAB II........................................................................................................................................4
TINJAUAN PUSTAKA.............................................................................................................4
2.3 MS5803-14BA.............................................................................................................7
2.7 I2C.............................................................................................................................10
iv
2.8 Keypad.......................................................................................................................11
BAB III.....................................................................................................................................18
3.1.1 Input.......................................................................................................................18
3.1.2 Proses.....................................................................................................................19
3.1.3 Output.....................................................................................................................19
BAB IV.....................................................................................................................................29
v
4.3 Pengujian LCD DAN I2C..........................................................................................29
BAB V......................................................................................................................................40
5.1 Kesimpulan................................................................................................................40
5.2 Saran..........................................................................................................................40
DAFTAR PUSTAKA...............................................................................................................41
LAMPIRAN.............................................................................................................................42
vi
DAFTAR GAMBAR
vii
DAFTAR TABEL
viii
BAB I
PENDAHULUAN
1
`2
1.4 Tujuan
Tujuan dari pembuatan proposal laporan akhir ini adalah:
1. Dapat membuat dan merancang kontrol motor vacuum pada ruang
pendingin
2. Mempermudah pengawetan dalam proses ruang pendingin.
1.6 Luaran LA
Luaran yang diharapkan dari laporan akhir ini adalah kontrol motor
vacuum pada ruang pendingin, dengan mengimplementasi pemrograman
mikrokontroller menggunakan PID.
BAB II
TINJAUAN PUSTAKA
2.3 MS5803-14BA
Pressure sensor atau sensor dapat mengukur tekanan air yang terjadi pada
membran, sehingga dapat dijadikan acuan pada tingkat tekanan pada kedalaman
tertentu, tekanan air hakikatnya memiliki hubungan dengan kedalaman air.
2.5 Dimmer AC
Dimmer AC adalah rangkaian alat pengatur kecepatan putaran motor AC
yang sering disebut PWM Controller, dapat mengatur temperatur, kecepatan
putaran motor AC, terang lampu ruangan dan sebagainya. Controller ini
menggunakan TRIAC bi-directional yang memudahkan pengaturan arus hingga
16A. Selain itu, juga dapat membatasi arus agar tidak terjadi overload pada
peralatan elemen.Mudul tersebut memungkinkan pengguna untuk mengatur
voltase arus antara 50 Volt hingga 220 Volt pada peralatan kecil seperti oven,
pemanas air, penanak nasi, dimer lampu, motor AC kecil serta setrikaan. Dimmer
AC memiliki 4 pin yang terhubung ke Arduino:
`9
1 Vcc ~ +5v
2 Gnd ~ -5v
3 PWM ~ PWM
4 Z-C ~ Pendeteksi Zero-Cross
Gambar 5 Dimmer AC
(Sumber :
Google.com)
menyesuaikan diri dan segmen yang diaktifkan terlihat menjadi gelap dan
membentuk karakter data yang ingin ditampilkan.
2.6.1 Fungsi Pin LCD (Liquid Cristal Display)
Gambar 6 LCD 20 x 4
2.7 I2C
Pada LCD 20x4 yang dilengkapi dengan I2C/TWI sistem komunikasi hanya
memerlukan 4 kabel yang dihubungkan dengan pin Arduino. Pada papan Arduino
secara umum SDA (Serial Data) pada input analog pin 4 dan SCl (Serial Clock)
pada input analog pin 5. Pada modul I²C/TWI juga dilengkapi dengan
`11
Gambar 7 I2C
(Sumber : Data Sheet I2C)
2.8 Keypad
Keypad merupakan antarmuka antara komunikasi perangkat elektronik
dengan manusia yang disebut dengan istilah HMI (Human Machine
Interface).Keypad tersusun atas 16 buah push button yang dirangkai dengan
konfigurasi dalam bentuk matrix, sehingga memiliki index baris dan kolom
sehingga pin input ke Arduino dapat dikurangi.
Gambar 8 Keypad
(Sumber : Data Sheet Keypad)
Jika e(T) mendekati konstan (bukan nol) maka u(t) akan menjadi
sangat besar sehingga diharapkan dapat memperbaiki error. Jika e(T)
mendekati nol maka efek kontrol I ini semakin kecil. Kontrol I dapat
memperbaiki sekaligus menghilangkan respon steady-state, namun
pemilihan Ki yang tidak tepat dapat menyebabkan respon transien yang
tinggi sehingga dapat menyebabkan ketidakstabilan sistem. Pemilihan Ki
yang sangat tinggi justru dapat menyebabkan output berosilasi karena
menambah orde system
Keluaran pengontrol ini merupakan hasil penjumlahan yang terus
menerus dari perubahan masukannya. Jika sinyal kesalahan tidak
mengalami perubahan, maka keluaran akan menjaga keadaan seperti
sebelum terjadinya perubahan masukan. Sinyal keluaran pengontrol
integral merupakan luas bidang yang dibentuk oleh kurva kesalahan /
error.
Ciri-ciri pengontrol integral :
1. Keluaran pengontrol integral membutuhkan selang waktu tertentu,
sehingga pengontrol integral cenderung memperlambat respon.
2. Ketika sinyal kesalahan berharga nil, keluaran pengontrol akan
bertahan pada nilai sebelumnya.
3. Jika sinyal kesalahan tidak berharga nol, keluaran akan menunjukkan
kenaikan atau penurunan yang dipengaruhi oleh besarnya sinyal
kesalahan dan nilai Ki.
4. Konstanta integral Ki yang berharga besar akan mempercepat
hilangnya offset. Tetapi semakin besar nilai konstanta Ki akan
mengakibatkan peningkatan osilasi dari sinyal keluaran pengontrol.
2.9.3 Kontrol Derivatif
Keluaran pengontrol diferensial memiliki sifat seperti halnya suatu
operasi derivatif. Perubahan yang mendadak pada masukan pengontrol
akan mengakibatkan perubahan yang sangat besar dan cepat. Ketika
masukannya tidak mengalami perubahan, keluaran pengontrol juga tidak
mengalami perubahan, sedangkan apabila sinyal masukan berubah
mendadak dan menaik (berbentuk fungsi step), keluaran menghasilkan
sinyal berbentuk
`15
impuls. Jika sinyal masukan berubah naik secara perlahan (fungsi ramp),
keluarannya justru merupakan fungsi step yang besar magnitudenya sangat
dipengaruhi oleh kecepatan naik dari fungsi ramp dan factor konstanta Kd.
Sinyal kontrol u yang dihasilkan oleh kontrol D dapat dinyatakan
sebagai G(s)=s.Kd Dari persamaan di atas, nampak bahwa sifat dari
kontrol D ini dalam konteks “kecepatan” atau rate dari error. Dengan
sifat ini ia dapat digunakan untuk memperbaiki respon transien dengan
memprediksi error yang akan terjadi. Kontrol Derivative hanya berubah
saat ada perubahan error sehingga saat error statis kontrol ini tidak akan
bereaksi, hal ini pula yang menyebabkan kontroler Derivative tidak
dapat dipakai
sendiri
Ciri-ciri pengontrol derivatif :
1. Pengontrol tidak dapat menghasilkan keluaran jika tidak ada
perubahan pada masukannya (berupa perubahan sinyal kesalahan)
2. Jika sinyal kesalahan berubah terhadap waktu, maka keluaran
yang dihasilkan pengontrol tergantung pada nilai Kd dan laju
perubahan sinyal kesalahan.
3. Pengontrol diferensial mempunyai suatu karakter untuk mendahului,
sehingga pengontrol ini dapat menghasilkan koreksi yang signifikan
sebelum pembangkit kesalahan menjadi sangat besar. Jadi
pengontrol diferensial dapat mengantisipasi pembangkit kesalahan,
memberikan aksi yang bersifat korektif dan cenderung meningkatkan
stabilitas sistem.
4. Dengan meningkatkan nilai Kd, dapat meningkatkan stabilitas sistem
dan mengurangi overshoot.
Berdasarkan karakteristik pengontrol ini, pengontrol diferensial
umumnya dipakai untuk mempercepat respon awal suatu sistem, tetapi
tidak memperkecil kesalahan pada keadaan tunaknya. Kerja pengontrol
diferensial hanyalah efektif pada lingkup yang sempit, yaitu pada periode
peralihan. Oleh sebab itu pengontrol diferensial tidak pernah digunakan
tanpa ada kontroler lainnya.
`16
Pengendali 𝑲𝑷 𝑻𝑰 𝑻𝑫
1
P - -
𝑎
`17
0.9
PI 3L -
𝑎
1.2 𝐿
PID 2L
𝑎 2
𝐾𝐼 𝐾𝑃
= 𝑇𝐼
𝐾 𝐷 = 𝐾 𝑃𝑇 𝐷
Pengendali 𝑲𝑷 𝑻𝑰 𝑻𝑫
𝐾𝑈
P - -
2
2𝐾𝑈 4𝑇𝑈
PI -
5 5
3𝐾𝑈 𝑇𝑈 3𝑇𝑈
PID
5 2 25
BAB III
JALA JALA
ADAPTOR
REGULATOR
SENSOR
MODUL
ARDUINO VACCUM
KEYPAD DIMMER AC
MEGA
MODUL RTC
SWITCH MODUL SD
CARD
LCD
18
`19
2. Keypad
Keypad digunakan untuk memasukan set point.
3. Modul RTC
Modul RTC digunakan untuk mencacah waktu secara real
time
4. Switch
Switch digunakan sebagai tombol On/Off untuk
menghidupkan alat atau mesin agar tetap dalam keadaan standby
3.1.2 Proses
Arduino mega merupakan kontroler yang digunakan sebagai proses
untuk memasukan input dan menghasilkan output.
3.1.3 Output
1. LCD 20x4
Merupakan komponen yang digunakan untuk menampilkan
nilai data.
2. Modul SD Card
Modul ini digunakan sebagai penyimpanan data.
3. Modul Dimmer AC SCR
Modul Dimmer AC SCR (driver) ini digunakan sebagai
pengatur masuknya tegangan pada kondensor yang membuat
tekanan pada kondensor bekerja sesuai dengan masuknya
tegangan.
Alat ini mendapatkan supply tegangan dari jala-jala 220V dan diubah menjadi
tegangan DC 5V untuk dijadikan supply teganan Arduino mega. Pertama alat ini
menampilkan hasil pembacaan sd card dan device yang akan di atur. Selanjutnya
masukan nilai pid menggunakan keypad. Selanjutnya memasukan nilai tekanan
vacuum yang diinginkan dan interval data yang akan diambil dengan keypad.
Kemudian nilai masukan akan diproses oleh Arduino Mega. Setelah itu driver
akan mengaktifkan motor vacuum. Setelah motor vacuum aktif maka sensor akan
`20
mendeteksi berapa besar tekanan yang dihasilkan motor vacuum dan mengirimkan
feedback ke Arduino mega apakah sudah sesuai dengan set point yang telah di
masukan dan ditampilkan pada LCD, apabila nilai belum sesuai maka motor
vacuum akan terus aktif sampai nilai tekanan sesuai dengan set point. Apabila
data yang dibutuhkan telah tercapai maka tekan tombol end untuk mengakhiri
proses vacuum pada ruang pendingin.
a. Panjang : 25 cm
b. Lebar : 15 cm
c. Tinggi : 5 cm
2.Tabung separator
Tabung berfungsi memisahkan dua jenis zat, tabung separator pada
alat kami menggunakan tabung freon bekas yang dimodifikasi dengan
desain sedemikian rupa.
3. Chamber
Chamber menggunakan toples kaca bervolume 100ml yang
digunakan untuk menaruh buah yang akan diawetkan.
4. Chase vacuum sensor
Chase sensor terbuat besi dan diberi pengunci untuk mengurangi
kebocoran.
Modul RTC
LCD 20x4
I2C
3.4 Perancangan Mekanik
1. Kontrol Box
2. Ruang Pendingin
INPUT AC
Output
1
Output
2
𝑉
𝑅=
𝐼
220𝑉
𝑅=
10𝑚𝐴
𝑅 = 2200𝑜ℎ𝑚
MULAI
MASUKAN
NILAI KP,KI,KD
MASUKAN NILAI
TEKANAN
MOTOR
VACUUM AKTIF
SENSOR
MENDETEKSI
TEKANAN
MOTOR VACUUM
AKTIF
TIDAK
APAKAH TOMBOL
STOP DITEKAN?
YA
STOP
MULAI
MENYALAKAN
KONTROLER
MASUKKAN NILAI
Kp,Ki,Kd
JALANKAN SISTEM
KONTROL
AMATI HASIL
PENGUJIAN
APAKAH HASIL
TELAH SESUAI ?
MULAI
29
`30
Hasil Pengujian
Set point = 3 torr
Nilai Tekanan Tegangan(V)
11.64 220
8.74 220
6.36 220
4.81 190
3.69 140
3.16 140
2.86 50
Tabel 3 Tabel Pengujian Driver
Hasil dari pengujian driver dapat dilihat melalui data
yang tersimpan pada sdcard, dimana dari hasil data tersebut pada
saat nilai tekanan belum mendekati set point maka tegangan
tetap sebesar 220 Volt. Tetapi jika nilai tekanan sudah
mendekati atau melebihi set point, maka tegangan akan turun.
Langkah Percobaan
Menghubungkan sensor dengan arduino mega sesuai
rangkaian yang telah dibuat
Upload progam yang telah dibuat
Nyalakan motor vacuum
Amati perubahan tekanan pada LCD
Hasil Percobaan
Hasil Pengujian
1. Nilai set point 1 torr
Data yang didapat pada set point 1 torr adalah 0.93 torr. Dengan
nilai tersebut dapat dihitung nilai error dengan rumus:
𝑆𝑃 −
𝑃𝑉 ) 𝑥100%
𝐸𝑟𝑟𝑜𝑟 = (
𝑆𝑃
Keterangan :
SP = Set point.
PV = Pressure Variable.
0.93 − 1.0
𝐸𝑟𝑟𝑜𝑟 = ( ) 𝑥100%
1.0
𝐸𝑟𝑟𝑜𝑟 = −7 %
𝑃𝑉 −
𝑆𝑃 ) 𝑥100%
𝐸𝑟𝑟𝑜𝑟 = (
𝑆𝑃
Keterangan :
SP = Set point.
PV = Pressure Variable.
1.3 − 1.5
𝐸𝑟𝑟𝑜𝑟 = ( ) 𝑥100%
1.5
𝐸𝑟𝑟𝑜𝑟 = −13.3 %
`38
Dari pengujian dengan memberikan nilai set point sebesar 1.5 torr
didapatkan hasil sebesar 1.3 torr dengan waktu pengambilan data selama
2 menit 30 detik. Pada pengujian ini nilai PID yang dimasukkan sebesar
Kp=203,Ki=001 dan Kd=007. Dengan hasil tersebut nilai dapat dihitung
nilai error sebesar -13%.
10
4
2.44
0
0:00:00
0:00:16
0:00:32
0:00:48
0:01:12
0:01:28
0:01:44
0:02:07
0:02:23
0:02:39
0:02:55
0:03:18
0:03:34
0:03:50
0:04:13
0:04:29
0:04:45
0:05:08
0:05:24
0:05:40
0:05:56
0:06:19
0:06:35
0:06:51
0:07:14
0:07:30
0:07:46
0:08:09
0:08:25
0:08:41
0:08:57
0:09:20
0:09:36
0:09:52
Gambar 30 Hasil Pengujian 2.5 torr
𝑃𝑉 − 𝑆𝑃
𝐸𝑟𝑟𝑜𝑟 = ) 𝑥100%
( 𝑆
𝑃
Keterangan :
SP = Set point.
PV = Pressure Variable.
2.44 − 2.5
𝐸𝑟𝑟𝑜𝑟 = ( ) 𝑥100%
2.5
𝐸𝑟𝑟𝑜𝑟 = −2.4 %
Pada pengujian dengan set point sebesar 2.5 torr didapatkan nilai
tekanan akhir sebesar 2.44 dalam waktu 9 menit 52 detik. Pada pengujian
`39
ini nilai Kp=203, Ki=001 dan Kd=007. Nilai error yang didapatkan dari
pengujian ini sebesasr -2.4%. Nilai Set point 3.0 torr
10
6
4.12
4 2.86
0
0:00:00
0:00:06
0:00:12
0:00:18
0:00:24
0:00:30
0:00:36
0:00:42
0:00:48
0:00:54
0:01:08
0:01:14
0:01:20
0:01:26
0:01:32
0:01:38
0:01:44
0:01:50
0:01:56
0:02:09
0:02:15
0:02:21
0:02:27
0:02:33
0:02:39
0:02:45
0:02:51
0:02:57
0:03:10
0:03:16
0:03:22
Gambar 31 Grafik Hasil pengujian dengan set point 3.0 Torr
𝑃𝑉 −
𝐸𝑟𝑟𝑜𝑟 = 𝑆𝑃 ) 𝑥100%
(
𝑆𝑃
Keterangan :
SP = Set point.
PV = Pressure Variable.
2.86 − 3.0
𝐸𝑟𝑟𝑜𝑟 = ( ) 𝑥100%
3.0
𝐸𝑟𝑟𝑜𝑟 = −4.6 %
40
DAFTAR PUSTAKA
1. Putra, Aditya Ilmawan. "Sistem Pengaturan Posisi Sudut Putar Motor DC
Pada Model Rotary Parking Menggunakan Kontroler PID Berbasis
Arduino Mega 2560." Jurnal Mahasiswa TEUB 1.3 (2013).
2. Aulani, Rahmat, Indriani Anizar, and Hadi Faisal. RANCANG BANGUN
KENDALI KECEPATAN MOTOR INDUKSI 1 FASA PADA
KONVEYOR PROTOTIPE ALAT PENGERING KARET DENGAN
PENGATURAN SUDUT PENYALAAN (FIRING ANGLE) TRIAC.
Diss. Universitas Bengkulu.
3. Wicaksono, Andrey, Sudjadi Sudjadi, and Iwan Setiawan. "Implementasi
Logika Fuzzy Dalam Kontrol Posisi Kedalaman Pada Remotely Operated
Underwater Vehicle (ROV)." Transmisi 19.2 (2017): 72-79.
4. Yulvianti, Meri, Widya Ernayati, and Tarsono Tarsono. "Pemanfaatan
ampas kelapa sebagai bahan baku tepung kelapa tinggi serat dengan
metode freeze drying." Jurnal Integrasi Proses 5.2 (2015).
5. Djalal, Muhammad Ruswandi, et al. "Desain optimal kontroler PID motor
DC menggunakan cuckoo search algorithm." SENTIA 2015 7.1 (2015).
41
LAMPIRAN
42
`
`
`
The Arduino Mega 2560 is a microcontroller board based on the ATmega2560 (datasheet). It
has 54 digital input/output pins (of which 14 can be used as PWM outputs), 16 analog inputs,
4 UARTs (hardware serial ports), a 16 MHz crystal oscillator, a USB connection, a power
jack, an ICSP header, and a reset button. It contains everything needed to support the
microcontroller; simply connect it to a computer with a USB cable or power it with a AC-to-DC
adapter or battery to get started. The Mega is compatible with most shields designed for the
Arduino Duemilanove or Diecimila.
`
Microcontroller ATmega2560
Operating Voltage 5V
Input Voltage (recommended) 7-12V
Input Voltage (limits) 6-20V
Digital I/O Pins 54 (of which 14 provide PWM output)
Analog Input Pins 16
DC Current per I/O Pin 40 mA
DC Current for 3.3V Pin 50 mA
Flash Memory 256 KB of which 8 KB used by bootloader
SRAM 8 KB
EEPROM 4 KB
Clock Speed 16 MHz
`
The Arduino Mega2560 can be powered via the USB connection or with an external power supply. The power source is
selected automatically. External (non-USB) power can come either from an AC-to-DC adapter (wall-wart) or battery. The
adapter can be connected by plugging a 2.1mm center-positive plug into the board's power jack. Leads from a battery
can be inserted in the Gnd and Vin pin headers of the POWER connector.
The board can operate on an external supply of 6 to 20 volts. If supplied with less than 7V, however, the 5V pin may
supply less than five volts and the board may be unstable. If using more than 12V, the voltage regulator may overheat
and damage the board. The recommended range is 7 to 12 volts.
The Mega2560 differs from all preceding boards in that it does not use the FTDI USB-to-serial driver chip. Instead, it
features the Atmega8U2 programmed as a USB-to-serial converter.
VIN. The input voltage to the Arduino board when it's using an external power source (as opposed to 5 volts
from the USB connection or other regulated power source). You can supply voltage through this pin, or, if
supplying voltage via the power jack, access it through this pin.
5V. The regulated power supply used to power the microcontroller and other components on the board. This
can come either from VIN via an on-board regulator, or be supplied by USB or another regulated 5V supply.
3V3. A 3.3 volt supply generated by the on-board regulator. Maximum current draw is 50 mA.
GND. Ground pins.
The ATmega2560 has 256 KB of flash memory for storing code (of which 8 KB is used for the bootloader), 8 KB of
SRAM and 4 KB of EEPROM (which can be read and written with the EEPROM library).
Each of the 54 digital pins on the Mega can be used as an input or output, using pinMode(), digitalWrite(), and
digitalRead() functions. They operate at 5 volts. Each pin can provide or receive a maximum of 40 mA and has an
internal pull-up resistor (disconnected by default) of 20-50 kOhms. In addition, some pins have specialized functions:
Serial: 0 (RX) and 1 (TX); Serial 1: 19 (RX) and 18 (TX); Serial 2: 17 (RX) and 16 (TX); Serial 3: 15 (RX) and
14 (TX). Used to receive (RX) and transmit (TX) TTL serial data. Pins 0 and 1 are also connected to the
corresponding pins of the ATmega8U2 USB-to-TTL Serial chip .
External Interrupts: 2 (interrupt 0), 3 (interrupt 1), 18 (interrupt 5), 19 (interrupt 4), 20 (interrupt 3), and 21
(interrupt 2). These pins can be configured to trigger an interrupt on a low value, a rising or falling edge, or a
change in value. See the attachInterrupt() function for details.
PWM: 0 to 13. Provide 8-bit PWM output with the analogWrite() function.
SPI: 50 (MISO), 51 (MOSI), 52 (SCK), 53 (SS). These pins support SPI communication, which, although
provided by the underlying hardware, is not currently included in the Arduino language. The SPI pins are also
broken out on the ICSP header, which is physically compatible with the Duemilanove and Diecimila.
LED: 13. There is a built-in LED connected to digital pin 13. When the pin is HIGH value, the LED is on, when
the pin is LOW, it's off.
I2C: 20 (SDA) and 21 (SCL). Support I2C (TWI) communication using the Wire library (documentation on the
Wiring website). Note that these pins are not in the same location as the I2C pins on the Duemilanove.
The Mega2560 has 16 analog inputs, each of which provide 10 bits of resolution (i.e. 1024 different values). By default
they measure from ground to 5 volts, though is it possible to change the upper end of their range using the AREF pin and
analogReference() function.
AREF. Reference voltage for the analog inputs. Used with analogReference().
Reset. Bring this line LOW to reset the microcontroller. Typically used to add a reset button to shields which
block the one on the board.
`
The Arduino Mega2560 has a number of facilities for communicating with a computer, another Arduino, or
other microcontrollers. The ATmega2560 provides four hardware UARTs for TTL (5V) serial communication.
An ATmega8U2 on the board channels one of these over USB and provides a virtual com port to software on
the computer (Windows machines will need a .inf file, but OSX and Linux machines will recognize the board
as a COM port automatically. The Arduino software includes a serial monitor which allows simple textual
data to be sent to and from the board. The RX and TX LEDs on the board will flash when data is being
transmitted via the ATmega8U2 chip and USB connection to the computer (but not for serial communication
on pins 0 and 1).
A SoftwareSerial library allows for serial communication on any of the Mega's digital pins.
The ATmega2560 also supports I2C (TWI) and SPI communication. The Arduino software includes a Wire
library to simplify use of the I2C bus; see the documentation on the Wiring website for details. To use the SPI
communication, please see the ATmega2560 datasheet.
The Arduino Mega2560 can be programmed with the Arduino software (download). For details, see the
reference and tutorials.
The Atmega2560 on the Arduino Mega comes preburned with a bootloader that allows you to upload new
code to it without the use of an external hardware programmer. It communicates using the original STK500
protocol (reference, C header files).
You can also bypass the bootloader and program the microcontroller through the ICSP (In-Circuit Serial
Programming) header; see these instructions for details.
`
Rather then requiring a physical press of the reset button before an upload, the Arduino Mega2560 is
designed in a way that allows it to be reset by software running on a connected computer. One of the
hardware flow control lines (DTR) of the ATmega8U2 is connected to the reset line of the ATmega2560 via a
100 nanofarad capacitor. When this line is asserted (taken low), the reset line drops long enough to reset the
chip. The Arduino software uses this capability to allow you to upload code by simply pressing the upload
button in the Arduino environment. This means that the bootloader can have a shorter timeout, as the
lowering of DTR can be well- coordinated with the start of the upload.
This setup has other implications. When the Mega2560 is connected to either a computer running Mac OS X
or Linux, it resets each time a connection is made to it from software (via USB). For the following half-second
or so, the bootloader is running on the Mega2560. While it is programmed to ignore malformed data (i.e.
anything besides an upload of new code), it will intercept the first few bytes of data sent to the board after a
connection is opened. If a sketch running on the board receives one-time configuration or other data when it
first starts, make sure that the software with which it communicates waits a second after opening the
connection and before sending this data.
The Mega contains a trace that can be cut to disable the auto-reset. The pads on either side of the trace can
be soldered together to re-enable it. It's labeled "RESET-EN". You may also be able to disable the auto-reset
by connecting a 110 ohm resistor from 5V to the reset line; see this forum thread for details.
The Arduino Mega has a resettable polyfuse that protects your computer's USB ports from shorts and
overcurrent. Although most computers provide their own internal protection, the fuse provides an extra layer
of protection. If more than 500 mA is applied to the USB port, the fuse will automatically break the
connection until the short or overload is removed.
The maximum length and width of the Mega PCB are 4 and 2.1 inches respectively, with the USB connector
and power jack extending beyond the former dimension. Three screw holes allow the board to be attached to
a surface or case. Note that the distance between digital pins 7 and 8 is 160 mil (0.16"), not an even multiple
of the 100 mil spacing of the other pins.
The Mega is designed to be compatible with most shields designed for the Diecimila or Duemilanove. Digital
pins 0 to 13 (and the adjacent AREF and GND pins), analog inputs 0 to 5, the power header, and ICSP
header are all in equivalent locations. Further the main UART (serial port) is located on the same pins (0 and
1), as are external interrupts 0 and 1 (pins 2 and 3 respectively). SPI is available through the ICSP header on
both the Mega and Duemilanove / Diecimila. Please note that I2C is not located on the same pins on the
Mega (20 and 21) as the Duemilanove / Diecimila (analog inputs 4 and 5).
`
Arduino can sense the environment by receiving input from a variety of sensors and can affect its
surroundings by controlling lights, motors, and other actuators. The microcontroller on the board is
programmed using the Arduino programming language (based on Wiring) and the Arduino
development environment (based on Processing). Arduino projects can be stand-alone or they can
communicate with software on running on a computer (e.g. Flash, Processing, MaxMSP).
Arduino is a cross-platoform program. You’ll have to follow different instructions for your personal
OS. Check on the Arduino site for the latest instructions. http://arduino.cc/en/Guide/HomePage
Once you have downloaded/unzipped the arduino IDE, you can Plug the Arduino to your PC via USB cable.
File>Sketchbook>
Arduino-0017>Examples>
Digital>Blink
and select the right serial port, the one arduino is attached to.
`
Dimensioned DraWincj
1 0 1,6
MS5803-14BA Miniature 14 bar Module
1. Warranties
1.1 The producer warrants that its products will conform to the Specifications. This warranty lasts for one (1) years from the date of the sale. The
producer shall not be liable for any defects that are caused by neglect, misuse or mistreatment by the Customer, including improper installation or testing, or
for any products that have been altered or modified in any way by a Customer. Moreover, The producer shall not be liable for any defects that result from
Customer's design, specifications or instructions for such products. Testing and other quality control techniques are used to the extent the producer deems
necessary.
1.2 If any products fail to conform to the warranty set forth above, the producer's sole liability shall be to replace such products. The producer's liability
shall be limited to products that are determined by the producer not to conform to such warranty. If the producer elects to replace such products, the producer
shall have a reasonable time to replacements. Replaced products shall be warranted for a new full warrantyperiod.
1.3 EXCEPT AS SET FORTH ABOVE, PRODUCTS ARE PROVIDED "AS IS" AND "WITH ALL FAULTS." THE PRODUCER DISCLAIMS ALL
OTHER WARRANTIES, EXPRESS OR IMPLIED, REGARDING PRODUCTS, INCLUDING BUT NOT LIMITED TO, ANY IMPLIED WARRANTIES OF
MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE
1.4 Customer agrees that prior to using any systems that include the producer products, Customer will test such systems and the functionality of
the products as used in such systems. The producer may provide technical, applications or design advice, quality characterization, reliability data or
other services. Customer acknowledges and agrees that providing these services shall not expand or otherwise alter the producer's warranties, as
set forth above, and no additional obligations or liabilities shall arise from the producer providing such services.
1.5 The Arduino products are not authorized for use in safety-critical applications where a failure of the product would reasonably be expected to cause
severe personal injury or death. Safety-Critical Applications include, without limitation, life support devices and systems, equipment or systems for the operation
of nuclear facilities and weapons systems. Arduino products are neither designed nor intended for use in military or aerospace applications or environments
and for automotive applications or environment. Customer acknowledges and agrees that any such use of Arduino products which is solely at the
Customer's risk, and that Customer is solely responsible for compliance with all legal and regulatory requirements in connection with such use.
1.6 Customer acknowledges and agrees that it is solely responsible for compliance with all legal, regulatory and safety-related requirements concerning its
products and any use of Arduino products in Customer's applications, notwithstanding any applications-related information or support that may be provided by
the producer.
2. Indemnification
The Customer acknowledges and agrees to defend, indemnify and hold harmless the producer from and against any and all third-party losses, damages,
liabilities and expenses it incurs to the extent directly caused by: (i) an actual breach by a Customer of the representation and warranties made under this
terms and conditions or (ii) the gross negligence or willful misconduct by the Customer.
In no event the producer shall be liable to the Customer or any third parties for any special, collateral, indirect, punitive, incidental, consequential or exemplary
damages in connection with or arising out of the products provided hereunder, regardless of whether the producer has been advised of the possibility of such
damages. This section will survive the termination of the warranty period.
4. Changes to specifications
The producer may make changes to specifications and product descriptions at any time, without notice. The Customer must not rely on the absence or
characteristics of any features or instructions marked "reserved" or "undefined." The producer reserves these for future definition and shall have no responsibility
whatsoever for conflicts or incompatibilities arising from future changes to them. The product information on the Web Site or Materials is subject to change
without notice. Do not finalize a design with this information.
DESCRIPTION
The MS5803-14BA is a new generation of high resolution pressure sensors with SPI and I2C bus
interface. It is optimized for depth measurement systems with a water depth resolution of 1cm and below.
The sensor module includes a high linear pressure sensor and an ultra low power 24 bit ΔΣ ADC with
internal factory calibrated coefficients. It provides a precise digital 24 Bit pressure and temperature value
and different operation modes that allow the user to optimize for conversion speed and current
consumption. A high resolution temperature output allows the implementation of a depth measurement
systems and thermometer function without any additional sensor. The MS5803-14BA can be interfaced to
any microcontroller. The communication protocol is simple, without the need to programming internal
registers in the device. The gel protection and antimagnetic stainless steel cap protects against 30 bar
overpressure water resistant. This new sensor module generation is based on leading MEMS technology
and latest benefits from the Intersema’s proven experience and know-how in high volume manufacturing
of pressure modules have been widely used for over a decade. This sensing principle employed leads to
very low hysteresis and high stability of both pressure and temperature signal.
(1) FEATURES
Sensor Memory
Interface IC (PROM)
SGND
PS CSB
GND
ELECTRICAL CHARACTERISTICS
512 1.7
256 0.9
Maximum error with supply VDD = 1.8 V … 3.6 V -20 +20 mbar
voltage (1)
2048 0.3
512 0.6
256 1.0
(6) TEMPERATURE
OUTPUT CHARACTERISTICS (VDD = 3 V, T = 25°C UNLESS
OTHERWISE NOTED)
2048 0.003
512 0.008
256 0.012
VDD
Meas. MUX
PS CSB Interface
PGA
-IN ADC dig.
Filter
SDI / SDA SDO
SGND