Tugas Pendahuluan Modul 1


[KEMBALI KE MENU SEBELUMNYA]




  • Hardware [Kembali]

    Arduino ATMega2560


    IC L293D


    Motor DC
  • Rangkaian Simulasi [Kembali]
  • Flowchart [Kembali]
  • Listing Program [Kembali]
    'Program 4 : LED dan Keypad
    $regfile = "m8535.dat"

    $crystal = 16000000
    Ddra = &B1110000
    Porta = &B11111111
    Ddrb = &B11111111
    Do
    Porta = &B1011111
       Waitms 1

       If Pina.1 = 0 Then
       Portb = &H80
       Waitms 200
       Portb = &H40
       Waitms 200
       Portb = &H20
       Waitms 200
       Portb = &H10
       Waitms 200
       Portb = &H08
       Waitms 200
       Portb = &H04
       Waitms 200
       Portb = &H02
       Waitms 200
       Portb = &H01
       Waitms 200
       End If

       If Pina.2 = 0 Then
       Portb = &H80
       Waitms 20
       Portb = &HC0
       Waitms 20
       Portb = &HE0
       Waitms 20
       Portb = &HF0
       Waitms 20
       Portb = &HF8
       Waitms 20
       Portb = &HFC
       Waitms 20
       Portb = &HFE
       Waitms 20
       Portb = &HFF
       Waitms 20
       End If

       If Pina.3 = 0 Then
       Do
       Portb = &HFF
       Waitms 20
       Portb = &H00
       Waitms 20
       Loop
       End If


    Loop
    End
  • Video Simulasi [Kembali] 

Tidak ada komentar:

Posting Komentar

Bahan Presentasi untuk Mata Kuliah Kimia 2020 Oleh : Teguh Putra Trila Seyepa 1610951011   Dosen Pengampu : Darwison,M.T   Referensi:...