SiriusHardware
Posts: 502
Joined: Thu Aug 02, 2012 9:09 pm
Location: UK

Manchester Encode/Decode [obsolete]

Wed Jan 02, 2013 10:37 am

I'm aware that the Pi has various serial hardware facilties already present - such as a serial UART and SPI and I2C buses - is there anything on the Pi which can generate / decode Manchester encoded data (Frequently used by remote control transmitters and short range on/off radio remote control devices) in a hardware-assisted fashion?

I know how to encode/decode Manchester data by bit-banging, having done it a few times on 8051/PIC microcontrollers, but I'm not sure that it will be possible to achieve sufficiently tight timing if trying to do it on the Pi via GIO/Python. (I expect that the Linux OS multitasking overhead will destabilise the timing too much).

Of course I could use a microcontroller to do the actual encoding/decoding and let the Pi transmit to / receive from it via the serial UART or I2C, but if it's feasible to do it using the Pi only, then I'd be interested in doing it that way.

I have two specific areas of interest in this respect -

One is using the Rpi to generate infra-red remote control signals to extend the range of items which the Pi can usefully be used to control. I'm aware, incidentally, that there are other remote data formats, not just Manchester encoding.

Secondly, to allow the Pi itself to respond to either IR or RF-bourne signal sources which might be handheld infra-red remotes, remote mounting wireless thermometers or RF remotes originally intended to control radio controlled mains sockets - that kind of thing.

vitaminxp
Posts: 1
Joined: Mon Dec 17, 2018 4:00 pm

Re: Manchester Encode/Decode

Mon Dec 17, 2018 4:04 pm

I am also very interested in decoding/encoding RF signals using Manchester encoding/decoding on my Pi. If anyone had or knows a Python or C++ library that can be used on Rasberry Pi to do that, please let us know. Thanks.

Thomasx
Posts: 1
Joined: Fri Oct 18, 2019 10:42 am

Re: Manchester Encode/Decode

Fri Oct 18, 2019 10:44 am

I am also interested in this 😊

User avatar
joan
Posts: 14469
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Manchester Encode/Decode

Fri Oct 18, 2019 11:36 am

This is an old thread.

pigpio has the hooks needed to encode/decode Manchester code for signals with bit transitions in the >microsecond range. What do you need to do?

SiriusHardware
Posts: 502
Joined: Thu Aug 02, 2012 9:09 pm
Location: UK

Re: Manchester Encode/Decode

Sat Oct 19, 2019 12:06 pm

I can never understand why the -age- of the thread matters if it was never answered and the question remains exactly the same. Especially if New information or a new feature with some bearing on the question comes to light some time after the original post.

(The OP).

User avatar
DougieLawson
Posts: 36515
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Manchester Encode/Decode

Sat Oct 19, 2019 1:16 pm

SiriusHardware wrote:
Sat Oct 19, 2019 12:06 pm
I can never understand why the -age- of the thread matters if it was never answered and the question remains exactly the same. Especially if New information or a new feature with some bearing on the question comes to light some time after the original post.

(The OP).
Because any threads for Wheezy, Jessie and Stretch are past both their sell-by & use-by dates. So much has changed between Wheezy and Buster, that most junk for Wheezy won't work or may leave a system unbootable.

Old versions of Raspbian won't boot on hardware that popped into existence after the version of Raspbian (the classic example being nothing but Buster boots on an RPi4 (because of the radical hardware changes with the RPi4)).

Old versions of Raspbian won't have current security fixes and that puts your whole home network at risk.

In my ideal world EVERY thread not updated for six months would be auto-locked (and left as a historical reference).
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

Heater
Posts: 13859
Joined: Tue Jul 17, 2012 3:02 pm

Re: Manchester Encode/Decode

Sat Oct 19, 2019 3:41 pm

I does not matter how old the thread is. Especially if the the question is still a valid question. Especially if it's new information in the light of changes that may effect the way to tackle to original question.

Random people searching the net with a similar problem may be very happy to find their question was asked years ago and answered last week.
Memory in C++ is a leaky abstraction .

SiriusHardware
Posts: 502
Joined: Thu Aug 02, 2012 9:09 pm
Location: UK

Re: Manchester Encode/Decode

Sat Oct 19, 2019 5:32 pm

While I see DougieLawson's point, that an old post may contain a solution / suggestion which will not work under a newer regime, in this case no progress had been made at all until Joan's suggestion, so there was nothing in this thread which had gone out of date.

Even so, I would rather work through one ages old mega-thread where the problem and suggested solutions have evolved along with the Pi and its OS, than search 100 similar closed threads each of which may or may not contain a small fragment of the answer.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 12398
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Manchester Encode/Decode

Sat Oct 19, 2019 6:26 pm

If a thread is so old, that any answers in it have become obsolete, these answers (that won't in all likelyhood work anymore on newer systems) will only confuse and irritate new readers, and should therefore be locked, and marked obsolete.
It is only because this forum lacks a mechanism to do this automatically once a thread is beyond a "sell by date" we don't do this per default.

If you have an identical question, but for a NEW OS, then you should create a NEW post, and at the same time flag a moderator so that he can lock the OLD thread, and mark it obsolete, so Google won't send people astray.
re-opening such obsolete posts will only cause perpetually extension of this ageing problem, and therefore we have a descriptive name for it "necromancing", meaning raising an dead old thread from the grave.

It's much better to start anew, with if necessary a link to the older posts, with a note they might be obsolete.

also, it might be true that the threads contains still valid data, but moderators cannot, don't always have the time, to judge that, so as a default moderators should judge it as obsolete, especially if the thread is many years old.

Return to “Interfacing (DSI, CSI, I2C, etc.)”