This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM8148 and SYNCTIMER32K documentation

Hi,

I see the base address for SYNCTIMER32K is listed in "Table 2-7. L4 Slow Peripheral Memory Map" of sprs647e and mentioned in a few more places in the same document but cannot find its registers' description in the TRM. By manually peeking at registers I have verified that SYNCTIMER32K is indeed present on the part I tested. Where can I find documentation about SYNCTIMER32K registers? Thanks.

Kind Regards
--
Delio Brignoli
AudioScience Inc

  • Hi Delio,

    I found some description regarding SYNCTIMER32K:

    32-Khz synchronization timer

    This is a 32-bit ordinary counter, clocked by the falling edge of the 32 KHz clock. It is reset by the Always ON reset and after reset release starts counting forever. When the highest value is reached, it wraps back to zero and starts running again.

    Main features of the 32K timer controller:
    *slave interface (L4) supports:
    - 32-bit data bus width
    - 16/32 bit access supported
    - 16-bit address bus width
    - Burst not supported
    - WNP not supported
    *Only read operations are supported on the module’s registers; no write operation is supported (no error/no action on write).
    *Free running 32-bit upward counter
    *Start and keep counting after power-on reset, even when device is in OFF state
    *Automatic roll over to 0 highest value reached (0xFFFFFFFF) On the fly read (while counting)
    *Functional clock 32KHz sysclk18
    *L4 interface clock 110MHz sysclk6
    * no interrupt and DMA requests
    *Power and clock domain is WKUP

    Let me further check regarding registers description.

    BR
    Pavel
  • 2.1 Reading the counter

    The counter register is a 32-bit “atomic datum” and his 16-bit capture is done on the 16-bit LSB first to allow atomic LSB16 + MSB16 capture.

    3. REGISTERS DESCRIPTION

    Bit width : 32 bits. ( Can be 32bits or 2 x16 bits)

    Address of one register : Start address + Offset address.

    3.1 Register Mapping

    All the registers are:

    *32-bit register accessible in 16-bit mode.
    *little endian addressing.

    Register Name Size Access Address Offset
    LSB MSB
    32KSYNCNT_REV 32-bit Read 0x00 0x02
    Reserved 0x04 0x06
    Reserved 0x08 0x0A
    Reserved 0x0C 0x0E
    CR 32-bit Read 0x10 0x12

    3.2 Identification register (32KSYNCNT_REV)
    This read-only, 32-bit register (accessible in 16-bit mode) contains the hardware revision number of the module. A write to this register has no effect.

    [7:0] CID_REV Module HW revision number, value at reset: HW ID revision
    [31:8] Unused

    This CID_REV field indicates the revision number of the current timer module. This value is fixed by hardware.
    The Least significant 4-bit LSBs of CID_REV indicate a minor revision.
    The Most significant 4-bit of CID_REV MSBs indicate a major revision.
    The reset value is:
    0x11 =>: version 1.1

    A reset has no effect on the value returned.

    3.3 Counter Register (CR) (Read) little endian addressing
    The CR register is a 32-bit register. So the MPU performs a 32-bit access on the register while the DSP performs two consecutives 16-bit transactions. Also, note that since the Ocp is completely asynchronous with the clk_32KHz, some synchronization is done, so as to make sure that the CR value is not read while it is being incremented.
    In 16 bits mode the following sequence must be followed to read the CR register properly:

    a) Perform an OCP Read Transaction to Read the lower 16-bit of the CR register (offset = 10). When the CR is read and synchronized, the lower 16-bit ‘LSB’ are driven onto the “ocp_sdata” bus and the Upper 16-bit of the CR ‘MSB’ register are stored in a Temporary register.
    b) Perform an OCP Read Transaction to Read the upper 16-bit of the CR register (offset = 12). During this Read, the value of the upper 16-bit ‘MSB’ that has been temporary register is forwarded onto the “ocp_sdata” bus.

    So, to read the value of CR correctly, the first OCP read access has to be to the lower 16-bit (i.e. offset = 10), followed by OCP read access to the upper 16-bit (i.e., offset= 12).
  • Thank you very much Pavel. From my testing on DM8148 it appears that CR register is at offset 0x30 (instead of 0x10). Please, could you point me to the the source (an URL to a PDF or otherwise) of the information you quote in your answer? I ask because it's not in the TRM and I am wondering it it's an officially supported module that is guaranteed to be available on the SoC.
  • Hi Delio,

    We have only internal doc, nothing official.

    BR
    Pavel
  • Delio,

    I confirm I observe the same on my side (DM814x TI EVM), CR register seems to be at 0x30 offset.

    BR
    Pavel