Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
19 years ago

why the 3wire-spi-master have 4pins?

// the_spi_master

.MISO_to_the_spi_master(),

.MOSI_from_the_spi_master(SPI_SDIO),

.SCLK_from_the_spi_master(SPI_SCLK),

.SS_n_from_the_spi_master(SPI_SS),

////----------------------------------------------------

intput MISO_from_the_spi_master;

output MOSI_to_the_spi_master;

output SCLK_to_the_spi_master;

output SS_n_to_the_spi_master;

do you have catch the case ?

how to resolve it ?! thx

1 Reply

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    how to connect the net of spi-master ?

    spoc u_sopc(

    // 1) global signals:

    .clk(clk_cpu),

    .reset_n(cpu_reset_n),

    // the_sdram_0

    .zs_addr_from_the_sdram_0(SDRAM2_A[11:0]),

    .zs_ba_from_the_sdram_0(SDRAM2_BA),

    .zs_cas_n_from_the_sdram_0(SDRAM2_CAS_n),

    .zs_cke_from_the_sdram_0(SDRAM2_CLKEN),

    .zs_cs_n_from_the_sdram_0(SDRAM2_CS_n),

    .zs_dq_to_and_from_the_sdram_0(SDRAM2_D),

    .zs_dqm_from_the_sdram_0({SDRAM2_UDQM,SDRAM2_LDQM}),

    .zs_ras_n_from_the_sdram_0(SDRAM2_RAS_n),

    .zs_we_n_from_the_sdram_0(SDRAM2_WE_n),

    // the_key

    .in_port_to_the_key(KEY),

    // the_led

    .out_port_from_the_led(LED[2:0]),

    // the_spi_master

    .MISO_to_the_spi_master(), //----------------????? how to connect?

    .MOSI_from_the_spi_master(SPI_SDIO),//-------?? how to connect?

    .SCLK_from_the_spi_master(SPI_SCLK),

    .SS_n_from_the_spi_master(SPI_SS),

    );