lel
Fork of XBeeLib by
Embed:
(wiki syntax)
Show/hide line numbers
FH_IoDataSampleZB.h
00001 /** 00002 * Copyright (c) 2015 Digi International Inc., 00003 * All rights not expressly granted are reserved. 00004 * 00005 * This Source Code Form is subject to the terms of the Mozilla Public 00006 * License, v. 2.0. If a copy of the MPL was not distributed with this file, 00007 * You can obtain one at http://mozilla.org/MPL/2.0/. 00008 * 00009 * Digi International Inc. 11001 Bren Road East, Minnetonka, MN 55343 00010 * ======================================================================= 00011 */ 00012 00013 #if !defined(__FH_IO_DATA_SAMPLE_ZB_H_) 00014 #define __FH_IO_DATA_SAMPLE_ZB_H_ 00015 00016 #include "FrameHandler.h" 00017 #include "RemoteXBee/RemoteXBee.h" 00018 00019 namespace XBeeLib { 00020 00021 class IOSampleZB; 00022 00023 /** 00024 * @defgroup callback_types "Callback types declaration" 00025 * @{ 00026 */ 00027 /** IO Data Sample reception (ZigBee modules) callback type declaration 00028 * @param remote the remote module that sent the data 00029 * @param sample_data a referece to an @ref IOSampleZB that can be queried for the IoLines' values 00030 */ 00031 typedef void (*io_data_cb_zb_t)(const RemoteXBeeZB& remote, const IOSampleZB& sample_data); 00032 /** 00033 * @} 00034 */ 00035 00036 class FH_IoDataSampeZB : public FrameHandler 00037 { 00038 public: 00039 /** Class constructor */ 00040 FH_IoDataSampeZB(); 00041 00042 /** Class destructor */ 00043 virtual ~FH_IoDataSampeZB(); 00044 00045 virtual void process_frame_data(const ApiFrame *const frame); 00046 00047 void register_io_data_cb(io_data_cb_zb_t function); 00048 00049 void unregister_io_data_cb(); 00050 00051 private: 00052 /** Callback function, invoked if registered */ 00053 io_data_cb_zb_t io_data_cb; 00054 }; 00055 00056 } /* namespace XBeeLib */ 00057 00058 #endif /* __FH_IO_DATA_SAMPLE_ZB_H_ */
Generated on Sat Jul 16 2022 05:30:22 by 1.7.2