SlideShare a Scribd company logo
Penyusunan Program Percobaan
Running LED
Rizqun Nad Putra (1710501072)
R. Suryoto Edy Raharjo, S.T., M.Eng.
Teknik Elektro
Fakultas Teknik
Universitas Tidar
Program Coba 1
$regfile = "m16def.dat"
$crystal = 8000000
Config Porta = Output
Config Portb = Output
Do
Porta = &B11111111
Portb = &B11110000
Waitms 100
Porta = &B00000000
Portb = &B00000000
Waitms 100
Loop
End
Start
Compiler setup
Hardware setup
Do
LED Terhubung PortA
bit 0 – 7 dan PortB bit
0 – 3 ON
Wait 100 ms
LED Terhubung PortA
bit 0 – 7 dan PortB bit
0 – 3 OFF
Wait 100 ms
Loop
End
Program Coba 2
$regfile = "m16def.dat"
$crystal = 8000000
Config Porta = Output
Config Portb = Output
Do
Porta = &B00000000
Portb = &B11000000
Waitms 300
Porta = &B00000000
Portb = &B00110000
Waitms 300
Porta = &B11000000
Portb = &B00000000
Waitms 300
Porta = &B00110000
Portb = &B00000000
Waitms 300
Porta = &B00001100
Portb = &B00000000
Waitms 300
Porta = &B00000011
Portb = &B00000000
Waitms 300
Loop
End
Start
Compiler setup
Hardware setup
Do
LED Terhubung PortB
bit 0 dan 1 ON
Wait 300 ms
LED Terhubung PortB
bit 2 dan 3 ON
Wait 300 ms
LED Terhubung PortA
bit 0 dan 1 ON
Wait 300 ms
LED Terhubung PortA
bit 2 dan 3 ON
LED Terhubung PortA
bit 4 dan 5 ON
LED Terhubung PortA
bit 6 dan 7 ON
Wait 300 ms
Wait 300 ms
Wait 300 ms
Loop
End
Program Coba 3
$regfile = "m16def.dat"
$crystal = 8000000
Config Porta = Output
Config Portb = Output
Do
Porta = &B10000000
Portb = &B00010000
Waitms 300
Porta = &B01000000
Portb = &B00100000
Waitms 300
Porta = &B00100000
Portb = &B01000000
Waitms 300
Porta = &B00010000
Portb = &B10000000
Waitms 300
Porta = &B00001001
Portb = &B00000000
Waitms 300
Porta = &B00000110
Portb = &B00000000
Waitms 300
Porta = &B00000000
Portb = &B00000000
Waitms 300
Porta = &B00000110
Portb = &B00000000
Waitms 300
Porta = &B00001001
Portb = &B00000000
Waitms 300
Porta = &B00010000
Portb = &B10000000
Waitms 300
Porta = &B00100000
Portb = &B01000000
Waitms 300
Porta = &B01000000
Portb = &B00100000
Waitms 300
Porta = &B10000000
Portb = &B00010000
Waitms 300
Loop
End
Start
Compiler setup
Hardware setup
Do
LED Terhubung PortA bit 0 dan PortB bit 3 ON
Wait 300 ms
LED Terhubung PortA bit 1 dan PortB bit 2 ON
Wait 300 ms
LED Terhubung PortA bit 2 dan PortB bit 1 ON
Wait 300 ms
LED Terhubung PortA bit 3 dan PortB bit 0 ON
Wait 300 ms
LED Terhubung PortA bit 4 dan PortA bit 7 ON
Wait 300 ms
AB
LED Terhubung PortA bit 5 dan PortA bit 6 ON
Wait 300 ms
LED Terhubung PortA dan PortB OFF
Wait 300 ms
LED Terhubung PortA bit 5 dan PortA bit 6 ON
LED Terhubung PortA bit 4 dan PortA bit 7 ON
LED Terhubung PortA bit 3 dan PortB bit 0 ON
LED Terhubung PortA bit 2 dan PortB bit 1 ON
Wait 300 ms
Wait 300 ms
Wait 300 ms
Wait 300 ms
AB
AB
AB
LED Terhubung PortA bit 1 dan PortB bit 2 ON
Wait 300 ms
Wait 300 ms
LED Terhubung PortA bit 0 dan PortB bit 3 ON
End
Loop
Sekian dan Terimakasih

More Related Content

Similar to Program Running Led

Chp7 pic 16 f84 interfacing - copy
Chp7 pic 16 f84 interfacing - copyChp7 pic 16 f84 interfacing - copy
Chp7 pic 16 f84 interfacing - copy
mkazree
 
