Presentasi sedang didownload. Silahkan tunggu

Presentasi sedang didownload. Silahkan tunggu

PART 5 TRAINING INPUT Dosen : Dwisnanto Putro, ST, M.Eng.

Presentasi serupa


Presentasi berjudul: "PART 5 TRAINING INPUT Dosen : Dwisnanto Putro, ST, M.Eng."— Transcript presentasi:

1 PART 5 TRAINING INPUT Dosen : Dwisnanto Putro, ST, M.Eng

2 • Input 1 = Mikrokontroler menerima Input berupa tegangan (+) • Input 0 = Mikrokontroler menerima Input berupa tegangan (–) ataupun Ground Input Published By Stefanikha69

3 • Cara kerja Push Button Published By Stefanikha69

4 • System Push Button Published By Stefanikha69

5 • Jenis-Jenis Push Button Published By Stefanikha69

6 • Mikrokontroler menerima sinyal Ground • Rangkaian Push Button Published By Stefanikha69

7 • Rangkaian Push Button Pada Uc Published By Stefanikha69

8 if (syarat ==) {statement/proses;} • Struktur program kode INPUT Published By Stefanikha69

9 if (syarat ==) {statement/proses;} else {statement/proses;} • Struktur program kode INPUT else Published By Stefanikha69

10 • New Project • Run CodeVision Published By Stefanikha69

11

12 • Chip select Published By Stefanikha69

13 configuration chip select • Chip ATMEGA 8535 • Clock 8.000000 Mhz Published By Stefanikha69

14 • Untuk port gunakan PORTC untuk LED PORTC.0 – PORTC.7 = output (0) Published By Stefanikha69

15 • Gunakan PORTD.2 dan PORTD.3 sebagai Input pullup (P) Published By Stefanikha69

16 • Save and Generate Published By Stefanikha69

17 • Save File – make folder and files Published By Stefanikha69

18 • Display Published By Stefanikha69

19 • Configuration ready compile Published By Stefanikha69

20

21 • CODE PROGRAM • Untuk menyalakan led pada posisi PORTC.0dengan syarat harus menekan pushbutton PORTD.2; while(1){ if (PIND.2==0)// jika PIND.2 ditekan {PORTC=0b11111110;}// led nyala PORTC.0 } Published By Stefanikha69

22 SETTING USB – DOWNLOADER : • INSTALL DEVICE USB DOWNLOADER • CONNECT USB DOWNLOADER TO PC/LAPTOP SETTING COM PORT: • COMPUTER -> MANAGE -> DEVICE MANAGER • PORT (COM &LPT) -> PROLIFIC USB TO SERIAL COMM PORT (COM....) Published By Stefanikha69

23 • Configuration PORT Programmer Published By Stefanikha69

24 Choice : • AVR Chip programmer type • COM PORT • BAUD RATE Published By Stefanikha69

25 • COMPILER AND BUILD ALL PROGRAM Or Shift F9 Published By Stefanikha69

26 • Connecting USB Downloader - PC/Laptop - Microcontroller, And.... Published By Stefanikha69

27 • Process Downloading......... Published By Stefanikha69

28 FINISH Published By Stefanikha69

29 • Error DOWNLOADING Solution : • Check COM PORT • Check Baud Rate • Check Connection Downloader • Check Prog/Serial TTL select Published By Stefanikha69

30 • CV AVR WITH PROTEUS OPEN PROGRAM ISIS PROTEUS PROFESSIONAL Published By Stefanikha69

31 • synchronization cv avr with proteus • Creat Project and Design • Double click pict microcntroller Published By Stefanikha69

32 • synchronization cv avr with proteus • Select clock frequency • Select program file, (HEX file type) Published By Stefanikha69

33 • synchronization cv avr with proteus • Running ISIS Proteus • FINISH... Created by. Dwisnanto Putro, Manado, September 2012 Published By Stefanikha69

34 TASK BUATLAH project dengan system: • JIKA PUSH BUTTON PADA PORTD.2 DITEKAN MAKA LED pada PORTC.2 MENYALA • JIKA TIDAK DITEKAN PUSHBUTTON PADA PORTD.2 MAKA LED PADA PORTC.2 MATI Published By Stefanikha69

35 TASK BUATLAH project dengan system: • JIKA PUSH BUTTON PADA PORTD.2 DITEKAN MAKA LED pada PORTC.2 MENYALA • JIKA PUSH BUTTON PADA PORTD.3 DITEKAN MAKA LED pada PORTC.3 MENYALA Published By Stefanikha69

36 TASK BUATLAH project dengan system: • JIKA PUSH BUTTON PADA PORTD.2 DITEKAN MAKA LED pada PORTC.2 MENYALA • JIKA PUSH BUTTON PADA PORTD.3 DITEKAN MAKA LED pada PORTC.3 MENYALA • JIKA TIDAK DITEKAN PUSHBUTTON PADA PORTD.2 dan PORTD.3 MAKA LED PADA PORTC.2 DAN PORTC.3 MATI Published By Stefanikha69

37 TASK BUATLAH project dengan system: • JIKA PUSH BUTTON PADA PORTD.2 DITEKAN MAKA LED pada PORTC.2 MENYALA BERKEDIP SEBANYAK 2 KALI • JIKA PUSH BUTTON PADA PORTD.3 DITEKAN MAKA LED pada PORTC.3 MENYALA BERKEDIP SEBANYAK 3 KALI • DENGAN DELAY = 300 ms Published By Stefanikha69

38 TASK BUATLAH project dengan system: • JIKA PUSH BUTTON PADA PORTD.2 DITEKAN MAKA LED pada PORTC.2 MENYALA • JIKA PUSH BUTTON PADA PORTD.3 DITEKAN MAKA LED pada PORTC.3 MENYALA • JIKA PUSH BUTTON PADA PORTD.2 DAN PORTD.3 DITEKAN BERSAMAAN MAKA LED SEMUA MATI Published By Stefanikha69

39 TASK BUATLAH project dengan system: • JIKA PUSH BUTTON PADA PORTD.2 DITEKAN MAKA terjadi proses LED berjalan pada PORTC.0 s/d PORTC.7 • JIKA PUSH BUTTON PADA PORTD.3 DITEKAN MAKA terjadi proses LED berjalan pada PORTC.7 s/d PORTC.0 Published By Stefanikha69


Download ppt "PART 5 TRAINING INPUT Dosen : Dwisnanto Putro, ST, M.Eng."

Presentasi serupa


Iklan oleh Google