Skip to content

Commit a0ff745

Browse files
fix windows CI missing module
1 parent a08d2a0 commit a0ff745

File tree

2 files changed

+41
-36
lines changed

2 files changed

+41
-36
lines changed

decoder_modules/pager_decoder/src/pocsag/pocsag.cpp

+39-36
Original file line numberDiff line numberDiff line change
@@ -85,21 +85,24 @@ namespace pocsag {
8585
void Decoder::flushMessage() {
8686
if (!msg.empty()) {
8787

88-
// Unpack bits
89-
std::string outStr = "";
90-
91-
for (int i = 0; (i+7) <= msg.size(); i += 7) {
92-
uint8_t b0 = msg[i];
93-
uint8_t b1 = msg[i+1];
94-
uint8_t b2 = msg[i+2];
95-
uint8_t b3 = msg[i+3];
96-
uint8_t b4 = msg[i+4];
97-
uint8_t b5 = msg[i+5];
98-
uint8_t b6 = msg[i+6];
99-
outStr += (char)((b6<<6) | (b5<<5) | (b4<<4) | (b3<<3) | (b2<<2) | (b1<<1) | b0);
100-
}
101-
102-
onMessage(addr, msgType, outStr);
88+
// // Unpack bits
89+
// std::string outStr = "";
90+
// for (int i = 0; (i+7) <= msg.size(); i += 7) {
91+
// uint8_t b0 = msg[i];
92+
// uint8_t b1 = msg[i+1];
93+
// uint8_t b2 = msg[i+2];
94+
// uint8_t b3 = msg[i+3];
95+
// uint8_t b4 = msg[i+4];
96+
// uint8_t b5 = msg[i+5];
97+
// uint8_t b6 = msg[i+6];
98+
// outStr += (char)((b6<<6) | (b5<<5) | (b4<<4) | (b3<<3) | (b2<<2) | (b1<<1) | b0);
99+
// }
100+
// onMessage(addr, msgType, outStr);
101+
102+
// Send out message
103+
onMessage(addr, msgType, msg);
104+
105+
// Reset state
103106
msg.clear();
104107
leftInLast = 0;
105108
}
@@ -165,30 +168,30 @@ namespace pocsag {
165168
}
166169
else if (msgType == MESSAGE_TYPE_ALPHANUMERIC) {
167170
// Alpha messages pack 7bit characters in the entire codeword stream
168-
// int lasti;
169-
// for (int i = -leftInLast; i <= POCSAG_DATA_BITS_PER_CW-7; i += 7) {
170-
// // Read 7 bits
171-
// char c = 0;
172-
// if (i < 0) {
173-
// c = (lastMsgData & ((1 << (-i)) - 1)) << (7+i);
174-
// }
175-
// c |= (data >> (13 - i)) & 0b1111111;
176-
177-
// // Save character
178-
// bitswapChar(c, c);
179-
// msg += c;
180-
181-
// // Update last successful unpack
182-
// lasti = i;
183-
// }
184-
185-
// Pack the bits backwards
186-
for (int i = 19; i >= 0; i--) {
187-
msg += (char)((data >> i) & 1);
171+
int lasti;
172+
for (int i = -leftInLast; i <= POCSAG_DATA_BITS_PER_CW-7; i += 7) {
173+
// Read 7 bits
174+
char c = 0;
175+
if (i < 0) {
176+
c = (lastMsgData & ((1 << (-i)) - 1)) << (7+i);
177+
}
178+
c |= (data >> (13 - i)) & 0b1111111;
179+
180+
// Save character
181+
bitswapChar(c, c);
182+
msg += c;
183+
184+
// Update last successful unpack
185+
lasti = i;
188186
}
189187

190188
// Save how much is still left to read
191-
//leftInLast = 20 - (lasti + 7);
189+
leftInLast = 20 - (lasti + 7);
190+
191+
// // Pack the bits backwards
192+
// for (int i = 19; i >= 0; i--) {
193+
// msg += (char)((data >> i) & 1);
194+
// }
192195
}
193196

194197
// Save last data

make_windows_package.ps1

+2
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,8 @@ cp $build_dir/misc_modules/discord_integration/Release/discord_integration.dll s
7979

8080
cp $build_dir/misc_modules/frequency_manager/Release/frequency_manager.dll sdrpp_windows_x64/modules/
8181

82+
cp $build_dir/misc_modules/iq_exporter/Release/iq_exporter.dll sdrpp_windows_x64/modules/
83+
8284
cp $build_dir/misc_modules/recorder/Release/recorder.dll sdrpp_windows_x64/modules/
8385

8486
cp $build_dir/misc_modules/rigctl_client/Release/rigctl_client.dll sdrpp_windows_x64/modules/

0 commit comments

Comments
 (0)