uhf_module_settings.h 1.3 KB

1234567891011121314151617181920212223242526272829
  1. #pragma once
  2. #include <stdint.h>
  3. // UHF module regions
  4. typedef enum {
  5. WR_CHINA_900 = 1, // Freq_CH-920.125M
  6. WR_US, // Freq_CH-902.25M
  7. WR_EU, // Freq_CH-865.1M
  8. WR_CHINA_800, // Freq_CH-840.125M
  9. WR_KOREA = 6 // Freq_CH-917.1M
  10. } WorkingRegion;
  11. // UHF module baudrates
  12. static const uint32_t BAUD_RATES[] = {9600, 19200, 115200};
  13. static const uint8_t BAUD_RATES_COUNT = sizeof(BAUD_RATES) / sizeof(BAUD_RATES[0]);
  14. // RF Power Setting
  15. static const uint8_t POWER_DBM[] = {12, 14, 17, 20}; // To be determined ...
  16. static const uint8_t POWER_DBM_COUNT = sizeof(POWER_DBM) / sizeof(POWER_DBM[0]);
  17. // UHF WorkingArea
  18. static const char* WORKING_REGIONS_STR[] = {"CN1", "US", "EU", "CN2", "KR"};
  19. static const uint8_t __working_region_str =
  20. sizeof(WORKING_REGIONS_STR) / sizeof(WORKING_REGIONS_STR[0]);
  21. static const WorkingRegion WORKING_REGIONS[] = {WR_CHINA_900, WR_US, WR_EU, WR_CHINA_800, WR_KOREA};
  22. static const uint8_t WORKING_REGIONS_COUNT = sizeof(WORKING_REGIONS) / sizeof(WORKING_REGIONS[0]);
  23. // UHF WorkingChannel
  24. // static const string WORKING_CHANNELS_STR[] = {"China 900MHz", "US", "EU", "China 800MHz", "Korea"};
  25. // static const WorkingChannel WORKING_CHANNELS[] = {WC_CHINA_900, WC_US, WC_EU, WC_CHINA_800, WC_KOREA};
  26. // static const uint8_t WORKING_CHANNELS_COUNT = sizeof(WORKING_CHANNELS) / sizeof(WORKING_CHANNELS[0]);