Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
Hi to all
I am fighting now with PortOut and PortInOut libraries ...
I have simple prog.
#include "mbed.h" #define LED_MASK 0x00000ff0 PortOut IoPort(Port0, LED_MASK); DigitalOut myled(LED1); int main() { while(1) { myled = !myled; wait(0.5); IoPort = 0xff; wait(0.5); IoPort = 0xaa; wait(0.5); IoPort = 0x55; } }I set 8bit (ports p30, p29, p8, p7, p6, p5, p28, p27) mask on port0 but when I try to set 8 bit value I get only first 4 bite workingwhere is problem ?