SPI HAL implemented and more (#207)
- Cleanup unused code and move ISR/IRQ checks to `Kernel.h` - Improve clang-format - Fix for LVGL lock transfer: ensure lock isn't activate when changing the lock - Implement SPI HAL - Remove `initHardware` HAL configuration entry - Fix `I2cScanner`: don't scan when port isn't started
This commit is contained in:
committed by
GitHub
parent
88b3bfbe3e
commit
c1f55429b6
@@ -1,7 +1,7 @@
|
||||
#include "Tactility/StreamBuffer.h"
|
||||
|
||||
#include "Tactility/Check.h"
|
||||
#include "Tactility/CoreDefines.h"
|
||||
#include "Tactility/kernel/Kernel.h"
|
||||
|
||||
namespace tt {
|
||||
|
||||
@@ -23,7 +23,7 @@ size_t StreamBuffer::send(
|
||||
size_t length,
|
||||
uint32_t timeout
|
||||
) const {
|
||||
if (TT_IS_IRQ_MODE()) {
|
||||
if (kernel::isIsr()) {
|
||||
BaseType_t yield;
|
||||
size_t result = xStreamBufferSendFromISR(handle.get(), data, length, &yield);
|
||||
portYIELD_FROM_ISR(yield);
|
||||
@@ -38,7 +38,7 @@ size_t StreamBuffer::receive(
|
||||
size_t length,
|
||||
uint32_t timeout
|
||||
) const {
|
||||
if (TT_IS_IRQ_MODE()) {
|
||||
if (kernel::isIsr()) {
|
||||
BaseType_t yield;
|
||||
size_t result = xStreamBufferReceiveFromISR(handle.get(), data, length, &yield);
|
||||
portYIELD_FROM_ISR(yield);
|
||||
|
||||
Reference in New Issue
Block a user