Skip to content

Commit

Permalink
Updated SerialMuxProt to Version 2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jkerpe committed Nov 23, 2023
1 parent 02db626 commit 705aca1
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 21 deletions.
7 changes: 5 additions & 2 deletions lib/APPConvoyLeader/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
* Prototypes
*****************************************************************************/

static void App_motorSpeedSetpointsChannelCallback(const uint8_t* payload, const uint8_t payloadSize);
static void App_motorSpeedSetpointsChannelCallback(const uint8_t* payload, const uint8_t payloadSize, void* userData);

/******************************************************************************
* Local Variables
Expand Down Expand Up @@ -167,9 +167,12 @@ void App::reportSpeed()
*
* @param[in] payload Motor speed left/right
* @param[in] payloadSize Size of twice motor speeds
* @param[in] userData User data provided by the application.
*/
void App_motorSpeedSetpointsChannelCallback(const uint8_t* payload, const uint8_t payloadSize)
void App_motorSpeedSetpointsChannelCallback(const uint8_t* payload, const uint8_t payloadSize, void* userData)
{
/* Not implemented*/
(void) userData;
if ((nullptr != payload) && (SPEED_SETPOINT_CHANNEL_DLC == payloadSize))
{
const SpeedData* motorSpeedData = reinterpret_cast<const SpeedData*>(payload);
Expand Down
2 changes: 1 addition & 1 deletion lib/APPConvoyLeader/library.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
{
"owner": "gabryelreyes",
"name": "SerialMuxProt",
"version": "^1.0.0"
"version": "^2.0.0"
}
],
"frameworks": "*",
Expand Down
14 changes: 10 additions & 4 deletions lib/APPRemoteControl/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@
* Prototypes
*****************************************************************************/

static void App_cmdChannelCallback(const uint8_t* payload, const uint8_t payloadSize);
static void App_motorSpeedsChannelCallback(const uint8_t* payload, const uint8_t payloadSize);
static void App_cmdChannelCallback(const uint8_t* payload, const uint8_t payloadSize, void* userData);
static void App_motorSpeedsChannelCallback(const uint8_t* payload, const uint8_t payloadSize, void* userData);

/******************************************************************************
* Local Variables
Expand Down Expand Up @@ -191,9 +191,12 @@ void App::sendLineSensorsData() const
*
* @param[in] payload Command id
* @param[in] payloadSize Size of command id
* @param[in] userData User data provided by the application.
*/
static void App_cmdChannelCallback(const uint8_t* payload, const uint8_t payloadSize)
static void App_cmdChannelCallback(const uint8_t* payload, const uint8_t payloadSize, void* userData)
{
/* Not implemented*/
(void) userData;
if ((nullptr != payload) && (sizeof(RemoteCtrlState::CmdId) == payloadSize))
{
RemoteCtrlState::CmdId cmdId = *reinterpret_cast<const RemoteCtrlState::CmdId*>(payload);
Expand All @@ -207,9 +210,12 @@ static void App_cmdChannelCallback(const uint8_t* payload, const uint8_t payload
*
* @param[in] payload Motor speed left/right
* @param[in] payloadSize Size of twice motor speeds
* @param[in] userData User data provided by the application.
*/
static void App_motorSpeedsChannelCallback(const uint8_t* payload, const uint8_t payloadSize)
static void App_motorSpeedsChannelCallback(const uint8_t* payload, const uint8_t payloadSize, void* userData)
{
/* Not implemented*/
(void) userData;
if ((nullptr != payload) && (SPEED_SETPOINT_CHANNEL_DLC == payloadSize) && (true == gIsRemoteCtrlActive))
{
const SpeedData* motorSpeedData = reinterpret_cast<const SpeedData*>(payload);
Expand Down
2 changes: 1 addition & 1 deletion lib/APPRemoteControl/library.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
{
"owner": "gabryelreyes",
"name": "SerialMuxProt",
"version": "^1.0.0"
"version": "^2.0.0"
}
],
"frameworks": "*",
Expand Down
36 changes: 23 additions & 13 deletions lib/APPSensorFusion/library.json
Original file line number Diff line number Diff line change
@@ -1,19 +1,29 @@
{
"name": "SensorFusion",
"name": "APPSensorFusion",
"version": "0.1.0",
"description": "SensorFusion application",
"authors": [{
"name": "Juliane Kerpe",
"email": "[email protected]",
"url": "https://github.com/jkerpe",
"maintainer": true
}],
"description": "Sensor Fusion application",
"authors": [
{
"name": "Juliane Kerpe",
"email": "[email protected]",
"url": "https://github.com/jkerpe",
"maintainer": true
}
],
"license": "MIT",
"dependencies": [{
"name": "Service"
}, {
"name": "HALInterfaces"
}],
"dependencies": [
{
"name": "Service"
},
{
"name": "HALInterfaces"
},
{
"owner": "gabryelreyes",
"name": "SerialMuxProt",
"version": "^2.0.0"
}
],
"frameworks": "*",
"platforms": "*"
}

0 comments on commit 705aca1

Please sign in to comment.