Danger-alarm/SOFTWARE-FreeRTOS/Source/DS18B20.hpp
aixiao 1e7e438091 这次提交基于FreeRTOS能正常运行。
还存在微笑问题,由于CO2传感器必须通过看门狗重启一次后才能正常,这个问题还没解决。(喂狗只在CO2函数内,保证能重启RP2040)
2024-08-11 22:03:46 +08:00

24 lines
476 B
C++

#ifndef DS18B20_H
#define DS18B20_H
/* Scheduler include files. */
#include "FreeRTOS.h"
#include "task.h"
#include "semphr.h"
#include "queue.h"
#include <cstdio>
#include <stdbool.h>
#include "pico/stdlib.h"
#include "hardware/gpio.h"
#include "hardware/watchdog.h"
#include "../../SOFTWARE/Lib/pico-onewire/api/one_wire.h"
#define DS18B20_PIN 15 // DS18B20 引脚
#define BUFER 256
extern QueueHandle_t xQueue;
extern void DS18B20(void *pvParameters);
#endif