All About Circuits Forum  

Go Back   All About Circuits Forum > Software, Microcomputing, and Communications Forums > Embedded Systems and Microcontrollers

Notices

Embedded Systems and Microcontrollers Discussion forum for projects and working with embedded systems and microcontrollers (FPGAs, PICs, AVRs). Get help with hardware issues and embedded programming.

Reply   Post New Thread
 
Thread Tools Display Modes
  #1  
Old 10-05-2012, 03:35 PM
aghag aghag is offline
New Member
 
Join Date: Oct 2012
Posts: 3
Default 8051 I/O programming

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
Reply With Quote
  #2  
Old 10-05-2012, 03:36 PM
aghag aghag is offline
New Member
 
Join Date: Oct 2012
Posts: 3
Default

help please
Reply With Quote
  #3  
Old 10-05-2012, 08:51 PM
ActivePower's Avatar
ActivePower ActivePower is offline
Senior Member
 
Join Date: Mar 2012
Location: India (GMT + 5.5)
Posts: 152
Blog Entries: 3
Default

Have you tried doing any of them? With what results?
__________________
'I will either find a way or make one' - Hannibal
Reply With Quote
  #4  
Old 10-06-2012, 02:27 AM
Arm_n_Legs Arm_n_Legs is offline
Senior Member
 
Join Date: Mar 2007
Posts: 174
Default

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
Reply With Quote
The Following User Says Thank You to Arm_n_Legs For This Useful Post:
aghag (10-07-2012)
  #5  
Old 10-07-2012, 12:55 PM
aghag aghag is offline
New Member
 
Join Date: Oct 2012
Posts: 3
Default

Quote:
Originally Posted by Arm_n_Legs View Post
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
can you please also explain which answer is to which i got a little confuse?
Reply With Quote
Reply   Post New Thread


Similar Threads
Thread Thread Starter Forum Replies Last Post
lcd interfacing with 8051 c programming khan yousufzai Embedded Systems and Microcontrollers 3 09-07-2012 08:37 AM
I/O ports, serial COM port, timer, 8051 PG1995 General Electronics Chat 7 04-25-2012 12:31 PM
Problem with programming the 8051 maxfourier Embedded Systems and Microcontrollers 9 12-01-2011 05:57 PM
8051 Programming question/clarification Unteddybear Embedded Systems and Microcontrollers 3 11-29-2011 12:25 AM
i/o programming for 16f84a kavindu.balasuriya Programmer's Corner 5 03-16-2011 01:50 PM

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 03:09 PM.


User-posted content, unless source quoted, is licensed under a Creative Commons Public Domain License.
Powered by vBulletin
Copyright ©2000 - 2014, vBulletin Solutions, Inc.