1-Wire® library for mbed. Complete 1-Wire library that supports our silicon masters along with a bit-bang master on the MAX32600MBED platform with one common interface for mbed. Slave support has also been included and more slaves will be added as time permits.

Dependents:   MAXREFDES131_Qt_Demo MAX32630FTHR_iButton_uSD_Logger MAX32630FTHR_DS18B20_uSD_Logger MAXREFDES130_131_Demo ... more

Superseded by MaximInterface.

Committer:
IanBenzMaxim
Date:
Thu May 12 14:38:16 2016 -0500
Revision:
73:2cecc1372acc
Parent:
OneWireSlave.hpp@49:36954b62f503
Child:
74:23be10c32fa3
Added namespaces. Renamed files and directories for consistency. Use <stdint.h> instead of <cstdint> since it is not supported by C++98.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
IanBenzMaxim 25:bdb1c5a53b58 1 #ifndef _ONEWIRESLAVE_HPP
IanBenzMaxim 25:bdb1c5a53b58 2 #define _ONEWIRESLAVE_HPP
IanBenzMaxim 25:bdb1c5a53b58 3
IanBenzMaxim 73:2cecc1372acc 4 #include "RomId.h"
IanBenzMaxim 25:bdb1c5a53b58 5
IanBenzMaxim 73:2cecc1372acc 6 namespace OneWire
IanBenzMaxim 25:bdb1c5a53b58 7 {
IanBenzMaxim 73:2cecc1372acc 8 /// Base class for all 1-Wire Slaves.
IanBenzMaxim 73:2cecc1372acc 9 class OneWireSlave
IanBenzMaxim 25:bdb1c5a53b58 10 {
IanBenzMaxim 73:2cecc1372acc 11 public:
IanBenzMaxim 73:2cecc1372acc 12 enum CmdResult
IanBenzMaxim 73:2cecc1372acc 13 {
IanBenzMaxim 73:2cecc1372acc 14 Success,
IanBenzMaxim 73:2cecc1372acc 15 CommunicationError,
IanBenzMaxim 73:2cecc1372acc 16 TimeoutError,
IanBenzMaxim 73:2cecc1372acc 17 OperationFailure
IanBenzMaxim 73:2cecc1372acc 18 };
IanBenzMaxim 73:2cecc1372acc 19
IanBenzMaxim 73:2cecc1372acc 20 /// 1-Wire ROM ID for this slave device.
IanBenzMaxim 73:2cecc1372acc 21 RomId romId;
IanBenzMaxim 25:bdb1c5a53b58 22 };
IanBenzMaxim 73:2cecc1372acc 23 }
IanBenzMaxim 25:bdb1c5a53b58 24
IanBenzMaxim 49:36954b62f503 25 #endif