URL
https://opencores.org/ocsvn/rc4-prbs/rc4-prbs/trunk
[/] [rc4-prbs/] [trunk/] [rc4_tb.v] - Diff between revs 9 and 14
Show entire file |
Details |
Blame |
View Log
Rev 9 |
Rev 14 |
Line 68... |
Line 68... |
|
|
|
|
/* Simulation */
|
/* Simulation */
|
integer q;
|
integer q;
|
initial begin
|
initial begin
|
password[0] = 8'h53; // 'S'
|
password[0] = 8'h01; // Testvectors http://tools.ietf.org/html/draft-josefsson-rc4-test-vectors-02#page-4
|
password[1] = 8'h65; // 'e'
|
password[1] = 8'h02; //
|
password[2] = 8'h63; // 'c'
|
password[2] = 8'h03; //
|
password[3] = 8'h72; // 'r'
|
password[3] = 8'h04; //
|
password[4] = 8'h65; // 'e'
|
password[4] = 8'h05; //
|
password[5] = 8'h74; // 't'
|
password[5] = 8'h06; //
|
// Test vector: "Secret" --> "04 d4 6b 05 3c a8 7b 59"
|
password[6] = 8'h07; //
|
|
|
|
// Key length: 56 bits.
|
|
// key: 0x01020304050607
|
|
// DEC 0 HEX 0: 29 3f 02 d4 7f 37 c9 b6 33 f2 af 52 85 fe b4 6b
|
|
|
$display ("Start...");
|
$display ("Start...");
|
clk = 0;
|
clk = 0;
|
rst = 1;
|
rst = 1;
|
clkcount =0;
|
clkcount =0;
|
password_input=password[clkcount];
|
password_input=password[clkcount];
|
#(1*tck)
|
#(1*tck)
|
rst = 0;
|
rst = 0;
|
#(program_cycles*tck+100)
|
#(program_cycles*tck+100000)
|
$display ("Finish.");
|
$display ("Finish.");
|
$finish;
|
$finish;
|
end
|
end
|
|
|
|
|
© copyright 1999-2025
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.