Hello, I'm new to this. I have a MCB2300 and I'm trying to toggle P0.14:15 and monitor on a scope. This should be simple, but it's driving me nuts. Here's the source: int main (void) { PINSEL0 = 0x00000000; PINMODE0 = 0xA0000000; FIO0DIR = 0x0000C000;
while (1) { FIO0PIN1 = 0xC0; FIO0PIN1 = 0x00; } }
What am I doing wrong? Richard
Please wait.
Your loop should have some form of delay, so the pins are left in one state for a while before toggling to the other state.
Placing a delay between the two writes doesn't work. Neither does single stepping in the debug environment.
Found the answer here www.embeddedrelated.com/.../36094.php
Fast IO has to be explicitly enabled via bit 0 of the SCS register.