OS Layer in NullOS conficuration

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

OS Layer in NullOS conficuration

794 Views
Pochie
Contributor I

Dear NXP Community,

I am trying to port the “NxpNfcRdLib_PN5180_LPC1769_v05.22.01_Full” library to our MCU. After porting the Driver Abstraction Layer, I wanted to implement the basic discovery loop.

1.Even in Null Os configuration it seems that hardware specific timer functions are needed to be ported. Is that true for the complete library or just the examples?

 

An example for the functions to be ported are given in:

phOsal_Port_CM3.c

phOsal_Port_CM4.c

phOsal_Port_PN74xxxx.c

that are defined in phOsal_NullOs_Port.h

 

2.But “phOsal_Port_PN74xxxx.c” returns all ...TickTimer(void) functions with just an “PH_OSAL_SUCCESS”. Is it because The PN7462 family has a 32-bit Arm® Cortex®-M0 that may be already integrates an Os?

Inside the phOsal_Port_XXX.c files and also the phOsal_NullOs_Port.h are  functions to put the processor to sleep and to wake it up. That would be lees of a problem if its just for the examples.

 

3.But the phOsal_Sleep() function is called inside the phOsal_EventPend(...) function with out a condition. That function again is called by many other functions, with one of the most important “phhalHw_Pn5180_Exchange”. From that call hierarchy it would seem, the Osal layer is mandatory for the NFC library, right?

 

4. So the NFC library puts the used controller to sleep? That would seem strange and not very practical if NFC is just part of a bigger projects that uses the same MCU.

 

5. At least in the “phhalHw_Pn5180_Exchange” function, there is a condition for sending the Mcu into sleep mode. That would be if (pDataParams->bPollGuardTimeFlag == PH_ON). Dose that mean the Exchange function can be used, with out sending the MCU into sleep?

 

6.In  my eyes the most critical functions in the NullOs configuration would be

phOsal_Sleep

phOsal_WakeUp

phOsal_Sleep with its assampler instruction “wfe” is quiet clear but phOsal_WakeUp with its assampler instruction “sev” seem to only make sense in a multi cpu configuration, since a sleeping cpu does not seem to be able to send it. So the wake up need to come from an interrupt source like the tick timer?

 

7. That timer would need to be a separate timer from the one configured in the Driver Abstraction Layer right?

 

To sum it up: Do I need to port the OS Layer even in the NullOs configuration and if so are there information on how to do that, like there are for the Driver Abstraction Layer? I found some examples for porting the library and they show what need to be done on the Driver Abstraction Layer but none of the really talks about the OS Layer. If the OS Layer is mandatory for the NFC library can it be used with out the sleep mode of the MCU?

 

Best regards

Pochie

Labels (2)
0 Kudos
1 Reply

764 Views
fangfang
NXP TechSupport
NXP TechSupport

Hello,

If the customer needs to porting the library to other NXP MCU. One may refer to the information as the link.URL:https://community.nxp.com/t5/NFC-Knowledge-Base/Overview-of-supported-NFC-MCU-Combinations/ta-p/1124410.If NOT NXP MCU. Unfortunately, We don't have related information for it. Sorry for the inconvenience may cause.

Have a nice day.

 

 

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-----------------------------------------------------------------------------

0 Kudos