Here is the code I used.
(https://forum.seeedstudio.com/uploads/short-url/egpPEy4TjlhsrXK49dozhsZz3KL.zip 1)
Peripheral : XIAO BLE Sense + battery
Central : XIAO BLE on Expansion Board + battery
BSP : Seeed nRF52 Borads 1.1.1
Board select : Seeed nRF52 Borads / Seeed XIAO nRF52840 (or Sense)