This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

## Macro

Hi,

I am use the ## as follows

#define ADC_SRV_DEV 1

#define ADCCON(dev, chan, reg) AD##dev##CON##chan##reg

then when I give
ADCCON(ADC_SRV_DEV, 1, bits.FORM) = 3; // this is equavalent to AD1CON1bits.FORM = 3;

But for some reason it is taking it as ADADC_SRV_DEVCON1bits

Please help

0