URL
https://opencores.org/ocsvn/i2c/i2c/trunk
[/] [i2c/] [trunk/] [rtl/] [verilog/] [i2c_master_byte_ctrl.v] - Diff between revs 38 and 47
Go to most recent revision |
Show entire file |
Details |
Blame |
View Log
Rev 38 |
Rev 47 |
Line 35... |
Line 35... |
//// ////
|
//// ////
|
/////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////
|
|
|
// CVS Log
|
// CVS Log
|
//
|
//
|
// $Id: i2c_master_byte_ctrl.v,v 1.6 2003-08-09 07:01:33 rherveille Exp $
|
// $Id: i2c_master_byte_ctrl.v,v 1.7 2004-02-18 11:40:46 rherveille Exp $
|
//
|
//
|
// $Date: 2003-08-09 07:01:33 $
|
// $Date: 2004-02-18 11:40:46 $
|
// $Revision: 1.6 $
|
// $Revision: 1.7 $
|
// $Author: rherveille $
|
// $Author: rherveille $
|
// $Locker: $
|
// $Locker: $
|
// $State: Exp $
|
// $State: Exp $
|
//
|
//
|
// Change History:
|
// Change History:
|
// $Log: not supported by cvs2svn $
|
// $Log: not supported by cvs2svn $
|
|
// Revision 1.6 2003/08/09 07:01:33 rherveille
|
|
// Fixed a bug in the Arbitration Lost generation caused by delay on the (external) sda line.
|
|
// Fixed a potential bug in the byte controller's host-acknowledge generation.
|
|
//
|
// Revision 1.5 2002/12/26 15:02:32 rherveille
|
// Revision 1.5 2002/12/26 15:02:32 rherveille
|
// Core is now a Multimaster I2C controller
|
// Core is now a Multimaster I2C controller
|
//
|
//
|
// Revision 1.4 2002/11/30 22:24:40 rherveille
|
// Revision 1.4 2002/11/30 22:24:40 rherveille
|
// Cleaned up code
|
// Cleaned up code
|
Line 218... |
Line 222... |
core_txd <= #1 sr[7];
|
core_txd <= #1 sr[7];
|
shift <= #1 1'b0;
|
shift <= #1 1'b0;
|
ld <= #1 1'b0;
|
ld <= #1 1'b0;
|
cmd_ack <= #1 1'b0;
|
cmd_ack <= #1 1'b0;
|
|
|
case (c_state) // synopsis full_case parallel_case
|
case (c_state) // synopsys full_case parallel_case
|
ST_IDLE:
|
ST_IDLE:
|
if (go)
|
if (go)
|
begin
|
begin
|
if (start)
|
if (start)
|
begin
|
begin
|
Line 241... |
Line 245... |
end
|
end
|
else // stop
|
else // stop
|
begin
|
begin
|
c_state <= #1 ST_STOP;
|
c_state <= #1 ST_STOP;
|
core_cmd <= #1 `I2C_CMD_STOP;
|
core_cmd <= #1 `I2C_CMD_STOP;
|
|
|
// generate command acknowledge signal
|
|
cmd_ack <= #1 1'b1;
|
|
end
|
end
|
|
|
ld <= #1 1'b1;
|
ld <= #1 1'b1;
|
end
|
end
|
|
|
Line 318... |
Line 319... |
end
|
end
|
|
|
// assign ack_out output to bit_controller_rxd (contains last received bit)
|
// assign ack_out output to bit_controller_rxd (contains last received bit)
|
ack_out <= #1 core_rxd;
|
ack_out <= #1 core_rxd;
|
|
|
// // generate command acknowledge signal
|
|
// cmd_ack <= #1 1'b1;
|
|
|
|
core_txd <= #1 1'b1;
|
core_txd <= #1 1'b1;
|
end
|
end
|
else
|
else
|
core_txd <= #1 ack_in;
|
core_txd <= #1 ack_in;
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.