Shop OBEX P1 Docs P2 Docs Learn Events
Serial input — Parallax Forums

Serial input

philipad23philipad23 Posts: 44
edited 2006-03-02 22:26 in BASIC Stamp
Hi all,

I am using Holtek HT12E to build a remote control that is sending data to thae Basic Stamp 2. I can cleary see the signal on the oscillocope so I can culculate the frequency of transmition of pulses. What I dont know is how I can find the Baud that I must specify
at the SERIN command?

Does anyone know how to calculate the Baud Rate?


Thanks

Comments

  • PJAllenPJAllen Banned Posts: 5,065
    edited 2006-03-02 21:00
    The baudrate, or bits per second, is 1 / time of 1 bit (the reciprocal of the period of 1 bit width).· You have a scope, so you may be able to determine that, if you really crank it up.
    ·
    1200 bps is esentially 1200 Hz.
    The time for each bit = 1 / 1200
    ······················=· 833 usec
    If a bit is 833 usec, then the bit rate = 1 / 833usec
    ········································= 1200 Hz (bps)

    Once you know that, then you can look up the Baudrates in the tables provided in PBASIC Help.






    Post Edited (PJ Allen) : 3/2/2006 9:08:12 PM GMT
  • stamptrolstamptrol Posts: 1,731
    edited 2006-03-02 22:26
    If you Google Holtek HT12E, the data sheet is available on the first hit.

    It is actually an encoder chip which transmits data serially, but not in the usual RS-232 format. Seeing as how the matching HT12D is the decoder, it makes sense to use the pair.

    Cheers
Sign In or Register to comment.