4
\$\begingroup\$

I'm trying to reverse engineer a piece of electronics that seems to be using ~1Mhz differential phase shift keying to send a signal over a 2-wire line that's also used for low-voltage power.

So newbie question here, but how do I both encode/decode a PSK signal? In terms of do I need to build a custom circuit to do it (I've found diagrams of such)? Or are there cheap/small chips that will do this for me? I ultimately need a micro-controller both reading and sending the signal.

\$\endgroup\$
1
  • \$\begingroup\$ I bet there are IC's available. \$\endgroup\$
    – Al Kepp
    Feb 21, 2012 at 22:29

3 Answers 3

2
\$\begingroup\$

WHat you call BPSK could be also what was commonly called Manchester code. This was used in single ended and differential mode for long hauls and depending on idle data codes, there were several types. where phase would invert on a Mark (1), Space (0) or on a transition.

If so, you need a clock sync, phase sync (mark/space/invert) depending on modulation method used and then a byte sync UART and then a frame sync if synchronous payload.

Consider this solution. http://www.intersil.com/data/fn/fn2951.pdf I used to design discrete versions decades ago.

\$\endgroup\$
2
  • \$\begingroup\$ One could call Manchester coding "phase-shift keying", but would that be the normal usage of the term? I thought the term was more commonly used in cases where the carrier frequency was much higher than the bit rate; the carrier would be modulated with a signal that would switch between +1 and -1 for each "1" bit, and stay the same for each "0". Unlike amplitude modulation, where the percentage of "1"'s and "0"'s must stay within a certain range, phase-shift modulation could accommodate nearly any blend of "1"'s and "0"'s since the receiver... \$\endgroup\$
    – supercat
    Apr 9, 2012 at 14:48
  • \$\begingroup\$ ...can feed the signal through detectors that are both in-phase and out-of-phase of the precious signal and see which one registers more strongly. \$\endgroup\$
    – supercat
    Apr 9, 2012 at 14:50
1
\$\begingroup\$

One approach for decoding phase-shift keying is to delay the input signal by approximately a bit time, rounded to the nearest half phase, and either "xor", "and", or multiply that signal by the original, and then filter the result. This will yield a relatively nice output, even in the presence of noise which would disrupt counter-based approaches. The biggest limitation is that it requires that one have a good means of delaying the input signal.

\$\endgroup\$
0
\$\begingroup\$

A person could encode data as BPSK by sending the binary data to one input of an XOR gate, and connecting the other input of the XOR gate to a carrier oscillator (perhaps a 1 MHz square-wave oscillator). The output has lots of harmonics, but perhaps that's OK when transmitting over a differential pair of wires.

Decoding is a little more complex. I bet someone has already figured out how to do most of the decoding in software with a little 16 MHz microcontroller. (Excellent question; I hope someone else has a better answer.)

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.