Skip to content

Commit b6581d3

Browse files
committed
Rename the f parameter into hz to avoid confusion with a loopcounter
1 parent a769d2b commit b6581d3

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

drivers/CAN.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,14 @@ CAN::CAN(PinName rd, PinName td) : _can(), _irq() {
3434
can_irq_init(&_can, (&CAN::_irq_handler), (uint32_t)this);
3535
}
3636

37-
CAN::CAN(PinName rd, PinName td, int f) : _can(), _irq() {
37+
CAN::CAN(PinName rd, PinName td, int hz) : _can(), _irq() {
3838
// No lock needed in constructor
3939

4040
for (int i = 0; i < sizeof _irq / sizeof _irq[0]; i++) {
4141
_irq[i].attach(donothing);
4242
}
4343

44-
can_init_freq(&_can, rd, td, f);
44+
can_init_freq(&_can, rd, td, hz);
4545
can_irq_init(&_can, (&CAN::_irq_handler), (uint32_t)this);
4646
}
4747

drivers/CAN.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,9 +116,9 @@ class CAN {
116116
*
117117
* @param rd the rd pin
118118
* @param td the td pin
119-
* @param f the bus frequency in hertz
119+
* @param hz the bus frequency in hertz
120120
*/
121-
CAN(PinName rd, PinName td, int f);
121+
CAN(PinName rd, PinName td, int hz);
122122

123123
virtual ~CAN();
124124

0 commit comments

Comments
 (0)