- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
i tried to use both of the phys on DE2-115, so i add two mac, two sgdma_rx, two sgdma_tx, two descriptor_mem, and one cpu in Qsys.
and i changed the top level file, in order to use both of the phys. then build a "simple socket server" project, but changed nothing. it turned out as follows: InterNiche Portable TCP/IP, v3.1 Copyright 1996-2008 by InterNiche Technologies. All rights reserved. Static IP Address is 192.168.1.2 prep_tse_mac 1 Your Ethernet MAC address is 00:07:ed:ff:cd:15 Static IP Address is 192.168.1.2 prepped 2 interfaces, initializing... [tse_mac_init] INFO : TSE MAC 0 found at address 0x08223400 INFO : PHY Marvell 88E1111 found at PHY address 0x10 of MAC Group[0] INFO : PHY[0.0] - Automatically mapped to tse_mac_device[0] INFO : PHY[0.0] - Restart Auto-Negotiation, checking PHY link... INFO : PHY[0.0] - Auto-Negotiation PASSED INFO : PHY[0.0] - Restart Auto-Negotiation, checking PHY link... INFO : PHY[0.0] - Auto-Negotiation PASSED INFO : PHY[0.0] - Checking link... INFO : PHY[0.0] - Link established INFO : PHY[0.0] - Speed = 100, Duplex = Full OK, x=0, CMD_CONFIG=0x01000000 neither PHY can ping through...T_T then i add this code into "int main (int argc, char* argv[], char* envp[]){}" in "iniche_init.c" file: alt_tse_system_mac psys_mac_0 = {TSE_SYSTEM_MAC(TSE_MAC_0)}; alt_tse_system_sgdma psys_sgdma_0 = {TSE_SYSTEM_SGDMA(SGDMA_TX_0, SGDMA_RX_0)}; alt_tse_system_desc_mem psys_mem_0 = {TSE_SYSTEM_DESC_MEM(DESCRIPTOR_MEMORY_0)}; alt_tse_system_shared_fifo psys_sfifo = {TSE_SYSTEM_NO_SHARED_FIFO()}; alt_tse_system_phy psys_phy_0 = {TSE_SYSTEM_PHY(1, NULL)}; alt_tse_system_mac psys_mac_1 = {TSE_SYSTEM_MAC(TSE_MAC_1)}; alt_tse_system_sgdma psys_sgdma_1 = {TSE_SYSTEM_SGDMA(SGDMA_TX_1, SGDMA_RX_1)}; alt_tse_system_desc_mem psys_mem_1 = {TSE_SYSTEM_DESC_MEM(DESCRIPTOR_MEMORY_1)}; alt_tse_system_phy psys_phy_1 = {TSE_SYSTEM_PHY(1, NULL)}; alt_tse_system_add_sys(&psys_mac_0, &psys_sgdma_0, &psys_mem_0, &psys_sfifo, &psys_phy_0 ); alt_tse_system_add_sys(&psys_mac_1, &psys_sgdma_1, &psys_mem_1, &psys_sfifo, &psys_phy_0 ); it reports as follows: Copyright 1996-2008 by InterNiche Technologies. All rights reserved. Static IP Address is 192.168.1.2 prep_tse_mac 1 Your Ethernet MAC address is 00:07:ed:ff:cd:15 Static IP Address is 192.168.1.2 prepped 2 interfaces, initializing... [tse_mac_init] INFO : TSE MAC 0 found at address 0x08223400 INFO : PHY Marvell 88E1111 found at PHY address 0x10 of MAC Group[0] INFO : PHY[0.0] - Automatically mapped to tse_mac_device[0] INFO : PHY[0.0] - Restart Auto-Negotiation, checking PHY link... INFO : PHY[0.0] - Auto-Negotiation PASSED INFO : PHY[0.0] - Restart Auto-Negotiation, checking PHY link... INFO : PHY[0.0] - Auto-Negotiation PASSED INFO : PHY[0.0] - Checking link... INFO : PHY[0.0] - Link established INFO : PHY[0.0] - Speed = 100, Duplex = Full OK, x=4, CMD_CONFIG=0x01000000 MAC post-initialization: CMD_CONFIG=0x05000203 [tse_sgdma_read_init] RX descriptor chain desc (1 depth) created mctest init called IP address of : 192.168.1.2 Created "Inet main" task (Prio: 2) Created "clock tick" task (Prio: 3) Simple Socket Server starting up [sss_task] Simple Socket Server listening on port 30 Created "simple socket server" task (Prio: 4) still neither one can ping !!!T_T then i add "TSE_SYSTEM_EXT_MEM_NO_SHARED_FIFO(TSE_MAC_1, 0, SGDMA_TX_1, SGDMA_RX_1, TSE_PHY_AUTO_ADDRESS, 0, DESCRIPTOR_MEMORY_1)" into "alt_tse_system_info tse_mac_device[MAXNETS] = {}" at "tse_my_system.c" file report below: Copyright 1996-2008 by InterNiche Technologies. All rights reserved. prep_tse_mac 0 Your Ethernet MAC address is 00:07:ed:ff:cd:15 Static IP Address is 192.168.1.2 prep_tse_mac 1 Your Ethernet MAC address is 00:07:ed:ff:cd:15 Static IP Address is 192.168.1.2 prepped 2 interfaces, initializing... [tse_mac_init] INFO : TSE MAC 0 found at address 0x08223400 INFO : TSE MAC 1 found at address 0x08223000 INFO : PHY Marvell 88E1111 found at PHY address 0x10 of MAC Group[0] INFO : PHY[0.0] - Automatically mapped to tse_mac_device[0] INFO : PHY[0.0] - Restart Auto-Negotiation, checking PHY link... INFO : PHY[0.0] - Auto-Negotiation PASSED INFO : PHY Marvell 88E1111 found at PHY address 0x11 of MAC Group[1] INFO : PHY[1.0] - Automatically mapped to tse_mac_device[1] INFO : PHY[1.0] - Restart Auto-Negotiation, checking PHY link... WARNING : PHY[1.0] - Auto-Negotiation FAILED MARVELL : Enabling auto crossover MARVELL : PHY reset INFO : PHY[1.0] - Restart Auto-Negotiation, checking PHY link... WARNING : PHY[1.0] - Auto-Negotiation FAILED INFO : PHY[1.0] - Checking link... INFO : PHY[1.0] - Link not yet established, restart auto-negotiation... INFO : PHY[1.0] - Restart Auto-Negotiation, checking PHY link... WARNING : PHY[1.0] - Auto-Negotiation FAILED WARNING : PHY[1.0] - Link could not established WARNING : PHY[1.0] - Auto-Negotiation not completed! Speed = 100, Duplex = Full OK, x=0, CMD_CONFIG=0x01000000 MAC post-initialization: CMD_CONFIG=0x05000203 [tse_sgdma_read_init] RX descriptor chain desc (1 depth) created [tse_mac_init] INFO : PHY[0.0] - Restart Auto-Negotiation, checking PHY link... INFO : PHY[0.0] - Auto-Negotiation PASSED INFO : PHY[0.0] - Checking link... INFO : PHY[0.0] - Link established INFO : PHY[0.0] - Speed = 100, Duplex = Full OK, x=12, CMD_CONFIG=0x01000000 MAC post-initialization: CMD_CONFIG=0x05000203 [tse_sgdma_read_init] RX descriptor chain desc (1 depth) created mctest init called IP address of et1 : 192.168.1.2 Created "Inet main" task (Prio: 2) Created "clock tick" task (Prio: 3) Simple Socket Server starting up [sss_task] Simple Socket Server listening on port 30 Created "simple socket server" task (Prio: 4) NOW the ETHERNET1 can ping, it works well, but the ETHERNET0 still couldnt not! could anyone help me! i'm a beginner of nios II. thanks a lot!Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
now i find that:
void alt_sys_init( void ) { ALTERA_AVALON_TIMER_INIT ( TIMER, timer); ALTERA_AVALON_CFI_FLASH_INIT ( CFI_FLASH, cfi_flash); ALTERA_AVALON_JTAG_UART_INIT ( JTAG_UART, jtag_uart); ALTERA_AVALON_LCD_16207_INIT ( LCD, lcd); ALTERA_AVALON_SGDMA_INIT ( SGDMA_RX_0, sgdma_rx_0); ALTERA_AVALON_SGDMA_INIT ( SGDMA_RX_1, sgdma_rx_1); ALTERA_AVALON_SGDMA_INIT ( SGDMA_TX_0, sgdma_tx_0); ALTERA_AVALON_SGDMA_INIT ( SGDMA_TX_1, sgdma_tx_1); ALTERA_AVALON_SYSID_QSYS_INIT ( SYSID, sysid); ALTERA_AVALON_UART_INIT ( RS232, rs232); TRIPLE_SPEED_ETHERNET_INIT ( TSE_MAC_0, tse_mac_0); <----- here TRIPLE_SPEED_ETHERNET_INIT ( TSE_MAC_1, tse_mac_1); <----- here } only the last one get used, if change the turn TSE_MAC_1 before TSE_MAC_0, i.e. TRIPLE_SPEED_ETHERNET_INIT ( TSE_MAC_1, tse_mac_1); TRIPLE_SPEED_ETHERNET_INIT ( TSE_MAC_0, tse_mac_0); the "TSE_MAC_0" is avaliable. please help me~ thx!- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I still working on it. Does it have some connection on the revision of Eclipse?
i use the Eclipse 13.0, anything will be helpful~ thx~ FangQJ
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page