Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How would I go about implementing this algorithm?

A while back I was trying to bruteforce a remote control which sent a 12 bit binary 'key'.

The device I made worked, but was very slow as it was trying every combination at about 50 bits per second (4096 codes = 49152 bits = ~16 minutes)

I opened the receiver and found it was using a shift register to check the codes and no delay was required between attempts. This meant that the receiver was simply looking at the last 12 bits to be received to see if they were a match to the key.

This meant that if the stream 111111111111000000000000 was sent through, it had effectively tried all of these codes.

111111111111    111111111110    111111111100    111111111000
111111110000    111111100000    111111000000    111110000000
111100000000    111000000000    110000000000    100000000000
000000000000

In this case, I have used 24 bits to try 13 12 bit combinations (>90% compression).

Does anyone know of an algorithm that could reduce my 49152 bits sent by taking advantage of this?

like image 948
John Avatar asked Jan 30 '09 16:01

John


People also ask

How many steps we are having to implementation of algorithm?

Step 1: Obtain a description of the problem. Step 2: Analyze the problem. Step 3: Develop a high-level algorithm. Step 4: Refine the algorithm by adding more detail.


1 Answers

What you're talking about is a de Bruijn sequence. If you don't care about how it works, you just want the result, here it is.

like image 127
Pesto Avatar answered Nov 15 '22 20:11

Pesto