Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
08/12/06 17:51
Read: times


 
#122127 - rather than all that processing
Responding to: ???'s previous message
This code fits in a $2.00 cpld and checks the crc on the serial bit stream,it uses the crc package generated here http://www.easics.com/webtools/crctool

<pre>
library IEEE;
use IEEE.std_logic_1164.all;
use work.crc5.all;

entity crccheck is
port (reset :in std_logic;
din :in std_logic; --serial data in
clk :in std_logic;
sr :out std_logic; -- goes high every 18 data bits
crc_err :out std_logic)
; -- after 18 data bits have been clocked in the internal shift register holds the MSB
--in bit position 18,sr goes high from the end of one 18 bit data set to the start of the
-- next
end crccheck;

architecture rtl of crccheck is

signal crcreg :std_logic_vector(17 downto 0);


begin
process(clk,reset)
variable bitcount :integer range 0 to 18;
begin
sr<='0';
if reset='0' then
bitcount:=0;
crcreg <=(others=>'0');
crc_err<='0';

elsif rising_edge(clk) then
bitcount:=bitcount+1;
crcreg<=din & crcreg(17 downto 1);
if bitcount=18 then
bitcount:=0;
sr<='1';
if nextCRC5_D13(crcreg(17 downto 5),crcreg(4 downto 0))/=crcreg(4 downto 0) then
crc_err<='1';
else crc_err<='0';
end if;
end if;
end if;

end process;


end rtl;



List of 36 messages in thread
TopicAuthorDate
5 bit CRC polynomial            01/01/70 00:00      
   there are several            01/01/70 00:00      
   what does "no success" mean?            01/01/70 00:00      
      He said            01/01/70 00:00      
         maybe we need a new 'forum' where            01/01/70 00:00      
      They said            01/01/70 00:00      
         This must be a very smart shaft encoder            01/01/70 00:00      
            competitor like Kuebler            01/01/70 00:00      
         This must be a very smart shaft encoder            01/01/70 00:00      
         Brute force it.            01/01/70 00:00      
            Yes this is what we were doing            01/01/70 00:00      
   can you find it in the pascal here? -- Kai            01/01/70 00:00      
      zyklische Redundanzprüfung            01/01/70 00:00      
      I searched all their site            01/01/70 00:00      
         did you search the pascal code examples            01/01/70 00:00      
            Where?            01/01/70 00:00      
               I did not look at it all, but there is much here            01/01/70 00:00      
                  I downloaded them all            01/01/70 00:00      
                     what about all the .pas            01/01/70 00:00      
      Found a document name            01/01/70 00:00      
         I feel your pain            01/01/70 00:00      
            This is how we get experienced            01/01/70 00:00      
               CRC time            01/01/70 00:00      
                  FPGA option            01/01/70 00:00      
                  SiLabs            01/01/70 00:00      
               have you seen this?            01/01/70 00:00      
                  Maybe it is X^5+X^4+X^3+X^2+X+1            01/01/70 00:00      
   rather than all that processing            01/01/70 00:00      
      The thing is            01/01/70 00:00      
         USB 5bit CRC            01/01/70 00:00      
         implementing other crc using crc package            01/01/70 00:00      
            impressive            01/01/70 00:00      
   rather than all that processing            01/01/70 00:00      
   Initial value?            01/01/70 00:00      
      and the final value            01/01/70 00:00      
   Friends            01/01/70 00:00      

Back to Subject List