Analog to digital converter
Analog to digital converterAnalog to digital converter
Analog to digital converter
Corrado Santoro
 
8051-mazidi-solution
8051-mazidi-solution8051-mazidi-solution
8051-mazidi-solution
ZunAib Ali
 

Similar to Program Running Led (20)

2 n3904
2 n39042 n3904
2 n3904
 
Adc r2013 lab manual
Adc r2013 lab manualAdc r2013 lab manual
Adc r2013 lab manual
 
ADC LAB MANUAL.docx
ADC LAB MANUAL.docxADC LAB MANUAL.docx
ADC LAB MANUAL.docx
 
DC/AC 3-Phase Inverter (LTspice Model)
DC/AC 3-Phase Inverter (LTspice Model) DC/AC 3-Phase Inverter (LTspice Model)
DC/AC 3-Phase Inverter (LTspice Model)
 
Chp7 pic 16 f84 interfacing - copy
Chp7 pic 16 f84 interfacing - copyChp7 pic 16 f84 interfacing - copy
Chp7 pic 16 f84 interfacing - copy
 
TFT индикатор с емкостным тачем WF35LTIBCDSC0# для работы с отладками Arduino.
TFT индикатор с емкостным тачем WF35LTIBCDSC0# для работы с отладками Arduino.TFT индикатор с емкостным тачем WF35LTIBCDSC0# для работы с отладками Arduino.
TFT индикатор с емкостным тачем WF35LTIBCDSC0# для работы с отладками Arduino.
 
abc song
abc songabc song
abc song
 
Anexo reporte_SEL 487E.pdf
Anexo reporte_SEL 487E.pdfAnexo reporte_SEL 487E.pdf
Anexo reporte_SEL 487E.pdf
 
Original N-Channel IGBT 70A 330V FGPF4633 4633 300A 330V TO-200F New Fairchild
Original N-Channel IGBT 70A 330V FGPF4633 4633 300A 330V TO-200F New FairchildOriginal N-Channel IGBT 70A 330V FGPF4633 4633 300A 330V TO-200F New Fairchild
Original N-Channel IGBT 70A 330V FGPF4633 4633 300A 330V TO-200F New Fairchild
 
Apr9600 voice-recording-and-playback-system-with-j
Apr9600 voice-recording-and-playback-system-with-jApr9600 voice-recording-and-playback-system-with-j
Apr9600 voice-recording-and-playback-system-with-j
 
Original IGBT FGPF50N33 50N33 50A 330V TO-220F New Fairchild
Original IGBT FGPF50N33 50N33 50A 330V TO-220F New FairchildOriginal IGBT FGPF50N33 50N33 50A 330V TO-220F New Fairchild
Original IGBT FGPF50N33 50N33 50A 330V TO-220F New Fairchild
 
Analog to digital converter
Analog to digital converterAnalog to digital converter
Analog to digital converter
 
Aplikasi pemograman mikrokontroler
Aplikasi pemograman mikrokontrolerAplikasi pemograman mikrokontroler
Aplikasi pemograman mikrokontroler
 
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On SemiconductorOriginal PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
 
8051-mazidi-solution
8051-mazidi-solution8051-mazidi-solution
8051-mazidi-solution
 
Original PNP Transistor DTA143 A143 143 DTA143ESATP TO-92 New Rohm
Original PNP Transistor DTA143 A143 143 DTA143ESATP TO-92 New RohmOriginal PNP Transistor DTA143 A143 143 DTA143ESATP TO-92 New Rohm
Original PNP Transistor DTA143 A143 143 DTA143ESATP TO-92 New Rohm
 
D882 npn
D882 npnD882 npn
D882 npn
 
semiconductor Bc327
semiconductor Bc327semiconductor Bc327
semiconductor Bc327
 
Bc327
Bc327Bc327
Bc327
 
Blueoptics bo28c3443640d 1000base-2bx-u csfp dual bidi transceiver 40km singl...
Blueoptics bo28c3443640d 1000base-2bx-u csfp dual bidi transceiver 40km singl...Blueoptics bo28c3443640d 1000base-2bx-u csfp dual bidi transceiver 40km singl...
Blueoptics bo28c3443640d 1000base-2bx-u csfp dual bidi transceiver 40km singl...
 

Recently uploaded

Automobile Management System Project Report.pdf
Automobile Management System Project Report.pdfAutomobile Management System Project Report.pdf
Automobile Management System Project Report.pdf
Kamal Acharya
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
R&R Consult
 
