The Hardware Side of Cryptography

22 May 2008

The Design of ROT13 encoder

Filed under: encoding, logic gate — Tags: , , , , — edipermadi @ 1:32 pm

I have previously made an implementaion of ROT13 cipher using PIC16F84 microcontroller. Yesterday, i came up with a new idea of another ROT13 implementation. I was thinking about designing ROT13 encoder using discrete combinational logic. Today, I sat hours and hours to draw and debug those circuits until it meets the specification.

First think first, to design an encoder we first look at the “expected” behaviour of encoder that called as truth table then derive the boolean equation of each bits with respected to every inputs. The truth table of ROT13 encoder is shown below.

If we denote inputs as [x1x2x3x4x5x6x7x8] and outputs as [y1y2y3y4y5y6y7y8], ke knew that:



Since we knew so, y1,y2 and y3 were not expecting special treatment from us. The rest of output bits will explained further step by step.

First, If we map y4 into Karnaugh Map, with respect to y4y5y6y7y8, we will get this picture below.

Next, we proceed to deriving boolean function of y4. The y4 output bit then defined as.

Second, the same procedure as before. If we map y5 with respect to y4y5y6y7y8 The respecive Karnaugh Map diagram would be:

The boolean function of y5 then defined as:

Third, the mapping of y6 with respects to y4y5y6y7y8 will results this picture below.

The boolean equation of y6 then defined as.

Fourth, the mapping of y7 with respects to y4y5y6y7y8 will results this picture below.

The boolean equation of y7 then defined as.

Fifth, the mapping of y8 with respects to y4y5y6y7y8 will results this picture below.

The boolean equation of y8 then defined as.

Finally, after we have all boolean equations of each output bits, we now could draw the schematic circuit of ROT13 encoder. The schematic is shown below, please click the picture to see the full sized one.

I have tested the circuit and it works the same as specification. You may download benchmarking results on links below. You may freely use, redistribute and modify this design including the pictures under the term of GNU Free Documentation License.

BENCHMARK

A, B, C, D, E, F, G, H, I, J, K, L, K, N, O, P, Q, R, S, T, U, V, W, X, Y, Z.

RELATED STUFF

Reference:
ROT13 Cipher

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: