Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
09/14/10 03:38
Read: times


 
#178552 - but it is ...
Responding to: ???'s previous message
I tried using the following code (from this site) and it behaves exactly the same , it sends the output three more times after i power down the circuit.
so what do the experts say . is it the hardware? something i need to do in the RS232 circuit?


;*****************************************************************
;This is an example of polled transmit
;*****************************************************************
;
$MOD51
;
CR EQU 0DH
LF EQU 0AH
;
	ORG 	0
	LJMP 	MAIN
;
	ORG 	100H
MAIN:   LCALL 	SERINIT
	MOV 	DPTR,#HELLO
	LCALL 	TEXT_OUT
	MOV 	DPTR,#MSG1
	LCALL 	TEXT_OUT
	MOV 	DPTR,#MSG2
	LCALL 	TEXT_OUT
LOOP: 	AJMP 	LOOP 				;STOP HERE
;*****************************************************************
;Other Serial Messages
;
HELLO: 	DB 'Hello World',CR,LF,0
MSG1: 	DB 'I am sending messages to my terminal!',CR,LF,0
MSG2: 	DB 'This is fun..',CR,LF,0
;*****************************************************************
SERINIT: ;Initialize serial port
	CLR 	TR1
	CLR 	TI
	CLR 	RI
	MOV 	SCON,#01011010B 	;TI SET INDICATES TRANSMITTER READY.
					;MODE 1 REN
	MOV 	TMOD,#00100001B 	;TIMER 1 MODE 8 BIT AUTO RELOAD
	MOV 	TH1,#0FDH 		;TIMER RELOAD VALUE
	SETB 	TR1 			;START TIMER
	MOV 	DPTR,#SINIT
	LCALL 	TEXT_OUT
	RET
;
SINIT: 	DB 	CR,LF
	DB 	'Serial Port Initialized! '
CRLF: 	DB 	CR,LF,0
;*****************************************************************
TEXT_OUT:
WT1: 	CLR 	A
	MOVC 	A,@A+DPTR
	INC 	DPTR
	JZ 	WT2
	LCALL 	CHAR_OUT
	AJMP 	WT1
WT2: 	RET
;*****************************************************************
CHAR_OUT:
	CLR 	TI
	MOV 	SBUF,A
	JNB 	TI,$
CORET: 	RET
;*****************************************************************
END

 



List of 81 messages in thread
TopicAuthorDate
strange behaviour in serial communication            01/01/70 00:00      
   Slow VCC Decay            01/01/70 00:00      
      Get rid of the crappy R/C reset circuit            01/01/70 00:00      
   try this experiment...            01/01/70 00:00      
      totally irrelevant            01/01/70 00:00      
         thanks all            01/01/70 00:00      
            if you are running 5V ....            01/01/70 00:00      
               I agree            01/01/70 00:00      
         What's irrelevant is..            01/01/70 00:00      
            Not irrelevant to evaluate before buying            01/01/70 00:00      
            if this refer to my post ....            01/01/70 00:00      
               I am glad i started such a healthy discussion :)            01/01/70 00:00      
                  not start but restrart            01/01/70 00:00      
                     Will be more threads            01/01/70 00:00      
               to Gary Peek            01/01/70 00:00      
      I doubt that will help            01/01/70 00:00      
   bad news            01/01/70 00:00      
      time to show ...            01/01/70 00:00      
         Oh My Gosh            01/01/70 00:00      
            I do not know to which extent ...            01/01/70 00:00      
               A number of short forms are commonly accepted in formal text            01/01/70 00:00      
                  we are getting distracted here            01/01/70 00:00      
               What I would like to outlaw            01/01/70 00:00      
            SMS? I think not. Just in a hurry to prove...            01/01/70 00:00      
         here is the code again            01/01/70 00:00      
            that code could not possibly produce            01/01/70 00:00      
               but it is ...            01/01/70 00:00      
                  here are the screenshots from hyperterminal            01/01/70 00:00      
                     Still Seems Like...            01/01/70 00:00      
                     Could Also Be            01/01/70 00:00      
                     By the way...            01/01/70 00:00      
                        good advice and an addendum            01/01/70 00:00      
                           supervisor decoupling            01/01/70 00:00      
                              But things are quite slow!            01/01/70 00:00      
                                 yes cutting of DC fixed the issue            01/01/70 00:00      
                                    Are you sure?            01/01/70 00:00      
                                    Oh no it hasn't!            01/01/70 00:00      
                                       ok I agree , lets discuss            01/01/70 00:00      
                                          It depends on what your goals are            01/01/70 00:00      
                                          "DNA scope"            01/01/70 00:00      
                                          The Thing Is            01/01/70 00:00      
                                             Frequent examples            01/01/70 00:00      
   Scope time!            01/01/70 00:00      
      Would this sort of thing be at all helpful?            01/01/70 00:00      
         Quite possibly            01/01/70 00:00      
            I suspect they're all AC-coupled            01/01/70 00:00      
               AC Coupled -- No Good            01/01/70 00:00      
                  More than DC power decay...            01/01/70 00:00      
                  Isn't there some way of conditioning the input?            01/01/70 00:00      
                     No DC Bandwidth            01/01/70 00:00      
                        No argument there ... but ...            01/01/70 00:00      
                           Do you really think...            01/01/70 00:00      
                              Certainly, you're right ... however ...            01/01/70 00:00      
                                 Squeezing DC through AC Channel            01/01/70 00:00      
                                    and, for all practical purposes ...            01/01/70 00:00      
                                    How about this ... ???            01/01/70 00:00      
                                       Invert and add to subract the AC??            01/01/70 00:00      
                                          What about using other sampling hardware?            01/01/70 00:00      
                                             making a scope (sampling or not) is fairly simple            01/01/70 00:00      
                                                true enough ...            01/01/70 00:00      
                                                   USB modems really nifty            01/01/70 00:00      
                                                      Maybe the USB 'scopes are nifty ...            01/01/70 00:00      
                                                         USB 'scopes'            01/01/70 00:00      
                                                            for observing PSU behavior ...            01/01/70 00:00      
                                                               making a scope (sampling or not) is fairly simple            01/01/70 00:00      
                                                                  Well, I haven't tried it            01/01/70 00:00      
                                                                     another approach            01/01/70 00:00      
                                                                        Using hardware as built ... as much as possible            01/01/70 00:00      
                                                                           SiLabs C8051F34x            01/01/70 00:00      
                                                                              Which MCU is used doesn't matter ... yet            01/01/70 00:00      
                                                                                 But it does matter            01/01/70 00:00      
                                                                                    I agree, but ...            01/01/70 00:00      
                                                                        100MHz++ is nice but lots of areas are below 100kHz            01/01/70 00:00      
                                                                           While that works for some ...            01/01/70 00:00      
                                                                              Different tools good at different times            01/01/70 00:00      
                                                                                 no argument from me            01/01/70 00:00      
                                                                                    For one so insistent on answering the question as asked...            01/01/70 00:00      
                                                                                       This should have been a new thread, eh?            01/01/70 00:00      
                                                                                          Yes!            01/01/70 00:00      
                                                   too new, but            01/01/70 00:00      
                                                For crude display ...            01/01/70 00:00      

Back to Subject List