Library for Programmable Resolution 1-Wire Digital ThermometerDS18B20

Dependents:   DS18B20_HGC

Committer:
kriedel
Date:
Thu Feb 03 12:10:20 2011 +0000
Revision:
0:21c0c97a5d7c

        

Who changed what in which revision?

UserRevisionLine numberNew contents of line
kriedel 0:21c0c97a5d7c 1 /*
kriedel 0:21c0c97a5d7c 2 * DS18S20. Maxim DS18S20 One-Wire Thermometer.
kriedel 0:21c0c97a5d7c 3 * Uses the OneWireCRC library.
kriedel 0:21c0c97a5d7c 4 *
kriedel 0:21c0c97a5d7c 5 * Copyright (C) <2010> Petras Saduikis <petras@petras.co.uk>
kriedel 0:21c0c97a5d7c 6 *
kriedel 0:21c0c97a5d7c 7 * This file is part of OneWireThermometer.
kriedel 0:21c0c97a5d7c 8 *
kriedel 0:21c0c97a5d7c 9 * OneWireThermometer is free software: you can redistribute it and/or modify
kriedel 0:21c0c97a5d7c 10 * it under the terms of the GNU General Public License as published by
kriedel 0:21c0c97a5d7c 11 * the Free Software Foundation, either version 3 of the License, or
kriedel 0:21c0c97a5d7c 12 * (at your option) any later version.
kriedel 0:21c0c97a5d7c 13 *
kriedel 0:21c0c97a5d7c 14 * OneWireThermometer is distributed in the hope that it will be useful,
kriedel 0:21c0c97a5d7c 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
kriedel 0:21c0c97a5d7c 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
kriedel 0:21c0c97a5d7c 17 * GNU General Public License for more details.
kriedel 0:21c0c97a5d7c 18 *
kriedel 0:21c0c97a5d7c 19 * You should have received a copy of the GNU General Public License
kriedel 0:21c0c97a5d7c 20 * along with OneWireThermometer. If not, see <http://www.gnu.org/licenses/>.
kriedel 0:21c0c97a5d7c 21 */
kriedel 0:21c0c97a5d7c 22
kriedel 0:21c0c97a5d7c 23 #ifndef SNATCH59_DS18S20_H
kriedel 0:21c0c97a5d7c 24 #define SNATCH59_DS18S20_H
kriedel 0:21c0c97a5d7c 25
kriedel 0:21c0c97a5d7c 26 #include "OneWireThermometer.h"
kriedel 0:21c0c97a5d7c 27
kriedel 0:21c0c97a5d7c 28 class DS18S20 : public OneWireThermometer
kriedel 0:21c0c97a5d7c 29 {
kriedel 0:21c0c97a5d7c 30 public:
kriedel 0:21c0c97a5d7c 31 DS18S20(bool crcOn, bool useAddr, bool parasitic, PinName pin);
kriedel 0:21c0c97a5d7c 32
kriedel 0:21c0c97a5d7c 33 virtual void setResolution(eResolution resln) { }; // do nothing
kriedel 0:21c0c97a5d7c 34
kriedel 0:21c0c97a5d7c 35 protected:
kriedel 0:21c0c97a5d7c 36 virtual float calculateTemperature(BYTE* data);
kriedel 0:21c0c97a5d7c 37 };
kriedel 0:21c0c97a5d7c 38
kriedel 0:21c0c97a5d7c 39 #endif