Decoding Manchester code from a Torque sensor of VW car.

Hello,

I am desperately seeking some advice of using Arduino Mega to decode Manchester encoded signal from a Torque sensor. I also need to visualise the code 1's and 0's using a LCD. Please help :frowning: :frowning: :frowning: :frowning: :frowning:

Post the data sheet for the torque sensor.

original bit = manchester bit XOR clock

see - Manchester code - Wikipedia -

The fun part is that

manchester bit = original bit XOR clock

Be aware here is at least also a differential manchester encoding, and there might be some other variations.

robtillaart:
The fun part is that

manchester bit = original bit XOR .

A Manchester coded signal is probably transmitted without a clock signal on another wire: otherwise why use Manchester coding? It is also unlikely to be a ternary signal as shown in the Wikipedia article, at least after detection electronics.

When I have used a Manchester coded signal I always had a logical "1" start bit followed by the data bits. Referring to the 'Manchester as per GE Thomas" waveform in the diagram from the Wikipedia article, my software looked for the first positive-to-negative transition then sampled the signal 0.75 clock periods later to give the first data bit. This was repeated to determine the following bits. This method only works if you know the approximate clock frequency/period.

If there is no start bit then the following from Wikipedia applies "the receiver can identify if it is misaligned by half a bit period, as there will no longer always be a transition during each bit period". However I feel that is problematic if the data is 11111111 or 00000000.

Incidentally, there have been various threads in this forum concerning whether data can be transmitted over a few metres of cable. I believe a Manchester-coded signal can be transmitted over a few kilometres with only a simple voltage comparator as receiving detector, depending on data rate of course.

Hello,

Thanks for replying to my post everyone :slight_smile: really do appreciate it. I am currently using PIC 16F1509 to decode the manchester encoded signal. I am using "Configurable logic cells - CLC" according to Microchip's AN1470 application note.

Now, the main problem is to amplify the output signal of the torque sensor from mV to up to 5mV, the the chip will not decode as far as I understand.

The datasheet of the sensor is not available as it is a VW stuff :stuck_out_tongue: as you know German engineering is always efficient. But this is definitely Manchester encoded signal as I have research through.

Please help me out with your expertise and a circuit design to amplify the signal. I have got a LM358 OP-AMP. Can I possibly use that ? May be a bridge amplifier or differential amplifier ?

Please let me know. Your help will be heartily appreciated. Once I have decoded the signal, I will share it here about the final prototype that I am after.

With Regards

Fahim