# Viterbi decoder on a bit stream where the preamble is also coded

I hope this is not off-topic for this site.

In my problem, Viterbi decoder is used for decoding convolutional-coded (rate = 1/2, constraint length = 7) messages.

A message is 250 bits where the first 8 bits are 1/3 of a preamble. There are several types of messages. A message is received as 500 bits because of the coding, which means, the preamble is also coded.

Since there is no place marker other than the coded preamble, I am in trouble with finding the first bit of the 500 bits to start decoding.

I would really appreciate any suggestions and comments.

-
I assume the preamble is known a priori (or it wouldn't be of much use). Is the encoder state at the beginning of a message known? If so, then the coded version of the preamble should be known ahead of time. Thus, you could correlate your received signal against the coded preamble to estimate packet synchronization. – Jason R Dec 31 '12 at 14:51
@Jason R Yes, the preamble is known. I am not sure if I get what you say; I only know that these 250 bit messages (of various types where the first 8 bits are preambles) are encoded with the encoder I've mentioned. I should process the signal in space (such as GPS signal). If I can obtain a decoded version, I can find the preamble by correlating. I have no idea what the coded preamble is since there are many types of messages using the same preamble. As far as I know, encoding the same 8 bits give different 16 bits because of the various following 242 bits. – groove Jan 2 '13 at 0:15
Is the convolutional code recursive or feedforward? If it isn't recursive, then the bits that follow the preamble may not have any effect on the encoder output for the preamble bits themselves (although it could depend upon the code rate). If you have knowledge of the exact structure of the encoder, that can help you. – Jason R Jan 2 '13 at 0:57
It is not recursive. The polynomials are octal 133 and 171. – groove Jan 2 '13 at 7:23

## 1 Answer

Is the 500-bit encoded message part of a continuous stream being decoded by the Viterbi decoder, or is it a 500-bit packet that is decoded individually? If part of a stream, then decoding continuously and searching for the preamble indicates the beginning of the message. If packetized, then the decoder memory needs to be managed so that the first decoded bit location is known. This will be dependent on the decoder implementation.

-
I get a continuous bit stream from the receiver which gets signal in space (like GPS signal). Messages are encoded as packets, but the receiver receives a stream. Each message is encoded individually. If I can obtain the decoded signal, I will find the preamble by correlation. I can simplfy this question as two questions: While decoding, is it possible to get the results for the first 8 bits without waiting for the whole message? Can Viterbi decode message2 or message3 from a stream like ("half of message1" + message2 + message3 +...) by starting from the first bit of the "half of message1"? – groove Jan 2 '13 at 0:42