Skip to content

manchester encoding / decoding #1104

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
evilpete opened this issue Sep 18, 2020 · 0 comments · May be fixed by #1135
Open

manchester encoding / decoding #1104

evilpete opened this issue Sep 18, 2020 · 0 comments · May be fixed by #1135
Labels

Comments

@evilpete
Copy link

manchester encoding (also known as phase encoding) is commonly used with telecommunications and data storage and would be a useful filter in CyberChef, particularly when working with SDR (software defined radio) sourced data

In short to encode, a input value of 1 becomes 01 and a input value of 0 becomes 10

encode(input) {

    foreach bit in input {
        if bit == 0 {
            output.append(1);
            output.append(0);
        } else {
            output.append(0);
            output.append(1);
        }

    return output;
}
@mt3571 mt3571 linked a pull request Nov 30, 2020 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant