Skip to content

Commit 5da5ef4

Browse files
author
Donatien Garnier
committed
Cordio H4: Added some comments explaining the use of RawSerial as opposed to using Serial
1 parent 0cb86de commit 5da5ef4

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

features/FEATURE_BLE/targets/TARGET_CORDIO/driver/H4TransportDriver.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,10 @@ class H4TransportDriver : public CordioHCITransportDriver {
6969
private:
7070
void on_controller_irq();
7171

72+
// Use RawSerial as opposed to Serial as we don't require the locking primitives
73+
// provided by the Serial class (access to the UART should be exclusive to this driver)
74+
// Furthermore, we access the peripheral in interrupt context which would clash
75+
// with Serial's locking facilities
7276
RawSerial uart;
7377
PinName cts;
7478
PinName rts;

0 commit comments

Comments
 (0)