mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-16 04:45:24 +03:00
fix coding style
This commit is contained in:
parent
cb5fc4fd63
commit
95d3200c92
5 changed files with 22 additions and 24 deletions
|
@ -4467,8 +4467,8 @@ const clicmd_t cmdTable[] = {
|
|||
#endif
|
||||
#endif
|
||||
#ifdef USE_RX_BIND
|
||||
CLI_COMMAND_DEF("frsky_bind", "initiate binding for FrSky SPI RX", NULL, cliRxBind), /* legacy */
|
||||
CLI_COMMAND_DEF("rx_bind", "initiate binding for RX", NULL, cliRxBind),
|
||||
CLI_COMMAND_DEF("frsky_bind", "initiate binding for FrSky SPI RX", NULL, cliRxBind),
|
||||
CLI_COMMAND_DEF("sfhss_bind", "initiate binding for S-FHSS SPI RX", NULL, cliRxBind),
|
||||
#endif
|
||||
CLI_COMMAND_DEF("get", "get variable value", "[name]", cliGet),
|
||||
#ifdef USE_GPS
|
||||
|
|
|
@ -1116,8 +1116,8 @@ const clivalue_t valueTable[] = {
|
|||
{ "frsky_spi_use_external_adc", VAR_UINT8 | MASTER_VALUE | MODE_LOOKUP, .config.lookup = { TABLE_OFF_ON }, PG_RX_FRSKY_SPI_CONFIG, offsetof(rxFrSkySpiConfig_t, useExternalAdc) },
|
||||
#endif
|
||||
#ifdef USE_RX_SFHSS_SPI
|
||||
{ "sfhss_spi_tx_id", VAR_UINT8 | MASTER_VALUE | MODE_ARRAY, .config.array.length = 2, PG_RX_SFHSS_SPI_CONFIG, offsetof(rxSfhssSpiConfig_t, bindTxId) },
|
||||
{ "sfhss_spi_offset", VAR_INT8 | MASTER_VALUE, .config.minmax = { -127, 127 }, PG_RX_SFHSS_SPI_CONFIG, offsetof(rxSfhssSpiConfig_t, bindOffset) },
|
||||
{ "sfhss_tx_id", VAR_UINT8 | MASTER_VALUE | MODE_ARRAY, .config.array.length = 2, PG_RX_SFHSS_SPI_CONFIG, offsetof(rxSfhssSpiConfig_t, bindTxId) },
|
||||
{ "sfhss_offset", VAR_INT8 | MASTER_VALUE, .config.minmax = { -127, 127 }, PG_RX_SFHSS_SPI_CONFIG, offsetof(rxSfhssSpiConfig_t, bindOffset) },
|
||||
#endif
|
||||
{ "led_inversion", VAR_UINT8 | MASTER_VALUE, .config.minmax = { 0, ((1 << STATUS_LED_NUMBER) - 1) }, PG_STATUS_LED_CONFIG, offsetof(statusLedConfig_t, inversion) },
|
||||
#ifdef USE_DASHBOARD
|
||||
|
|
|
@ -40,4 +40,3 @@ void cc2500LedOn(void);
|
|||
void cc2500LedOff(void);
|
||||
void cc2500LedBlink(timeMs_t blinkms);
|
||||
bool cc2500SpiInit(void);
|
||||
|
||||
|
|
|
@ -38,4 +38,3 @@ PG_DECLARE(rxFrSkySpiConfig_t, rxFrSkySpiConfig);
|
|||
bool frSkySpiInit(const rxSpiConfig_t *rxSpiConfig, rxRuntimeConfig_t *rxRuntimeConfig);
|
||||
rx_spi_received_e frSkySpiDataReceived(uint8_t *packet);
|
||||
void frSkySpiSetRcData(uint16_t *rcData, const uint8_t *payload);
|
||||
|
||||
|
|
|
@ -130,12 +130,12 @@ static void initialise() {
|
|||
cc2500WriteReg(CC2500_2E_TEST0, 0x0B);
|
||||
cc2500WriteReg(CC2500_3E_PATABLE, 0xFF);
|
||||
|
||||
for(unsigned c = 0;c < 30; c++)
|
||||
{ //calibrate all channels
|
||||
for(unsigned c = 0;c < 30; c++){
|
||||
//calibrate all channels
|
||||
cc2500Strobe(CC2500_SIDLE);
|
||||
cc2500WriteReg(CC2500_0A_CHANNR, SFHSSCH2CHANNR(c));
|
||||
cc2500Strobe(CC2500_SCAL);
|
||||
delayMicroseconds(900); //
|
||||
delayMicroseconds(900);
|
||||
calData[c][0] = cc2500ReadReg(CC2500_23_FSCAL3);
|
||||
calData[c][1] = cc2500ReadReg(CC2500_24_FSCAL2);
|
||||
calData[c][2] = cc2500ReadReg(CC2500_25_FSCAL1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue