If you are driving the pin high, then you have a start bit and you'll get a framing error until you drive it low. If you clear the framing error, it will come right back unless you drive the pin low. If you need to drive the pin high for some reason, either turn off the rx interrupt, or turn off the uart rx. Remember that in 0-5v logic, rs-232 is not inverted, so a 1 is +5v. A start bit is +5v, stop bit is 0v. -Adam Laurence Evans wrote: >Hello All, > >I am having trouble with the UART of an 16F877. > >I am using a piece of software which simulates the PIC extremely >well and does simulate the UART (Proteous). Every time I initialise >the UART the Rx State changes to "Start Bit" straight away >despite the input being configured as an input and its being driven >high. > >The UART goes to start bit as soon as the instruction: > >bsf rcsta, cren > >is executed. Because the UART thinks it has recived a start bit, it >gets a framing error which is impossible to clear for some reason. >Mabe its because the UART status goes immediatly to start bit >again after recieveing anything ???? > >Thanks for any help in advance > >-- >http://www.piclist.com hint: PICList Posts must start with ONE topic: >[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads > > > > > -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body