Confused about ifdef code, greyed out
Posted: Sat Sep 29, 2018 9:00 pm
All,
So I am debugging my XU208 hardware and I am really confused about what should be greyed out and what is. For instance I am crashing on a DFU call which is bogus because it is not enabled. So I opened endpoint0.xc which is were the call came from. I have in my make file flags:
XCC_FLAGS = $(BUILD_FLAGS) -DI2S_CHANS_DAC=2 -DI2S_CHANS_ADC=0 -DNUM_USB_CHAN_OUT=2 -DNUM_USB_CHAN_IN=0 -DMIDI=0 -DSPDIF_TX=0 -DSPDIF_RX=0 -DADAT_TX=0 -DADAT_RX=0 -DDSD_CHANS_DAC=0 -DAUDIO_CLASS=2
NUM_CHANS_OUT = 2, but in endpoint0.xc the code is greyed out for input and output.
I also have in my customdefines AUDIO_CLASS=2, but in main.xc if ifdef for that indicates a default back to UAC1??? So I added that switch statement -DAUDIO_CLASS=2 on the build flags but it's still greyed out.
The DFU is totally greyed out so I am not sure what is going on. I think the crash is basically that my flags or make or something is enabled in one source file and not enabled in another and that is causing the problem.
Any ideas or is greyed out display just something to ignore?
Thanks,
Gordon
So I am debugging my XU208 hardware and I am really confused about what should be greyed out and what is. For instance I am crashing on a DFU call which is bogus because it is not enabled. So I opened endpoint0.xc which is were the call came from. I have in my make file flags:
XCC_FLAGS = $(BUILD_FLAGS) -DI2S_CHANS_DAC=2 -DI2S_CHANS_ADC=0 -DNUM_USB_CHAN_OUT=2 -DNUM_USB_CHAN_IN=0 -DMIDI=0 -DSPDIF_TX=0 -DSPDIF_RX=0 -DADAT_TX=0 -DADAT_RX=0 -DDSD_CHANS_DAC=0 -DAUDIO_CLASS=2
NUM_CHANS_OUT = 2, but in endpoint0.xc the code is greyed out for input and output.
I also have in my customdefines AUDIO_CLASS=2, but in main.xc if ifdef for that indicates a default back to UAC1??? So I added that switch statement -DAUDIO_CLASS=2 on the build flags but it's still greyed out.
The DFU is totally greyed out so I am not sure what is going on. I think the crash is basically that my flags or make or something is enabled in one source file and not enabled in another and that is causing the problem.
Any ideas or is greyed out display just something to ignore?
Thanks,
Gordon