Physical Device Drivers (PDD) macros is a software layer that provides set of methods for accessing microcontroller peripheral configuration registers.
PDD macros are a good companion to Peripheral Initialization components (like Init_GPIO, Init_TPM etc..) that provide complete initialization code for a peripheral so the user can then just use PDD macros for runtime control of the peripheral.
1. Add corresponding Peripheral Initialization component for your task and configure it ( they are named Init_{peripheral} ).
2. In the Components view, the Peripheral Initialization components contain a PDD sub-folder with a list of macros only relevant for the selected peripheral. Unfold the component to get the PDD sub folder visible.
3. Unfold the PDD folder and drag and drop macro you need to use (add semilcolon and optinaly a parametr):
The first parameter of all macros is base address of the peripheral and is filled automaticaly with the _DEVICE constant generated for the component if you drag it from Init_ component.
4. Include the corresponding header file. PDD macros are located wihtin the following folder:
{CodeWarrior}\MCU\ProcessorExpert\lib\Kinetis\pdd\inc\
For details please go to the PEx documentation. Available through "Help Contents" command under "Help" menu of CW and then select the following section CodeWarrior for Microcontrollers V10.x > Processor Expert Manuals > Processor Expert User Manual > Application Design > Low-level Access to Peripherals.
Best Regards
Vojtech Filip
Processor Expert Support Team
Hi VF
Is there any documents on using these PDD components ? I mean syntax of the PDD function. At least in PE components there is an option oh help in right click on the components but in these how do we know What to write in the function? I am using CodeWarrior 10.5
Kind Regards
Amit Kumar
This one might be helpful: Low-Level Coding with PDD (Physical Device Driver) | MCU on Eclipse
As for documentation: I click on the function/macro in the source and press F3, this gets me to the macro definition which has example/documentation for it. Not like a manual, but helped me to use the PDD macros.
Thanks Erich , The post is helpful :smileyhappy: