keever50 commented on issue #15856: URL: https://github.com/apache/nuttx/issues/15856#issuecomment-2676775490
True! In case of struct: **— IOCTL using struct —** ``` Common: WLIOC_COM_PARAMS takes { uint32_t freq_hz; int8_t power_dbm; uint16_t preamble_bytes; } WLIOC_COM_MOD takes Modulation technique (enum like lora, gfsk, ook, etc) ``` **— LoRa structs —** ``` WLIOC_LORA_MODULATION takes { uint8_t spreading_factor; uint16_t bw_khz; } WLIOC_LORA_PACKET takes { enum coding_rate; bool include_crc; bool include_length; // Also called implicit header or fixed length header. It actually just includes a length byte. } WLIOC_LORA_SET_SYNCWORD takes { uint8_t *sync_bytes; size_t sync_length; } ``` **— Read Header —** ``` { uint8_t *payload; size_t payload_length; int32_t RSSI_fixed_float_dBm; // 2 points precision 0.00dBm int32_t SNR_fixed_float_ratio; // 2 points precision 0.00dB bool error; } ``` I hope these data types make sense. Technically it would also be possible to add headers for writing, which can set frequency, power, preambles and length. That would allow for quicker response. What do you think about that, @raiden00pl ? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org