Laundry management system project report.pdf
Laundry management system project report.pdfLaundry management system project report.pdf
Laundry management system project report.pdf
Kamal Acharya
 

Recently uploaded (20)

NO1 Pandit Amil Baba In Bahawalpur, Sargodha, Sialkot, Sheikhupura, Rahim Yar...
NO1 Pandit Amil Baba In Bahawalpur, Sargodha, Sialkot, Sheikhupura, Rahim Yar...NO1 Pandit Amil Baba In Bahawalpur, Sargodha, Sialkot, Sheikhupura, Rahim Yar...
NO1 Pandit Amil Baba In Bahawalpur, Sargodha, Sialkot, Sheikhupura, Rahim Yar...
 
The Ultimate Guide to External Floating Roofs for Oil Storage Tanks.docx
The Ultimate Guide to External Floating Roofs for Oil Storage Tanks.docxThe Ultimate Guide to External Floating Roofs for Oil Storage Tanks.docx
The Ultimate Guide to External Floating Roofs for Oil Storage Tanks.docx
 
A case study of cinema management system project report..pdf
A case study of cinema management system project report..pdfA case study of cinema management system project report..pdf
A case study of cinema management system project report..pdf
 
Scaling in conventional MOSFET for constant electric field and constant voltage
Scaling in conventional MOSFET for constant electric field and constant voltageScaling in conventional MOSFET for constant electric field and constant voltage
Scaling in conventional MOSFET for constant electric field and constant voltage
 
ASME IX(9) 2007 Full Version .pdf
ASME IX(9)  2007 Full Version       .pdfASME IX(9)  2007 Full Version       .pdf
ASME IX(9) 2007 Full Version .pdf
 
Online resume builder management system project report.pdf
Online resume builder management system project report.pdfOnline resume builder management system project report.pdf
Online resume builder management system project report.pdf
 
KIT-601 Lecture Notes-UNIT-5.pdf Frame Works and Visualization
KIT-601 Lecture Notes-UNIT-5.pdf Frame Works and VisualizationKIT-601 Lecture Notes-UNIT-5.pdf Frame Works and Visualization
KIT-601 Lecture Notes-UNIT-5.pdf Frame Works and Visualization
 
RESORT MANAGEMENT AND RESERVATION SYSTEM PROJECT REPORT.pdf
RESORT MANAGEMENT AND RESERVATION SYSTEM PROJECT REPORT.pdfRESORT MANAGEMENT AND RESERVATION SYSTEM PROJECT REPORT.pdf
RESORT MANAGEMENT AND RESERVATION SYSTEM PROJECT REPORT.pdf
 
Quality defects in TMT Bars, Possible causes and Potential Solutions.
Quality defects in TMT Bars, Possible causes and Potential Solutions.Quality defects in TMT Bars, Possible causes and Potential Solutions.
Quality defects in TMT Bars, Possible causes and Potential Solutions.
 
HYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generationHYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generation
 
Automobile Management System Project Report.pdf
Automobile Management System Project Report.pdfAutomobile Management System Project Report.pdf
Automobile Management System Project Report.pdf
 
2024 DevOps Pro Europe - Growing at the edge
2024 DevOps Pro Europe - Growing at the edge2024 DevOps Pro Europe - Growing at the edge
2024 DevOps Pro Europe - Growing at the edge
 
İTÜ CAD and Reverse Engineering Workshop
İTÜ CAD and Reverse Engineering WorkshopİTÜ CAD and Reverse Engineering Workshop
İTÜ CAD and Reverse Engineering Workshop
 
Pharmacy management system project report..pdf
Pharmacy management system project report..pdfPharmacy management system project report..pdf
Pharmacy management system project report..pdf
 
Top 13 Famous Civil Engineering Scientist
Top 13 Famous Civil Engineering ScientistTop 13 Famous Civil Engineering Scientist
Top 13 Famous Civil Engineering Scientist
 
Introduction to Machine Learning Unit-4 Notes for II-II Mechanical Engineering
Introduction to Machine Learning Unit-4 Notes for II-II Mechanical EngineeringIntroduction to Machine Learning Unit-4 Notes for II-II Mechanical Engineering
Introduction to Machine Learning Unit-4 Notes for II-II Mechanical Engineering
 
Democratizing Fuzzing at Scale by Abhishek Arya
Democratizing Fuzzing at Scale by Abhishek AryaDemocratizing Fuzzing at Scale by Abhishek Arya
Democratizing Fuzzing at Scale by Abhishek Arya
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
 
