Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: lib_Transmission_Serial_example 2022_TICE_Electrolyse lib_Transmission_TCP_example
lib_Transmission.h File Reference
Transmission class. More...
Go to the source code of this file.
Data Structures | |
| class | Transmission |
| Transmission class. More... | |
Detailed Description
Transmission class.
library for Transmission
Use to Transmission
Example:
#define MBED_PROJECT "Transmission" #include "lib_Transmission.h" #if MBED_MAJOR_VERSION > 5 UnbufferedSerial pc(USBTX, USBRX, 230400); #else Serial pc(USBTX, USBRX, 230400); #endif string transmission_processing(string); Transmission transmission(&pc, &transmission_processing); int main(void) { while(1) ThisThread::sleep_for(200ms); } string transmission_processing(string cmd) { ostringstream ssend; ssend << fixed; ssend.precision(2); if(cmd.empty()); else if(cmd == "*IDN?") ssend << MBED_PROJECT << ", Mbed OS " << MBED_VERSION << ", Version dated, " << __DATE__ << ", " << __TIME__; else if(cmd[cmd.size()-1] == '?') ssend << "incorrect requeste [" << cmd << "]"; return ssend.str(); }
- Date:
- Jun 2020
Definition in file lib_Transmission.h.
Generated on Wed Jul 13 2022 20:40:22 by
1.7.2