Forums

pic16f627 with different baudrates

Started by rose fay October 8, 2007
Hi!

I am a newbee of using PIC USART and internal clock.

I am developing a program that will send a data to an instrument to enable
it to send an output to the PC via RS232.  The problem is, my hardware has
8 channels with different instruments which run with different baudrates.
The data sent is similar on all channels.  How could i send the correct
data to the corresponding channel which i am not sure what baudrate to
use? Is it possible for me to constantly change different baudrates after
i send a data to each channel since different instruments have different
data request. What i am going to do? Do you have any idea. Too, i am using
the inaccurate internal clock since i am running out of ports.

Your response is highly appreciated. Thank you so much. 


rose fay wrote:
> Hi! > > I am a newbee of using PIC USART and internal clock. > > I am developing a program that will send a data to an instrument to enable > it to send an output to the PC via RS232. The problem is, my hardware has > 8 channels with different instruments which run with different baudrates. > The data sent is similar on all channels. How could i send the correct > data to the corresponding channel which i am not sure what baudrate to > use? Is it possible for me to constantly change different baudrates after > i send a data to each channel since different instruments have different > data request. What i am going to do? Do you have any idea. Too, i am using > the inaccurate internal clock since i am running out of ports. > > Your response is highly appreciated. Thank you so much. > >
Yes you can change the baud rate if you know the correct rate for each instrument. You will most likely needed a crystal the PIC internal oscillator is not accurate enough. You will need a bigger chip or some type of I/O expander
On Mon, 08 Oct 2007 04:38:27 -0500, "rose fay" <rf_orcullo@yahoo.com>
wrote:

>Hi! > >I am a newbee of using PIC USART and internal clock. > >I am developing a program that will send a data to an instrument to enable >it to send an output to the PC via RS232. The problem is, my hardware has >8 channels with different instruments which run with different baudrates. >The data sent is similar on all channels. How could i send the correct >data to the corresponding channel which i am not sure what baudrate to >use? Is it possible for me to constantly change different baudrates after >i send a data to each channel since different instruments have different >data request. What i am going to do? Do you have any idea. Too, i am using >the inaccurate internal clock since i am running out of ports.
So that's 9 UART channels total, 1 PC plus 8 instruments, and your PIC has 1 UART and nothing to multiplex that 1 UART. All that plus an inaccurate baud clock to boot. One thing you could do that might pay off would be rethink your hardware architecture. -- Dan Henry