Natalia Rutkowska - BIM School Course in Kraków
Natalia Rutkowska - BIM School Course in KrakówNatalia Rutkowska - BIM School Course in Kraków
Natalia Rutkowska - BIM School Course in Kraków
 
Laundry management system project report.pdf
Laundry management system project report.pdfLaundry management system project report.pdf
Laundry management system project report.pdf
 

Program Running Led

  • 1. Penyusunan Program Percobaan Running LED Rizqun Nad Putra (1710501072) R. Suryoto Edy Raharjo, S.T., M.Eng. Teknik Elektro Fakultas Teknik Universitas Tidar
  • 2. Program Coba 1 $regfile = "m16def.dat" $crystal = 8000000 Config Porta = Output Config Portb = Output Do Porta = &B11111111 Portb = &B11110000 Waitms 100 Porta = &B00000000 Portb = &B00000000 Waitms 100 Loop End Start Compiler setup Hardware setup Do LED Terhubung PortA bit 0 – 7 dan PortB bit 0 – 3 ON Wait 100 ms LED Terhubung PortA bit 0 – 7 dan PortB bit 0 – 3 OFF Wait 100 ms Loop End
  • 3.
  • 4. Program Coba 2 $regfile = "m16def.dat" $crystal = 8000000 Config Porta = Output Config Portb = Output Do Porta = &B00000000 Portb = &B11000000 Waitms 300 Porta = &B00000000 Portb = &B00110000 Waitms 300 Porta = &B11000000 Portb = &B00000000 Waitms 300 Porta = &B00110000 Portb = &B00000000 Waitms 300 Porta = &B00001100 Portb = &B00000000 Waitms 300 Porta = &B00000011 Portb = &B00000000 Waitms 300 Loop End
  • 5. Start Compiler setup Hardware setup Do LED Terhubung PortB bit 0 dan 1 ON Wait 300 ms LED Terhubung PortB bit 2 dan 3 ON Wait 300 ms LED Terhubung PortA bit 0 dan 1 ON Wait 300 ms LED Terhubung PortA bit 2 dan 3 ON LED Terhubung PortA bit 4 dan 5 ON LED Terhubung PortA bit 6 dan 7 ON Wait 300 ms Wait 300 ms Wait 300 ms Loop End
  • 6.
  • 7. Program Coba 3 $regfile = "m16def.dat" $crystal = 8000000 Config Porta = Output Config Portb = Output Do Porta = &B10000000 Portb = &B00010000 Waitms 300 Porta = &B01000000 Portb = &B00100000 Waitms 300 Porta = &B00100000 Portb = &B01000000 Waitms 300 Porta = &B00010000 Portb = &B10000000 Waitms 300 Porta = &B00001001 Portb = &B00000000 Waitms 300 Porta = &B00000110 Portb = &B00000000 Waitms 300 Porta = &B00000000 Portb = &B00000000 Waitms 300 Porta = &B00000110 Portb = &B00000000 Waitms 300 Porta = &B00001001 Portb = &B00000000 Waitms 300 Porta = &B00010000 Portb = &B10000000 Waitms 300 Porta = &B00100000 Portb = &B01000000 Waitms 300 Porta = &B01000000 Portb = &B00100000 Waitms 300 Porta = &B10000000 Portb = &B00010000 Waitms 300 Loop End
  • 8. Start Compiler setup Hardware setup Do LED Terhubung PortA bit 0 dan PortB bit 3 ON Wait 300 ms LED Terhubung PortA bit 1 dan PortB bit 2 ON Wait 300 ms LED Terhubung PortA bit 2 dan PortB bit 1 ON Wait 300 ms LED Terhubung PortA bit 3 dan PortB bit 0 ON Wait 300 ms LED Terhubung PortA bit 4 dan PortA bit 7 ON Wait 300 ms AB
  • 9. LED Terhubung PortA bit 5 dan PortA bit 6 ON Wait 300 ms LED Terhubung PortA dan PortB OFF Wait 300 ms LED Terhubung PortA bit 5 dan PortA bit 6 ON LED Terhubung PortA bit 4 dan PortA bit 7 ON LED Terhubung PortA bit 3 dan PortB bit 0 ON LED Terhubung PortA bit 2 dan PortB bit 1 ON Wait 300 ms Wait 300 ms Wait 300 ms Wait 300 ms AB AB
  • 10. AB LED Terhubung PortA bit 1 dan PortB bit 2 ON Wait 300 ms Wait 300 ms LED Terhubung PortA bit 0 dan PortB bit 3 ON End Loop
  • 11.