1. This forum section is a read-only archive which contains old newsgroup posts. If you wish to post a query, please do so in one of our main forum sections (here). This way you will get a faster, better response from the members on Motherboard Point.

Z85C30 D/C (Data/Control) pin

Discussion in 'Embedded' started by T.Mai, Mar 27, 2014.

  1. T.Mai

    T.Mai Guest

    I'm writting a driver for the Z85C30 and did read the user manual but stil
    unclear of when to set high or low on the D/C pin. Any advice?
    The manual wrote "In the SCC, the data registers are directly addressed b
    selecting a High on the D/C pin." but I can not find register is the dat
    registers or control registers.
    Thanks,
    Trang Mai
     
    T.Mai, Mar 27, 2014
    #1
    1. Advertisements

  2. T.Mai

    David Empson Guest

    The D/C pin is written "D//C" in the datasheet I have here, i.e. "D if
    1, C if 0".

    Treat this as an address input, along with the "A//B" input (which
    selects channel A if 1, or B if 0).

    D//C needs to be a logic 1 to access the data registers, or a logic 0 to
    access the control registers.

    In effect, the SCC occupies four bytes of address space. Assuming D//C
    is mapped to address bit 0 and A//B to address bit 1, the four locations
    are (relative to the base address):

    0 B control
    1 B data
    2 A control
    3 A data

    When you access one of the control register locations, you are initially
    addressing WR0 (write) or RR0 (read). The other read/write control
    registers are addressed by first writing the register number to WR0,
    then reading or writing the same location to access the desired control
    register.

    The data register can also be accessed through the control register
    location by addressing WR8/RD8, but this is less efficient as it
    requires writing the register number (8) to WR0, then reading or writing
    the same location, i.e. twice as many accesses compared to using the
    separate address for the data register.
     
    David Empson, Mar 28, 2014
    #2
    1. Advertisements

  3. T.Mai

    T.Mai Guest

    Thanks David. This helps a lot.
    Trang Mai
     
    T.Mai, Mar 28, 2014
    #3
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.