| /* |
| * Copyright (c) 2024 Henrik Brix Andersen <henrik@brixandersen.dk> |
| * |
| * SPDX-License-Identifier: Apache-2.0 |
| */ |
| |
| /dts-v1/; |
| |
| #include <st/f0/stm32f072Xb.dtsi> |
| #include <st/f0/stm32f072c(8-b)tx-pinctrl.dtsi> |
| |
| / { |
| model = "candleLight"; |
| compatible = "candlelight"; |
| |
| chosen { |
| zephyr,sram = &sram0; |
| zephyr,flash = &flash0; |
| zephyr,code-partition = &slot0_partition; |
| zephyr,canbus = &can1; |
| }; |
| |
| aliases { |
| led0 = &led_rx; |
| led1 = &led_tx; |
| }; |
| |
| leds { |
| compatible = "gpio-leds"; |
| led_rx: led_rx { |
| gpios = <&gpioa 0 GPIO_ACTIVE_LOW>; |
| label = "LED RX"; |
| }; |
| led_tx: led_tx { |
| gpios = <&gpioa 1 GPIO_ACTIVE_LOW>; |
| label = "LED TX"; |
| }; |
| }; |
| |
| transceiver0: can-phy0 { |
| compatible = "nxp,tja1051", "can-transceiver-gpio"; |
| enable-gpios = <&gpioc 13 GPIO_ACTIVE_LOW>; |
| max-bitrate = <1000000>; |
| #phy-cells = <0>; |
| }; |
| }; |
| |
| &clk_hsi { |
| status = "okay"; |
| clock-frequency = <DT_FREQ_M(8)>; |
| }; |
| |
| &pll { |
| prediv = <1>; |
| mul = <6>; |
| clocks = <&clk_hsi>; |
| status = "okay"; |
| }; |
| |
| &rcc { |
| clocks = <&pll>; |
| clock-frequency = <DT_FREQ_M(48)>; |
| ahb-prescaler = <1>; |
| apb1-prescaler = <1>; |
| }; |
| |
| zephyr_udc0: &usb { |
| pinctrl-0 = <&usb_dm_pa11 &usb_dp_pa12>; |
| pinctrl-names = "default"; |
| status = "okay"; |
| }; |
| |
| &can1 { |
| pinctrl-0 = <&can_rx_pb8 &can_tx_pb9>; |
| pinctrl-names = "default"; |
| phys = <&transceiver0>; |
| status = "okay"; |
| }; |
| |
| &flash0 { |
| partitions { |
| compatible = "fixed-partitions"; |
| #address-cells = <1>; |
| #size-cells = <1>; |
| |
| boot_partition: partition@0 { |
| label = "mcuboot"; |
| reg = <0x00000000 DT_SIZE_K(48)>; |
| read-only; |
| }; |
| slot0_partition: partition@c000 { |
| label = "image-0"; |
| reg = <0x0000c000 DT_SIZE_K(80)>; |
| }; |
| }; |
| }; |