Why do the FlexCAN SDK v2.0 functions mix lowercase and uppercase "L" in the function names?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

Why do the FlexCAN SDK v2.0 functions mix lowercase and uppercase "L" in the function names?

跳至解决方案
1,452 次查看
kylemanna
Contributor II

Was confused by a linker problem to discover the API is strange.  Consider the following function list:

FLEXCAN_Init

FLEXCAN_Deinit

FLEXCAN_GetDefaultConfig

FLEXCAN_SetTimingConfig

FlEXCAN_SetRxMbGlobalMask

FlEXCAN_SetRxFifoGlobalMask

FlEXCAN_SetRxIndividualMask

FLEXCAN_SetTxMbConfig

FLEXCAN_SetRxMbConfig

FlEXCAN_SetRxFifoConfig

FLEXCAN_GetStatusFlags

FLEXCAN_ClearStatusFlags

FlEXCAN_GetBusErrCount

FLEXCAN_GetMbStatusFlags

FLEXCAN_ClearMbStatusFlags

FLEXCAN_EnableInterrupts

FLEXCAN_DisableInterrupts

FLEXCAN_EnableMbInterrupts

FLEXCAN_DisableMbInterrupts

FLEXCAN_Enable

FLEXCAN_WriteTxMb

FLEXCAN_ReadRxMb

FlEXCAN_ReadRxFifo

FlEXCAN_TransferSendBlocking

FlEXCAN_TransferReceiveBlocking

FlEXCAN_TransferReceiveFifoBlocking

FLEXCAN_TransferCreateHandle

FLEXCAN_TransferSendNonBlocking

FLEXCAN_TransferReceiveNonBlocking

FLEXCAN_TransferReceiveFifoNonBlocking

FLEXCAN_TransferAbortSend

FLEXCAN_TransferAbortReceive

FLEXCAN_TransferAbortReceiveFifo

FLEXCAN_TransferHandleIRQ

Some have the "FLEXCAN_" prefix while many have the "FlEXCAN_" prefix.  Why the lowercase "L"? It appears this way in the documentation as well: Kinetis SDK 2.0 API Reference Manual: FlexCAN Driver
标签 (1)
标记 (4)
1 解答
851 次查看
Jmart
NXP Employee
NXP Employee

This is not intentional. I'll ask the team to correct this immediately.

Thanks for bringing this to my attention.

Jason

在原帖中查看解决方案

4 回复数
852 次查看
Jmart
NXP Employee
NXP Employee

This is not intentional. I'll ask the team to correct this immediately.

Thanks for bringing this to my attention.

Jason

851 次查看
kylemanna
Contributor II

Hi again Jmart,

One other minor comment: the internal API has two static function named FLEXCAN_EnterFrazeMode() and FLEXCAN_ExitFrazeMode().  I assume these are referring the the "Freeze" mode of the FlexCAN peripheral?  If someone is going to be cleaning up the public API, might be handy to rename these as well.

I like my CAN peripherals like I like my movies: Frozen.

frozen-vendor-20140616.jpg

Cheers!

0 项奖励
回复
851 次查看
Jmart
NXP Employee
NXP Employee

Kyle,

Spoke with the team and they have already cleaned up both issues in the latest FlexCAN driver.

Jasno

0 项奖励
回复
851 次查看
kylemanna
Contributor II

Hi Jason,

Thanks for addressing this.  Look forward to the next release!

- Kyle

0 项奖励
回复