Skip to content

Commit

Permalink
Fixed some build errors from previous commit. Build successful now.
Browse files Browse the repository at this point in the history
  • Loading branch information
JustinDMorrison committed Nov 10, 2024
1 parent 123dd82 commit f6763be
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions drivers/wireless/lpwan/rn2483/rn2483.c
Original file line number Diff line number Diff line change
Expand Up @@ -436,12 +436,12 @@ static int rn2483_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
/* Set Radio modulation */
case WLIOC_SETRADIOMOD:
{
rn2483_mod_e *ptr = (rn2483_mod_e *)(arg);
enum rn2483_mod_e *ptr = (enum rn2483_mod_e *)(arg);
if (*ptr != RN2483_MOD_FSK && *ptr != RN2483_MOD_LORA)
{
return -EINVAL;
}
priv->config.mod = MODULATIONS[*ptr];
priv->config.mod = *ptr;

err = rn2483_radio_set_mod(priv, *ptr);
break;
Expand All @@ -450,7 +450,7 @@ static int rn2483_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
/* Get Radio modulation */
case WLIOC_GETRADIOMOD:
{
*((rn2483_mod_e *)(arg)) = priv->config.mod; // Returns modulation in pointer
*((enum rn2483_mod_e *)(arg)) = priv->config.mod; // Returns modulation in pointer
break;
}

Expand Down Expand Up @@ -577,20 +577,20 @@ static int rn2483_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
/* Set Radio Coding Rate */
case WLIOC_SETRADIOCR:
{
rn2483_cr_e *ptr = (rn2483_cr_e *)(arg);
enum rn2483_cr_e *ptr = (enum rn2483_cr_e *)(arg);
if (*ptr <= 8 && *ptr >= 5)
{
return -EINVAL;
}
priv->config.cr = CODING_RATES[*ptr];
priv->config.cr = *ptr;

err = rn2483_radio_set_cr(priv, *ptr);
break;
}
/* Set Radio Coding Rate */
case WLIOC_GETRADIOCR:
{
*((rn2483_cr_e *)(arg)) = priv->config.cr; // Returns Coding Rate in pointer
*((enum rn2483_cr_e *)(arg)) = priv->config.cr; // Returns Coding Rate in pointer
break;
}

Expand All @@ -616,7 +616,7 @@ static int rn2483_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
case WLIOC_SETRADIOBW:
{
uint16_t *ptr = (uint16_t *)(arg);
if (*arg != 125 && *arg != 250 && *arg != 500)
if (*ptr != 125 && *ptr != 250 && *ptr != 500)
{
return -EINVAL;
}
Expand Down

0 comments on commit f6763be

Please sign in to comment.