fsmcBank1: Memory.MappedMemory @ sysbus 0x60000000
    size: 0x10000000

sram: Memory.MappedMemory @ sysbus 0x20000000
    size: 0x00040000

flash: Memory.MappedMemory @ sysbus 0x08000000
    size: 0x200000

flash_controller: MTD.STM32F4_FlashController @ {
        sysbus 0x40023C00;
        sysbus new Bus.BusMultiRegistration { address: 0x1FFFC000; size: 0x100; region: "optionBytes" }
    }
    flash: flash

usart1: UART.STM32_UART @ sysbus <0x40011000, +0x100>
    -> nvic@37

usart2: UART.STM32_UART @ sysbus <0x40004400, +0x100>
    -> nvic@38

usart3: UART.STM32_UART @ sysbus <0x40004800, +0x100>
    -> nvic@39

uart4: UART.STM32_UART @ sysbus <0x40004C00, +0x100>
    -> nvic@52

uart5: UART.STM32_UART @ sysbus <0x40005000, +0x100>
    -> nvic@53

can1: CAN.STMCAN @ sysbus <0x40006400, +0x400>
    [0-3] -> nvic@[19-22]

can2: CAN.STMCAN @ sysbus <0x40006800, +0x400>
    [0-3] -> nvic@[63-66]
    master: can1

nvic: IRQControllers.NVIC @ sysbus 0xE000E000
    priorityMask: 0xF0
    systickFrequency: 72000000
    IRQ -> cpu@0

cpu: CPU.CortexM @ sysbus
    cpuType: "cortex-m4"
    nvic: nvic

pwr: Miscellaneous.STM32_PWR @ sysbus 0x40007000

crc: CRC.STM32_CRC @ sysbus 0x40023000
    series: STM32Series.F4

exti: IRQControllers.STM32F4_EXTI @ sysbus 0x40013C00
    numberOfOutputLines: 24
    [0-4] -> nvic@[6-10]
    [5-9] -> nvicInput23@[0-4]
    [10-15] -> nvicInput40@[0-5]
    [16, 17, 18, 22] -> nvic@[1, 41, 42, 3]

nvicInput23: Miscellaneous.CombinedInput @ none
    numberOfInputs: 5
    -> nvic@23

nvicInput40: Miscellaneous.CombinedInput @ none
    numberOfInputs: 6
    -> nvic@40

gpioPortA: GPIOPort.STM32_GPIOPort @ sysbus <0x40020000, +0x400>
    modeResetValue: 0xA8000000
    pullUpPullDownResetValue: 0x64000000
    numberOfAFs: 16
    [0-15] -> exti@[0-15]

gpioPortB: GPIOPort.STM32_GPIOPort @ sysbus <0x40020400, +0x400>
    modeResetValue: 0x00000280
    outputSpeedResetValue: 0x000000C0
    pullUpPullDownResetValue: 0x00000100
    numberOfAFs: 16
    [0-15] -> exti@[0-15]

gpioPortC: GPIOPort.STM32_GPIOPort @ sysbus <0x40020800, +0x400>
    numberOfAFs: 16
    [0-15] -> exti@[0-15]

gpioPortD: GPIOPort.STM32_GPIOPort @ sysbus <0x40020C00, +0x400>
    numberOfAFs: 16
    [0-15] -> exti@[0-15]

gpioPortE: GPIOPort.STM32_GPIOPort @ sysbus <0x40021000, +0x400>
    numberOfAFs: 16
    [0-15] -> exti@[0-15]

gpioPortF: GPIOPort.STM32_GPIOPort @ sysbus <0x40021400, +0x400>
    numberOfAFs: 16
    [0-15] -> exti@[0-15]

ethernet: Network.SynopsysEthernetMAC @ sysbus 0x40028000
    -> nvic@61

rom1: Memory.MappedMemory @ sysbus 0x1FFF0000
    size: 0xC000

rom2: Memory.MappedMemory @ sysbus 0x1FFFC400
    size: 0x3C00

spi1: SPI.STM32SPI @ sysbus 0x40013000

spi2: SPI.STM32SPI @ sysbus 0x40003800
    IRQ->nvic@35
    DMARecieve->dma1@3

spi3: SPI.STM32SPI @ sysbus 0x40003C00

