Skip to content

Commit

Permalink
fix cadacy complaint again
Browse files Browse the repository at this point in the history
  • Loading branch information
pkotamnives committed Aug 9, 2023
1 parent 7ae9519 commit 4e272e2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions projects/cm_mcu/LocalTasks.c
Original file line number Diff line number Diff line change
Expand Up @@ -672,25 +672,24 @@ int8_t getFFpresentbit(const uint8_t i)
{
uint8_t j;
int8_t val;
uint8_t bitone = 0x1U;
configASSERT(i < NFIREFLIES);
if (i < NFIREFLIES_IT_F1) {
j = i;
val = ffl12_f1_args.present_bit_mask & (bitone << (uint8_t)j);
val = ffl12_f1_args.present_bit_mask & (0x1U << j);
}

else if (NFIREFLIES_IT_F1 <= i && i < NFIREFLIES_IT_F1 + NFIREFLIES_DAQ_F1) {
j = i - NFIREFLIES_IT_F1;
val = ffl12_f1_args.present_bit_mask & (bitone << (uint8_t)j);
val = ffl12_f1_args.present_bit_mask & (0x1U << j);
}

else if (NFIREFLIES_F1 <= i && i < NFIREFLIES_F1 + NFIREFLIES_IT_F2) {
j = i - NFIREFLIES_F1;
val = ffl12_f1_args.present_bit_mask & (bitone << (uint8_t)j);
val = ffl12_f1_args.present_bit_mask & (0x1U << j);
}
else {
j = i - (NFIREFLIES_F1 + NFIREFLIES_IT_F2);
val = ffl12_f1_args.present_bit_mask & (bitone << (uint8_t)j);
val = ffl12_f1_args.present_bit_mask & (0x1U << j);
}

return val;
Expand Down
2 changes: 1 addition & 1 deletion projects/cm_mcu/MonitorI2CTask.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ struct MonitorI2CTaskArgs_t {
TickType_t updateTick; // last update time, in ticks
SemaphoreHandle_t xSem; // semaphore for controlling access to device
uint8_t ffpart_bit_mask; // this mask is only used for detecting 12-ch 25Gbps on the REV2 board
uint8_t present_bit_mask; // this mask is used for all ffs to detect if it is mounted or not
uint32_t present_bit_mask; // this mask is used for all ffs to detect if it is mounted or not
const uint8_t n_rxchs; // the number of optical receiver channels
uint16_t *opt_pow_values; // a set of optical power measurements only from FFs with 25Gbs
UBaseType_t stack_size; // stack size of task
Expand Down

0 comments on commit 4e272e2

Please sign in to comment.