Version FC
Dependencies: DmTftLibrary eeprom SX1280Lib filesystem mbed
Fork of MSNV2-Terminal_V1-5 by
Diff: Channel.cpp
- Revision:
- 13:5414193da1de
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Channel.cpp Mon Aug 27 16:32:50 2018 +0000 @@ -0,0 +1,31 @@ +#include "Channel.hpp" + +Channel::Channel( DEVICE_TYPE type, + MISNET_CODE misnet_code, + STATE state, + ACCESS_TYPE access_type, + REQUEST_MODE request_mode, + UP_MODE up_mode, + ACCESS_PIN access_pins[6], + ACTION action, + OUTPUT_MODE output_mode, + std::string comment) { + this->device_type = type; + this->misnet_code = misnet_code; + this->state = state; + this->access_type = access_type; + this->request_mode = request_mode; + this->up_mode = up_mode; + for (int i = 0; i < 6; i++) { + this->access_pins[i] = access_pins[i]; + } + this->action = action; + this->output_mode = output_mode; + this->comment = comment; +} + +std::ostream& operator<<(std::ostream& out, const Channel& channel) { + out << "Device type : " << channel.device_type << ", MISNet code : " << (int) channel.misnet_code; + out << ", state : " << channel.state << ", comment : " << channel.comment; + return out; +}