Skip to content

Commit e612fce

Browse files
committed
single type
1 parent db24611 commit e612fce

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

python_hackrf/pyhackrf_tools/pyhackrf_sweep.pyx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -171,21 +171,21 @@ def sweep_callback(object device, cnp.ndarray[cnp.int8_t, ndim=1] buffer, int bu
171171
'timestamp': time_str,
172172
'start_frequency': frequency,
173173
'stop_frequency': frequency + sample_rate // 4,
174-
'array': pwr[fft_1_start:fft_1_stop]
174+
'array': pwr[fft_1_start:fft_1_stop].astype(np.float32)
175175
})
176176
current_device_data['queue'].put({
177177
'timestamp': time_str,
178178
'start_frequency': frequency + sample_rate // 2,
179179
'stop_frequency': frequency + (sample_rate * 3) // 4,
180-
'array': pwr[fft_2_start:fft_2_stop]
180+
'array': pwr[fft_2_start:fft_2_stop].astype(np.float32)
181181
})
182182

183183
else:
184184
current_device_data['queue'].put({
185185
'timestamp': time_str,
186186
'start_frequency': frequency,
187187
'stop_frequency': frequency + sample_rate,
188-
'array': pwr
188+
'array': pwr.astype(np.float32)
189189
})
190190

191191
else:

0 commit comments

Comments
 (0)