OpenCores
URL https://opencores.org/ocsvn/xge_mac/xge_mac/trunk

Subversion Repositories xge_mac

[/] [xge_mac/] [trunk/] [tbench/] [systemc/] [sc_packet.h] - Diff between revs 7 and 29

Show entire file | Details | Blame | View Log

Rev 7 Rev 29
Line 46... Line 46...
#define PKT_FLAG_ERR_CRC      0x0004
#define PKT_FLAG_ERR_CRC      0x0004
#define PKT_FLAG_ERR_FRG      0x0008
#define PKT_FLAG_ERR_FRG      0x0008
#define PKT_FLAG_ERR_CODING   0x0010
#define PKT_FLAG_ERR_CODING   0x0010
#define PKT_FLAG_LOCAL_FAULT  0x0020
#define PKT_FLAG_LOCAL_FAULT  0x0020
#define PKT_FLAG_REMOTE_FAULT 0x0040
#define PKT_FLAG_REMOTE_FAULT 0x0040
 
#define PKT_FLAG_ERR_LENGHT   0x0080
 
 
 
 
struct packet_t {
struct packet_t {
 
 
    int length;
    int length;
 
 
    // Packet fields
    // Packet fields
 
 
    sc_uint<48> dest_addr;
    sc_uint<48> dest_addr;
    sc_uint<48> src_addr;
    sc_uint<48> src_addr;
    sc_uint<8> payload [12000];
    sc_uint<8> payload [18000];
    sc_uint<32> crc;
    sc_uint<32> crc;
 
 
    sc_uint<32> crc_rx;
    sc_uint<32> crc_rx;
    sc_uint<32> err_flags;
    sc_uint<32> err_flags;
    sc_uint<32> err_info;
    sc_uint<32> err_info;
 
 
    sc_uint<32> ifg;
    sc_uint<32> ifg;
    sc_uint<32> start_lane;
    sc_uint<32> start_lane;
 
 
    sc_uint<8> data [10000];
    sc_uint<8> data [20000];
};
};
 
 
ostream& operator<<(ostream& os, const packet_t& p);
ostream& operator<<(ostream& os, const packet_t& p);
 
 
void pack(packet_t* p);
void pack(packet_t* p);

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.