<p></p>
<blockquote>
<p>Looking at the energy consumption aspect it seems to me we loose a light bit of efficiency in the same order of magnitude: the code in master should put the CPU into light sleep for the complete wait duration, while with <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="627069675" data-permission-text="Title is private" data-url="https://github.com/RIOT-OS/RIOT/issues/14165" data-hovercard-type="pull_request" data-hovercard-url="/RIOT-OS/RIOT/pull/14165/hovercard" href="https://github.com/RIOT-OS/RIOT/pull/14165">#14165</a> the idle thread is only active for the transfer duration minus the time taken for the task switching, right?</p>
</blockquote>
<p>Exactly, with an otherwise idle cpu, it should still light sleep for the transfer duration, with a small bit of extra overhead caused by the mutex in this PR.</p>
<p>I'm starting to think if switching between the <code>nrf52_sleep()</code>-option and the mutex based on a compile-time setting makes sense. Let the user decide if he/she really needs the amount of power saved by instantly sleeping.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/RIOT-OS/RIOT/pull/14165#issuecomment-635996782">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABE7WYG3TMVVOVZ2XRTCYE3RT67Y7ANCNFSM4NNZXO3A">unsubscribe</a>.<img src="https://github.com/notifications/beacon/ABE7WYF3NX3MJIOXMRE2AR3RT67Y7A5CNFSM4NNZXO3KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEXUIU3Q.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/RIOT-OS/RIOT/pull/14165#issuecomment-635996782",
"url": "https://github.com/RIOT-OS/RIOT/pull/14165#issuecomment-635996782",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>