|
Post by juanjqh on Mar 10, 2022 11:27:57 GMT
Hi,why does not work like in AVR, ARM or teensy? any alternative? I look in the Variants.h file ... // These need adapting to Aurix  ? what does this mean? not work 100%?#define digitalPinToPort(P) ((uint32)AURduinoPins .port) // ( g_APinDescription .pPort )
#define digitalPinToBitMask(P) (1 << ((uint32_t)AURduinoPins .pinIndex))
#define digitalPinToBitMaskIOCR(P) (uint32_t)(8*(0x03u & (uint32_t)AURduinoPins .pinIndex)) // ( g_APinDescription .ulPin )
//#define analogInPinToBit(P) ( )
#define portOutputRegister(port) (uint32*)&((Ifx_P*)port)->OUT.U // (Ifx_P_OUT*)&((Ifx_P*)port)->OUT.U//( &(port->PIO_ODSR) ) MODULE_P33.OUT.U = 1; Ifx_P
#define portInputRegister(port) (uint32*)&((Ifx_P*)port)->IN.U // (Ifx_P_IN*)&((Ifx_P*)port)->IN.U //( &(port->PIO_PDSR) )
/* Return the address of the IOCRx required for this pin */
|
|
|
Post by Admin on Apr 26, 2022 8:26:12 GMT
In spite of the comment, these macros do work. However the differing port structure on the Aurix means that they will not work exactly like on the AVR.
|
|