Skip to content

Generated nrf52.go is missing IRQ_SPIM1_SPIS1_TWIM1_TWIS1_SPI1_TWI1 #33

@deadprogram

Description

@deadprogram

While trying (and so far failing) to get the I2C interface working on the pca10040 I noticed that there is a missing interrupt value.

const (
	IRQ_POWER_CLOCK                       = 0  // Power control // Clock control
	IRQ_RADIO                             = 1  // 2.4 GHz Radio
	IRQ_UARTE0_UART0                      = 2  // UART with EasyDMA // Universal Asynchronous Receiver/Transmitter
	IRQ_SPIM0_SPIS0_TWIM0_TWIS0_SPI0_TWI0 = 3  // Serial Peripheral Interface Master with EasyDMA 0 // SPI Slave 0 // I2C compatible Two-Wire Master Interface with EasyDMA 0 // I2C compatible Two-Wire Slave Interface with EasyDMA 0 // Serial Peripheral Interface 0 // I2C compatible Two-Wire Interface 0
	IRQ_NFCT                              = 5  // NFC-A compatible radio
	IRQ_GPIOTE                            = 6  // GPIO Tasks and Events
...

Notice that IRQ 4 is missing. It is supposed to be
IRQ_SPIM1_SPIS1_TWIM1_TWIS1_SPI1_TWI1 = 4 according to the nrf52.svd file:

    <peripheral derivedFrom="TWIM0">
      <name>TWIM1</name>
      <description>I2C compatible Two-Wire Master Interface with EasyDMA 1</description>
      <baseAddress>0x40004000</baseAddress>
      <alternatePeripheral>SPIM1</alternatePeripheral>
      <interrupt>
        <name>SPIM1_SPIS1_TWIM1_TWIS1_SPI1_TWI1</name>
        <value>4</value>
      </interrupt>
    </peripheral>

This value is of course also missing from the generated nrf52.s file.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions