[colibri imx6ull] Wake on BT


We are trying to wake the Colibri imx6ull from standby by sending it a bluetooth connection request. After setting the wakeup entry to enabled it works from command line. However, when using bluepy to manage connections with BLE devices, it does not work anymore. It is possible to suspend the device, however connection requests do not wake it up anymore. We would be happy if you could point us in a direction where to look for the error. Used kernel version is: 4.14.117-3.0.2+ge43e3a26e1b7

Thank you and Best regards

Hi @corinna and Welcome to the Toradex Community!

Could your provide the version of the hardware (including carrier board) software of your module?

After setting the wakeup entry to enabled it works from command line

What did you change?
How did you test it?
Could you provide the commands for your setup and any error log?

Thanks and best regards,

Hi @jaski.tx,

Thanks for your reply.
Hardware: We are using a Colibri iMX6ULL 512MB WB IT V1.1 on an Aster Carrier Board Rev 1.1.

Software: We build a yocto image.

  1. repo init -u Index of /toradex-bsp-platform.git -b LinuxImage3.0
  2. syncing the repo
  3. setting machine to colibri-imx6ull
  4. bitbake console-tdx-image
    Output of ‘uname -a’: Linux colibri-imx6ull 4.14.117-3.0.2+ge43e3a26e1b7

Working BT Wake up

  1. echo enabled > /sys/devices/soc0/soc/2100000.aips-bus/2194000.usdhc/power/wakeup
  2. hciconfig hci0 up
  3. hciconfig hci0 piscan
  4. Sending the Board to standby with
    rtcwake -m standby -d rtc0 -s 120
  5. On a separate machine: use bluetoothctl to connect to the imx6ull (in bluetoothctl: 'connect ')

The connect request successfully wakes up the board from sleep.

Not working BT wakeup

We want our Board to communicate with a Bluetooth Low Energy device. This communication is handled by bluepy. After receiving a packet, we send the board to standby from within a python script.
Again we try to wakeup the board with a connect request from bluetoothctl on a second machine. However in this case it does not wake up the board. We are unsure on where to look for the error.
Where is the wakeup be processed?

Thanks and best regards

In the meantime we found a solution for our problem.
Bluepy uses a helper binary based on bluez to maintain connections and also process events. It does not seem to work for wakeup events.
If the helper binary is terminated before going to standby, wakeup on bluetooth works again.

HI @corinna

Thanks very much for your Input.

So this means, you are able to wake up Colibri-iMX6ULL from standby using BT.
Could you describe how did you do this using bluypy python scripts?

Thanks and best regards,