Merge pull request #657 from jpconstantineau/fix-hardware-pwm-atomic

Fix to atomic compiler errors
This commit is contained in:
Ha Thach authored and GitHub committed 2021-06-07 17:28:05 +07:00
commit eb25586b1a
1 file changed
+2 -1
+2 -1
View File
@@ -39,6 +39,7 @@
#include "common_inc.h"
#include "nrf.h"
#include <atomic>
#include <cstdint>
#ifdef NRF52840_XXAA
#define HWPWM_MODULE_NUM 4
@@ -51,7 +52,7 @@ class HardwarePWM
private:
enum { MAX_CHANNELS = 4 }; // Max channel per group
NRF_PWM_Type * const _pwm;
std::atomic_uint32_t _owner_token;
std::atomic<std::uint32_t> _owner_token;
uint16_t _seq0[MAX_CHANNELS];