Diff
checker
Texte
Texte
Images
Documents
Excel
Dossiers
Legal
Enterprise
Application de bureau
Prix
Se connecter
Télécharger Diffchecker Desktop
Comparer le texte
Trouver la différence entre deux fichiers texte
Outils
Historique
Éditeur live
Cacher identiques
Sans retour à la ligne
Vue
Divisé
Unifié
Niveau de précision
Intelligent
Mot
Caractère
Coloration syntaxique
Choisir la syntaxe
Ignorer
Transformer le texte
Aller au premier écart
Modifier l'entrée
Diffchecker Desktop
La façon la plus sécurisée d'utiliser Diffchecker. Obtenez l'application Diffchecker Desktop : vos diffs ne quittent jamais votre ordinateur !
Obtenir Desktop
serial CRC verilog implementation
Créé
il y a 6 ans
Le diff n'expire jamais
Effacer
Exporter
Partager
Expliquer
2 suppressions
Lignes
Total
Supprimé
Caractères
Total
Supprimé
Pour continuer à utiliser cette fonctionnalité, passez à
Diff
checker
Pro
Voir les prix
28 lignes
Copier tout
1 ajout
Lignes
Total
Ajouté
Caractères
Total
Ajouté
Pour continuer à utiliser cette fonctionnalité, passez à
Diff
checker
Pro
Voir les prix
28 lignes
Copier tout
Copier
Copié
Copier
Copié
module crc_serial_
optimized
(clk, reset, data, crc);
module crc_serial_
long_division
(clk, reset, data, crc);
//=============================================================
//=============================================================
// Verilog function that implements serial USB CRC5
// Verilog function that implements serial USB CRC5
//=============================================================
//=============================================================
input clk, reset;
input clk, reset;
input data;
input data;
output reg [4:0] crc;
output reg [4:0] crc;
always @(posedge clk)
always @(posedge clk)
begin
begin
if(reset) crc <= 0;
if(reset) crc <= 0;
else begin
else begin
crc[0] <= crc[4] ^ data;
crc[0] <= crc[4] ^ data;
crc[1] <= crc[0];
crc[1] <= crc[0];
Copier
Copié
Copier
Copié
crc[2] <= crc[1] ^ crc[4]
^ data
;
crc[2] <= crc[1] ^ crc[4]
;
crc[3] <= crc[2];
crc[3] <= crc[2];
crc[4] <= crc[3];
crc[4] <= crc[3];
end
end
end
end
//============================================================
//============================================================
endmodule
endmodule
Différences enregistrées
Texte d'origine
Ouvrir un fichier
module crc_serial_optimized(clk, reset, data, crc); //============================================================= // Verilog function that implements serial USB CRC5 //============================================================= input clk, reset; input data; output reg [4:0] crc; always @(posedge clk) begin if(reset) crc <= 0; else begin crc[0] <= crc[4] ^ data; crc[1] <= crc[0]; crc[2] <= crc[1] ^ crc[4] ^ data; crc[3] <= crc[2]; crc[4] <= crc[3]; end end //============================================================ endmodule
Texte modifié
Ouvrir un fichier
module crc_serial_long_division(clk, reset, data, crc); //============================================================= // Verilog function that implements serial USB CRC5 //============================================================= input clk, reset; input data; output reg [4:0] crc; always @(posedge clk) begin if(reset) crc <= 0; else begin crc[0] <= crc[4] ^ data; crc[1] <= crc[0]; crc[2] <= crc[1] ^ crc[4]; crc[3] <= crc[2]; crc[4] <= crc[3]; end end //============================================================ endmodule
Trouver la différence