MCPcopy Create free account
hub / github.com/aethersdr/AetherSDR / applyPin

Method applyPin

src/core/SerialPortController.cpp:198–210  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

196}
197
198void SerialPortController::applyPin(PinFunction targetFn, bool active)
199{
200 if (!isOpen()) return;
201 HANDLE hPort = static_cast<HANDLE>(m_hWin);
202 if (m_dtrFn == targetFn) {
203 bool level = m_dtrActiveHigh ? active : !active;
204 ::EscapeCommFunction(hPort, level ? SETDTR : CLRDTR);
205 }
206 if (m_rtsFn == targetFn) {
207 bool level = m_rtsActiveHigh ? active : !active;
208 ::EscapeCommFunction(hPort, level ? SETRTS : CLRRTS);
209 }
210}
211
212void SerialPortController::updatePolling()
213{

Callers

nothing calls this directly

Calls 1

isOpenMethod · 0.45

Tested by

no test coverage detected