i2c1: I2C.STM32F4_I2C @ sysbus 0x40005400
    EventInterrupt -> nvic@31
    ErrorInterrupt -> nvic@32

i2c2: I2C.STM32F4_I2C @ sysbus 0x40005800
    EventInterrupt -> nvic@33
    ErrorInterrupt -> nvic@34

i2c3: I2C.STM32F4_I2C @ sysbus 0x40005C00
    EventInterrupt -> nvic@72
    ErrorInterrupt -> nvic@73

dma1: DMA.STM32DMA @ sysbus 0x40026000
    [0-7] -> nvic@[11-17,47]

dma2: DMA.STM32DMA @ sysbus 0x40026400
    [0-7] -> nvic@[56-60,68-70]

rng: Miscellaneous.STM32F4_RNG @ sysbus 0x50060800
    -> nvic@80

iwdg: Timers.STM32_IndependentWatchdog @ sysbus 0x40003000
    frequency: 32000
    windowOption: false
    defaultPrescaler: 0x4

rtc: Timers.STM32F4_RTC @ sysbus 0x40002800
    AlarmIRQ -> nvic@41

rcc: Miscellaneous.STM32F4_RCC @ sysbus 0x40023800
    rtcPeripheral: rtc

timer1: Timers.STM32_Timer @ sysbus 0x40010000
    -> nvic@25
    frequency: 10000000
    initialLimit: 0xFFFF

timer2: Timers.STM32_Timer @ sysbus 0x40000000
    -> nvic@28
    frequency: 10000000
    initialLimit: 0xFFFFFFFF

timer3: Timers.STM32_Timer @ sysbus 0x40000400
    -> nvic@29
    frequency: 10000000
    initialLimit: 0xFFFF

timer4: Timers.STM32_Timer @ sysbus 0x40000800
    -> nvic@30
    frequency: 10000000
    initialLimit: 0xFFFF

timer5: Timers.STM32_Timer @ sysbus 0x40000C00
    -> nvic@50
    frequency: 10000000
    initialLimit: 0xFFFFFFFF

timer6: Timers.STM32_Timer @ sysbus 0x40001000
    -> nvic@54
    frequency: 10000000
    initialLimit: 0xFFFF

timer7: Timers.STM32_Timer @ sysbus 0x40001400
    -> nvic@55
    frequency: 10000000
    initialLimit: 0xFFFF

timer8: Timers.STM32_Timer @ sysbus 0x40010400
    -> nvic@44
    frequency: 10000000
    initialLimit: 0xFFFF

timer9: Timers.STM32_Timer @ sysbus 0x40014000
    -> nvic@24
    frequency: 10000000
    initialLimit: 0xFFFF

timer10: Timers.STM32_Timer @ sysbus 0x40014400
    -> nvic@25
    frequency: 10000000
    initialLimit: 0xFFFF

timer11: Timers.STM32_Timer @ sysbus 0x40014800
    -> nvic@26
    frequency: 10000000
    initialLimit: 0xFFFF

timer12: Timers.STM32_Timer @ sysbus 0x40001800
    -> nvic@43
    frequency: 10000000
    initialLimit: 0xFFFF

timer13: Timers.STM32_Timer @ sysbus 0x40001C00
    -> nvic@44
    frequency: 10000000
    initialLimit: 0xFFFF

timer14: Timers.STM32_Timer @ sysbus 0x40002000
    -> nvic@45
    frequency: 10000000
    initialLimit: 0xFFFF

bitbandPeripherals: Miscellaneous.BitBanding @ sysbus <0x42000000, +0x2000000>
    peripheralBase: 0x40000000

bitbandSram: Miscellaneous.BitBanding @ sysbus <0x22000000, +0x200000>
    peripheralBase: 0x20000000

sysbus:
    init:
        ApplySVD @https://dl.antmicro.com/projects/renode/svd/STM32F40x.svd.gz
        Tag <0x40021000, 0x40021003> "GPIOE_MODER" 0xFFFFFFFF
        Tag <0x40021004, 0x40021007> "GPIOE_OTYPER" 0x00000008
        // FLASH and USB tags are required for CubeMX-based projects to pass the initialization phase
        Tag <0x50000010, 0x5000003f> "USB:RESET" 0x80000000
