#26576 - DiscoStew - Mon Sep 20, 2004 4:24 am
I plan to take a bunch of C functions I made, and wrap them together into a library. Some of the functions use DMA3, which isn't so bad except for this instance. In another project, I plan to use this library and AAS together. Now AAS includes a DoDMA3 function that is a bit necessary for people not doing the single stmia instruction. Now, I'd like to link that function into my library so that it uses that if the AAS library is also in the project, or not use it if it isn't.
My idea was to check for the symbol __AAS__ (since the AAS.h file defines it) to see if the library was also being used, like such...
..and in situations where I would use DMA3, I'd do this...
Now this was just an idea so that my library could be compatible with AAS, but my method isn't working. Perhaps someone out there knows what I am trying to do, and could help me with this problem. Any help would be appreciated.
_________________
DS - It's all about DiscoStew
My idea was to check for the symbol __AAS__ (since the AAS.h file defines it) to see if the library was also being used, like such...
Code: |
#ifdef __AAS__
#include "AAS.h" #endif |
..and in situations where I would use DMA3, I'd do this...
Code: |
#ifdef __AAS__
AAS_DoWork(....function parameters....); #else {....whatever I plan to do with DMA3......} #endif |
Now this was just an idea so that my library could be compatible with AAS, but my method isn't working. Perhaps someone out there knows what I am trying to do, and could help me with this problem. Any help would be appreciated.
_________________
DS - It's all about DiscoStew