mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-05-12 03:34:58 -04:00
Change IPC to exchange data, not pointers.
This commit is contained in:
parent
f99016d78f
commit
4126f1ab1f
7 changed files with 76 additions and 126 deletions
|
@ -147,8 +147,7 @@ void ReceiverModel::disable() {
|
|||
.decimation_factor = 1,
|
||||
}
|
||||
};
|
||||
shared_memory.baseband_queue.push(&message);
|
||||
while( !message.is_free() );
|
||||
shared_memory.baseband_queue.push(message);
|
||||
|
||||
radio::disable();
|
||||
}
|
||||
|
@ -187,10 +186,7 @@ void ReceiverModel::update_baseband_configuration() {
|
|||
radio::set_baseband_decimation_by(baseband_oversampling());
|
||||
|
||||
BasebandConfigurationMessage message { baseband_configuration };
|
||||
shared_memory.baseband_queue.push(&message);
|
||||
|
||||
// Block until message is consumed, since we allocated it on the stack.
|
||||
while( !message.is_free() );
|
||||
shared_memory.baseband_queue.push(message);
|
||||
|
||||
if( baseband_configuration.mode == 3 ) {
|
||||
update_fsk_configuration();
|
||||
|
@ -222,8 +218,5 @@ static constexpr FSKConfiguration fsk_configuration_tpms_a = {
|
|||
|
||||
void ReceiverModel::update_fsk_configuration() {
|
||||
FSKConfigurationMessage message { fsk_configuration_ais };
|
||||
shared_memory.baseband_queue.push(&message);
|
||||
|
||||
// Block until message is consumed, since we allocated it on the stack.
|
||||
while( !message.is_free() );
|
||||
shared_memory.baseband_queue.push(message);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue