Masterctrl/Sources/Chalet/LoraDevice.cpp
jfmartel d3d6e095d7 Réglé le problème de VOIP.ms Client.
Il a fallu que j'ajoute les DLL d'OPENSSL...
2020-07-12 12:09:38 -04:00

26 lines
580 B
C++

#include "LoraDevice.h"
CLoraDevice::CLoraDevice()
{
}
QByteArray CLoraDevice::GetLoraFrame(unsigned short DestAddress, unsigned char DestChannel, QByteArray Payload)
{
QByteArray OutputFrame;
OutputFrame.clear();
//E32 modules frame is [Address_MSB][Address_LSB][Channel][Payload]
char AddressByte = (char)((DestAddress >> 8) & 0x00FF);
OutputFrame.append(AddressByte);
AddressByte = (char)(DestAddress & 0x00FF);
OutputFrame.append(AddressByte);
OutputFrame.append(DestChannel);
OutputFrame.append(Payload);
return OutputFrame;
}