mirror of
https://github.com/g4klx/DMRGateway
synced 2025-12-22 14:16:08 +08:00
Pass DMR interrupt packets through.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2015,2016,2017,2018 by Jonathan Naylor G4KLX
|
||||
* Copyright (C) 2015-2019 by Jonathan Naylor G4KLX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@@ -276,6 +276,22 @@ bool CDMRNetwork::writeHomePosition(const unsigned char* data, unsigned int leng
|
||||
return write(buffer, length);
|
||||
}
|
||||
|
||||
bool CDMRNetwork::writeInterrupt(const unsigned char* data, unsigned int length)
|
||||
{
|
||||
if (m_status != RUNNING)
|
||||
return false;
|
||||
|
||||
unsigned char buffer[50U];
|
||||
|
||||
::memcpy(buffer + 0U, "RPTINTR", 7U);
|
||||
|
||||
::memcpy(buffer + 7U, m_id, 4U);
|
||||
|
||||
::memcpy(buffer + 11U, data + 11U, length - 11U);
|
||||
|
||||
return write(buffer, length);
|
||||
}
|
||||
|
||||
bool CDMRNetwork::isConnected() const
|
||||
{
|
||||
return m_status == RUNNING;
|
||||
|
||||
Reference in New Issue
Block a user