How to set BP Clock Frequency

The default backplane clock frequency is 16 MHz for ATM33xx and 32 MHz for ATM34xx. Look for the definition of ‘system-clock’ dts entry in openair/dts/arm/atmosic/{ATM33.dtsi, ATM34.dtsi} files.

An application may choose to configure different clock frequency overriding the default values by passing build time flags as follows:

-DDTS_EXTRA_CPPFLAGS="-DINIT_BP_FREQ=<FREQ>"

For example, to build an application with modified BP clock frequency of 48 MHz, use this command below, with extra arguments:

west build -p always -b <BOARD> openair/samples/bluetooth/beacon --sysbuild -T samples.bluetooth.beacon.atm -- -DDTS_EXTRA_CPPFLAGS="-DINIT_BP_FREQ=48000000"

Alternately, application’s sysbuild sample.yaml may be modified as follows:

git diff sample.yaml
diff --git a/samples/bluetooth/beacon/sample.yaml b/samples/bluetooth/beacon/sample.yaml
index be401c45..902c12e2 100644
--- a/samples/bluetooth/beacon/sample.yaml
+++ b/samples/bluetooth/beacon/sample.yaml
@@ -8,6 +8,10 @@ tests:
   samples.bluetooth.beacon.atm:
     sysbuild: true
     harness: console
+    extra_args:
+      - SB_ATM_DTS_EXTRA_CPPFLAGS="-DINIT_BP_FREQ=48000000"
     harness_config:
       type: one_line
       regex:

Valid values are 32 MHz, 48 MHz and 64 MHz.