9 years ago.

No output at the pins

I'm using this;

serial output

#include "mbed.h"
Serial  serial( p28, p27 );

int main() {
    char    c   = 0;
    
    while( 1 ) {
        serial.putc( c++ );    
    }
}

I'm using p27 as my clock output and p28 is my serial data out but when i compile and download the program, i get no output at both pins.

I might be doing something wrong since I'm new to mbed, like completely new.

2 Answers

9 years ago.

Before you do any further programming please visit this link and read it a number of times to get a good understanding of what you are trying to do.https://developer.mbed.org/handbook/Serial

Accepted Answer
9 years ago.

Did you press the reset button after download. The code wont run otherwise.. Also note that the Serial object is a regular UART port. The pins are TX and RX. There is no separate clock. You will only see clock lines for SPI or I2C. See handbook.

Sorry Wim my bump was not intended.

posted by David Fletcher 07 Apr 2015