Sorry, it has been awhile since I looked at MinionBuilder’s version of the libraries… I have my own C/C++ libraries that I use and have for example a Phoenix (3 dof Hex) running on an Arc32. These libraries also reasonably work for Bap40 and Bap28. When I say reasonably work, I mean to say that as I am simply doing it for my own fun, only those parts that I need or want are implemented and the parts that I use more are tested more… There is more details and libraries up on the thread: viewtopic.php?f=8&t=6196
In my version of the libraries, and I believe in MinionBuilder’s. There are functions to talk to the IO lines. The pin numbers mentioned in these functions are in the same order as are defined by the actual BAP you are using. So for example if you do something like:
[code]int main(void)
{
//[INIT]
bap_initialize();
low(9); // Sound
output(9);
//Timer
InitSystemTimer(); // Initialize the system timer
enable(); //enables all interrupts
output (0);
while (1) {
toggle(0);
pause(500);
}
}
[/code]
It should toggle IO pin 0 every half second (more or less)… There are tables setup for the three different Baps (Bap28, Bap40, Arc32) that do all of the mapping of IO pin to the appropriate set of registers. Some of my functions are not 100% functionally the same as the Basic version. That is for example my functions: low, high, toggle, don’t do the work to switch into output mode… Easy to add, but I left it out… So with both sets of libraries you need to make sure you have defined and built it for the right processor…
Again more details in the thread I mentioned.
Kurt