1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-26 01:35:41 +03:00

Removed unused parameters

This commit is contained in:
Martin Budden 2016-10-02 08:37:40 +01:00
parent 5fec66b639
commit e530c72a18
6 changed files with 10 additions and 13 deletions

View file

@ -614,7 +614,7 @@ void blackboxDeviceClose(void)
* of time to shut down asynchronously, we're the only ones that know when to call it. * of time to shut down asynchronously, we're the only ones that know when to call it.
*/ */
if (blackboxPortSharing == PORTSHARING_SHARED) { if (blackboxPortSharing == PORTSHARING_SHARED) {
mspSerialAllocatePorts(&masterConfig.serialConfig); mspSerialAllocatePorts();
} }
break; break;
default: default:

View file

@ -718,7 +718,7 @@ void processRx(uint32_t currentTime)
} else { } else {
// the telemetry state must be checked immediately so that shared serial ports are released. // the telemetry state must be checked immediately so that shared serial ports are released.
telemetryCheckState(); telemetryCheckState();
mspSerialAllocatePorts(&masterConfig.serialConfig); mspSerialAllocatePorts();
} }
} }
#endif #endif

View file

@ -50,10 +50,8 @@ static void resetMspPort(mspPort_t *mspPortToReset, serialPort_t *serialPort)
mspPortToReset->port = serialPort; mspPortToReset->port = serialPort;
} }
void mspSerialAllocatePorts(serialConfig_t *serialConfig) void mspSerialAllocatePorts(void)
{ {
UNUSED(serialConfig);
serialPort_t *serialPort; serialPort_t *serialPort;
uint8_t portIndex = 0; uint8_t portIndex = 0;
@ -89,11 +87,11 @@ void mspSerialReleasePortIfAllocated(serialPort_t *serialPort)
} }
} }
void mspSerialInit(serialConfig_t *serialConfig) void mspSerialInit(void)
{ {
mspInit(); mspInit();
memset(mspPorts, 0x00, sizeof(mspPorts)); memset(mspPorts, 0, sizeof(mspPorts));
mspSerialAllocatePorts(serialConfig); mspSerialAllocatePorts();
} }
static void setCurrentPort(mspPort_t *port) static void setCurrentPort(mspPort_t *port)

View file

@ -54,8 +54,7 @@ extern struct bufWriter_s *writer;
extern bool isRebootScheduled; extern bool isRebootScheduled;
struct serialConfig_s; void mspSerialInit(void);
void mspSerialInit(struct serialConfig_s *serialConfig);
void mspSerialProcess(void); void mspSerialProcess(void);
void mspSerialAllocatePorts(struct serialConfig_s *serialConfig); void mspSerialAllocatePorts(void);
void mspSerialReleasePortIfAllocated(struct serialPort_s *serialPort); void mspSerialReleasePortIfAllocated(struct serialPort_s *serialPort);

View file

@ -505,7 +505,7 @@ void init(void)
imuInit(); imuInit();
mspSerialInit(&masterConfig.serialConfig); mspSerialInit();
#ifdef USE_CLI #ifdef USE_CLI
cliInit(&masterConfig.serialConfig); cliInit(&masterConfig.serialConfig);

View file

@ -1898,7 +1898,7 @@ static bool processInCommand(void)
return true; return true;
} }
void mspProcessReceivedCommand() void mspProcessReceivedCommand(void)
{ {
if (!(processOutCommand(currentPort->cmdMSP) || processInCommand())) { if (!(processOutCommand(currentPort->cmdMSP) || processInCommand())) {
headSerialError(0); headSerialError(0);