8051 I/O programming

Discussion in 'Embedded Systems and Microcontrollers' started by aghag, Oct 5, 2012.

  1. aghag

    aghag Thread Starter New Member

    Joined:
    Oct 5, 2012
    Messages:
    3
    1.In 8051,Write a program to take in data through P1.1 and send it out through P2.6?
    2.In 8051,Write a program to monitor P1.6. when it is high,send 55H to P2?
    3.In 8051,Write a program to monitor the P2.5 bit. when it is high, send 99H to P1. If it is low, send 66H to P1?
    4.In 8051,Write a program to get status of P1.7 and put it on P1.2 continuously?
    5.In 8051,write a program to generate a square wave of 25% duty cycle on pin P2.5?

    NOTE: ALL PROGRAMMING IS DONE IN PINNACLE SOFTWARE USED FOR MICRO CONTROLLER 8051.PLEASE HELP ASAPTHANKS
  2. aghag

    aghag Thread Starter New Member

    Joined:
    Oct 5, 2012
    Messages:
    3
    help please
  3. ActivePower

    ActivePower Member

    Joined:
    Mar 15, 2012
    Messages:
    153
    Location:
    India (GMT + 5.5)
    Have you tried doing any of them? With what results?
  4. Arm_n_Legs

    Arm_n_Legs Active Member

    Joined:
    Mar 7, 2007
    Messages:
    183
    Location:
    Singapore
    MOV C,P1.1
    MOV P2.6,C

    WAIT: JNB P1.6,WAIT
    MOV P2,#55H

    JNB P2.5,W1
    MOV P1,#99H
    SJMP W2
    W1: MOV P1,#66H
    W2: ; continue from there

    W1: MOV C,P1.7
    MOV P1.2,C
    SJMP W1
    aghag likes this.
  5. aghag

    aghag Thread Starter New Member

    Joined:
    Oct 5, 2012
    Messages:
    3
    can you please also explain which answer is to which i got a little confuse?
Similar Threads
Forum Title Date
Embedded Systems and Microcontrollers Topic: C Programming for 8051: SFR directions as arguments Jul 17, 2014
Embedded Systems and Microcontrollers 8051 C Programming Bug Jun 10, 2014
Embedded Systems and Microcontrollers 8051 programming help Apr 17, 2014
Embedded Systems and Microcontrollers Help:embedded programming for 8051 using 8255 Apr 4, 2013
Embedded Systems and Microcontrollers lcd interfacing with 8051 c programming Sep 1, 2012

Share This Page