Sign in

username:

password:



Not a member?

Search basicx



Search tips

Subscribe to basicx



basicx by Keywords

Accelerometer | ADC | ADXL | Adxl20 | AVR | BasicStamp | BX-35 | BX28 | BX35 | COM3 | Compiler | Downloader | EEPROM | Electromagnet | GetADC | GP2D1 | GPS | I2C | IDE | Keypad | LCD | LCD+ | MIDI | Motors | Multitasking | Netmedia | Networking | PCB | PID | PlaySound | PWM | Relays | RTC | Servo | ShiftOut | SitePlayer | SPI | Stack | Timer | USB

Ads

Discussion Groups

Discussion Groups | BasicX | Custom UART

Discussion forum for the BasicX family of microcontroller chips.

Custom UART - john_hightower - Sep 10 11:17:57 2007

I am trying to communicate with a monitoring system that apparently is
using the following communications protocol (per O-scope).
1 Start Bit
32 Data Bits
2 Stop Bits
~180,000 baud

I know that is fast but there appears to be considerable dead time.

Is it possible to use a BX-24 to create a custom UART that would
convert to RS232? I have tried modifying the InputCapture examples
with mixed results.

John Hightower



(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )


RE: Custom UART - Ken Strauss - Sep 10 11:29:21 2007

With 33 bit times in each "character" I would be concerned regarding
sampling each bit at the right time. Consider that a 3% error in the clock
rate would result in sampling the wrong bit so an accuracy of 1% or better
would seem almost essential for reliable operation. Does the device supply a
clock? I'm curious; what is the monitoring system?

> -----Original Message-----
> From: b...@yahoogroups.com [mailto:b...@yahoogroups.com]
> On Behalf Of john_hightower
> Sent: Monday, September 10, 2007 11:13 AM
> To: b...@yahoogroups.com
> Subject: [BasicX] Custom UART
>
> I am trying to communicate with a monitoring system that
> apparently is using the following communications protocol
> (per O-scope).
> 1 Start Bit
> 32 Data Bits
> 2 Stop Bits
> ~180,000 baud
>
> I know that is fast but there appears to be considerable dead time.
>
> Is it possible to use a BX-24 to create a custom UART that
> would convert to RS232? I have tried modifying the
> InputCapture examples with mixed results.
>
> John Hightower
>
> Yahoo! Groups Links


(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: Custom UART - Tom Becker - Sep 10 11:58:59 2007

> ... I have tried modifying the InputCapture examples with mixed results.

InputCapture should work for this, but finding the start bit might be
a challenge. Two adjacent low bits followed by a high in 35 NRZ bit
times might be common and, therefore, difficult to sync to. Does the
source generate a preamble to which you can synchronize before
meaningful data arrives?

The worst case array for InputCapture would represent alternating bits
- the start bit (high) followed by 16 pairs of lows and highs then one
two-bit-time stop (low), or 34 time elements to measure. The shortest
use of that array would be if all input bits are high except the
stops, or just two time periods.

I suspect that you can do this with InputCapture but it will require
post-capture interpretation to reconstruct and parse the serial data.


(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: Custom UART - john_hightower - Sep 10 12:03:22 2007

The system is monitoring fiber processing machines in a textile mill
and is approximately 12 years old. The protocol was purchased by a
Belgian company from the machine manufacturer and the Belgian company
wants $80,000 to "upgrade" the system. They would just be putting a
new PC on the bus to collect the data. The original machine
manufacturer can't legally give any support since they sold the
rights.

I have a system monitoring other machines in the mill and was asked
if I could communicate with these machines. Since the current system
is working and I can see the resulting data, I feel I could decipher
the messages if I could just capture the bytes.

The system appears to be two-wire RS485 that is connected to a
proprietary ISA card in a DOS PC. Although the ISA card may just
have their sticker on it.

--- In b...@yahoogroups.com, "Ken Strauss" wrote:
>
> With 33 bit times in each "character" I would be concerned regarding
> sampling each bit at the right time. Consider that a 3% error in
the clock
> rate would result in sampling the wrong bit so an accuracy of 1% or
better
> would seem almost essential for reliable operation. Does the device
supply a
> clock? I'm curious; what is the monitoring system?
>
> > -----Original Message-----
> > From: b...@yahoogroups.com [mailto:b...@yahoogroups.com]
> > On Behalf Of john_hightower
> > Sent: Monday, September 10, 2007 11:13 AM
> > To: b...@yahoogroups.com
> > Subject: [BasicX] Custom UART
> >
> > I am trying to communicate with a monitoring system that
> > apparently is using the following communications protocol
> > (per O-scope).
> > 1 Start Bit
> > 32 Data Bits
> > 2 Stop Bits
> > ~180,000 baud
> >
> > I know that is fast but there appears to be considerable dead
time.
> >
> > Is it possible to use a BX-24 to create a custom UART that
> > would convert to RS232? I have tried modifying the
> > InputCapture examples with mixed results.
> >
> > John Hightower
> >
> >
> >
> >
> >
> >
> >
> > Yahoo! Groups Links
> >
> >
> >
>


(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: Custom UART - patgadget - Sep 28 7:09:34 2007

--- In b...@yahoogroups.com, "john_hightower"
wrote:
>
> I am trying to communicate with a monitoring system that apparently is
> using the following communications protocol (per O-scope).
> 1 Start Bit
> 32 Data Bits
> 2 Stop Bits
> ~180,000 baud
>
> I know that is fast but there appears to be considerable dead time.
>
> Is it possible to use a BX-24 to create a custom UART that would
> convert to RS232? I have tried modifying the InputCapture examples
> with mixed results.
>
> John Hightower
>
I am a bit suprise to see a 32 data bit serial comm! are you sure that
they are not sending 3 or 4 bytes in a very rapid way instead???
That would be more standard? check after every 7 or 8 bits if you have
a stop bit and a start?
you could send me a picture of some of that data so i can study it?



(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )