Moving from KSDK1 to KSDK2

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Moving from KSDK1 to KSDK2

ソリューションへジャンプ
675件の閲覧回数
davepfaltzgraff
Senior Contributor I

In moving from KSDK1 to KSDK2, I cam unable to find corresponding documentation for the following routines:

SIM_HAL_SetAdcAlternativeTriggerCmd(SIM, ADC_INSTANCE, true);

SIM_HAL_SetAdcPreTriggerMode(SIM, ADC_INSTANCE, kSimAdcPretrgselA);

SIM_HAL_SetAdcTriggerMode(SIM, ADC_INSTANCE, kSimAdcTrgSelPit0);

 

Would someone please point me in the right direction?

Thanks

ラベル(1)
1 解決策
493件の閲覧回数
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, David,

I think the SDK2.0 remove all the HAL function, if user wants to read specified bits in peripheral register, he can access the register directly.

for example, your above Hal function only read/write the bits in SIM_SOPT7, you can use the structure to access the register in SDK2.0.

SIM->SOPT7=0xxxxx;

Hope it can help you

元の投稿で解決策を見る

0 件の賞賛
2 返答(返信)
494件の閲覧回数
davepfaltzgraff
Senior Contributor I

This is just a comment for the "community" at large and is merely my observation.

This solution presents a double-edged sword. On the one hand, it forces the programmer to work closer to the lower (hardware) level. For an embedded programmer like me this is a "good thing". The other edge of the sword, though, is that it removes the level of encapsulation that was present in the previous methodology and thus, by requiring more "knowledge" by the programmer, it reduces the pool of programmers capable of handling the task. And, this is a "bad thing."

There will be some that will say that things like processor expert, etc. will handle this. But, I see two additional effects of this move. The first is a further extension of the idea that only a select few need to understand the inner machinations of the processor. The other is that in my experience the "processor expert" implementation, although great in concept, almost always falls short of delivering what it promises.

Well, back to the appropriate Family Reference Manuals...

Thanks, Xiangjun, for the pointer.

494件の閲覧回数
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, David,

I think the SDK2.0 remove all the HAL function, if user wants to read specified bits in peripheral register, he can access the register directly.

for example, your above Hal function only read/write the bits in SIM_SOPT7, you can use the structure to access the register in SDK2.0.

SIM->SOPT7=0xxxxx;

Hope it can help you

0 件の賞賛