-1

I have a software(.exe file) that runs and captures data on RS485 link. I am unable to determine the baud rate at which it is capturing data. Have tried all basic baud rates from 1600-9600 and above that too but all I receive is garble data. Any way to track which baud rate it is processing the data in

I tried using oscilloscope as methods given on internet but it is coming close to 9600 and not working.

sawdust
  • 16,103
  • 3
  • 40
  • 50
  • 1
    Serial communications involve more than just the baud rate. Have you explored all the variations of character length, parity and number of stop bits? – Tangentially Perpendicular Aug 30 '23 at 15:39
  • All variations account to thousands of combinations. Any workaround to this – Kanishk Chaudhary Aug 30 '23 at 17:22
  • "*it is coming close to 9600*" -- Why can't you get an accurate measurement? Rather than measure a *1-bit* interval, measure an interval of *several* bits (i.e. `N` bits), and then divide that measurement by `N` (so that the inaccuracy is reduced by a factor of `1/N`). Note that a mismatch of baudrates up to 5% can typically be tolerated. "*I am unable to determine the baud rate at which it is capturing data*" -- You're looking at the wrong end of the serial link. You need to determine what the transmitting end (i.e. the sender) is doing. – sawdust Aug 30 '23 at 23:22
  • You neglect to mention any hardware that you are using. If the transmitting unit is sending 9-bit data frames (which is not unusual for RS485), then you might manage to read it using 8-bits with parity (depending on your HW). See https://stackoverflow.com/questions/57193363/stty-serial-port-settings-for-parity-not-persistent/57318783#57318783 – sawdust Aug 30 '23 at 23:34
  • Too bad you seem to be using Windows. If Linux (or POSIX OS), a `stty` command during (or maybe even after) execution of the capture program could report/reveal the configuration of that serial terminal. – sawdust Aug 31 '23 at 00:35
  • @Kanishk There aren't 'thousands of combinations'. Step back from this and take some time to understand what you're doing. The combinations are: 7-bits or 8-bits per character, Odd, even or no parity, one or two stop bits. That's twelve combinations, and some of those will work even if they're not quite right. – Tangentially Perpendicular Aug 31 '23 at 09:11
  • This may not be a programming question, so I have cast a close vote. _Super User_ may be a better bet, though information on how you are configuring the software would be necessary if you choose to repost it. – halfer Aug 31 '23 at 10:53

0 Answers0