temperature (2) 썸네일형 리스트형 [nRF52 xBee EVM] Arduino 테스트 - 내장 온도 측정하기 nRF5 SDK에 온도 센서관련 예제가 있다. /examples/periphera/temperature ([nRF52 xBee EVM] 기본 동작 테스트 - temperature 테스트 (IAR) 참고) 하지만 아두이노 코드에 뒤져봐도 nrf_temp.h 파일이 없다. 예제 폴더에서 복사해서... #include "nrf_temp.h" void setup() { Serial.begin(115200); } int32_t get_temperature(void) { int32_t temp; NRF_TEMP->TASKS_START = 1; /** Start the temperature measurement. */ /* Busy wait while temperature measurement is not finis.. [STM32G0-SSM EVM] Arduino 내부 온도센서 테스트 STM32G0에는 칩내부에 온도 센서가 있다. 온도값에 따라 리니어 하게 전압으로 출력 되지만 절대온도로 사용하려면 보정이 필요 하다고 한다. 대략 온도 측정하기는 좋을것 같다. STM32G0 내부 온도 출력 Aruino 소스코드 #include "stm32yyxx_ll_adc.h" /* Values available in datasheet */ #define CALX_TEMP 25 #if defined(STM32F1xx) #define V25 1430 #define AVG_SLOPE 4300 #define VREFINT 1200 #elif defined(STM32F2xx) || defined(STM32F4xx) #define V25 760 #define AVG_SLOPE 2500 #define VREF.. 이전 1 다음