mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-02-20 10:54:14 +01:00
A few more #define capitalizations.
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@2748 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
parent
73d134ad98
commit
d12868f1a3
@ -61,11 +61,11 @@ enum { RX_WAIT_PREAMBLE_MODE = 0,
|
||||
|
||||
// ************************************
|
||||
|
||||
#define RFM22_device_type 0x00 // R
|
||||
#define RFM22_dt_mask 0x1F
|
||||
#define RFM22_DEVICE_TYPE 0x00 // R
|
||||
#define RFM22_DT_MASK 0x1F
|
||||
|
||||
#define RFM22_device_version 0x01 // R
|
||||
#define RFM22_dv_mask 0x1F
|
||||
#define RFM22_DEVICE_VERSION 0x01 // R
|
||||
#define RFM22_DV_MASK 0x1F
|
||||
|
||||
#define RFM22_device_status 0x02 // R
|
||||
#define RFM22_ds_cps_mask 0x03 // Chip Power State mask
|
||||
|
@ -1842,14 +1842,14 @@ int rfm22_init(uint32_t min_frequency_hz, uint32_t max_frequency_hz, uint32_t fr
|
||||
// ****************
|
||||
// read the RF chip ID bytes
|
||||
|
||||
device_type = rfm22_read(RFM22_device_type) & RFM22_dt_mask; // read the device type
|
||||
device_type = rfm22_read(RFM22_DEVICE_TYPE) & RFM22_DT_MASK; // read the device type
|
||||
#if defined(RFM22_DEBUG)
|
||||
DEBUG_PRINTF("rf device type: %d\r\n", device_type);
|
||||
#endif
|
||||
if (device_type != 0x08)
|
||||
return -1; // incorrect RF module type
|
||||
|
||||
device_version = rfm22_read(RFM22_device_version) & RFM22_dv_mask; // read the device version
|
||||
device_version = rfm22_read(RFM22_DEVICE_VERSION) & RFM22_DV_MASK; // read the device version
|
||||
#if defined(RFM22_DEBUG)
|
||||
DEBUG_PRINTF("rf device version: %d\r\n", device_version);
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user