Content originally posted in LPCWare by amelendez@dibal.com on Fri Dec 16 04:25:18 MST 2011
Thanks.
With other example, I have checked that I can move up (3V3) and down (0V) both PIO1_6 and PIO1_7. So the connection from the LPC1114 and the UART connector is tested and it is good.
Then, I have modified the 'uart' example as follows:
[SIZE=2]UARTInit(UART_BAUD);[/SIZE]
[B][SIZE=2][COLOR=#7f0055][SIZE=2][COLOR=#7f0055]#if[/COLOR][/SIZE][/COLOR][/SIZE][/B]
[LEFT][SIZE=2]MODEM_TEST[/SIZE]
[SIZE=2]ModemInit();[/SIZE]
[B][SIZE=2][COLOR=#7f0055][SIZE=2][COLOR=#7f0055]#endif[/COLOR][/SIZE][/COLOR][/SIZE][/B][/LEFT]
[LEFT][SIZE=2]UARTCount1=10;[/SIZE]
[SIZE=2]UARTBuffer1[1] = 10;[/SIZE][/LEFT]
[LEFT][B][SIZE=2][COLOR=#7f0055][SIZE=2][COLOR=#7f0055]while[/COLOR][/SIZE][/COLOR][/SIZE][/B][SIZE=2] (1) [/SIZE][/LEFT]
[LEFT][SIZE=2]{ [/SIZE][SIZE=2][COLOR=#3f7f5f][SIZE=2][COLOR=#3f7f5f]/* Loop forever */[/COLOR][/SIZE][/COLOR][/SIZE]
[SIZE=2]UARTSend( ([/SIZE][SIZE=2][COLOR=#005032][SIZE=2][COLOR=#005032]uint8_t[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] *)UARTBuffer1, UARTCount1 );[/SIZE]
[SIZE=2]}[/SIZE][/LEFT]
[LEFT][SIZE=2][SIZE=3][COLOR=black]Without connectig any UART port to my board (PIOs pins opened) and I don't get (in the oscilloscope)any signal neither at PIO1_6 neither PIO1_7 (both 0V)[/COLOR][/SIZE][/SIZE][/LEFT]
[LEFT]PIO1_6 and PIO1_7 are configurated for UART when the application executes: [SIZE=2]UARTInit(UART_BAUD);[/SIZE][/LEFT]
[LEFT][SIZE=2]LPC_IOCON->[/SIZE][SIZE=2][COLOR=#0000c0][SIZE=2][COLOR=#0000c0]PIO1_6[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] &= ~0x07; [/SIZE][SIZE=2][COLOR=#3f7f5f][SIZE=2][COLOR=#3f7f5f]/* UART I/O [U]config[/U] */[/COLOR][/SIZE][/COLOR][/SIZE][/LEFT]
[SIZE=2]LPC_IOCON->[/SIZE][SIZE=2][COLOR=#0000c0][SIZE=2][COLOR=#0000c0]PIO1_6[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] |= 0x01; [/SIZE][SIZE=2][COLOR=#3f7f5f][SIZE=2][COLOR=#3f7f5f]/* UART RXD */[/COLOR][/SIZE][/COLOR][/SIZE]
[LEFT][SIZE=2]LPC_IOCON->[/SIZE][SIZE=2][COLOR=#0000c0][SIZE=2][COLOR=#0000c0]PIO1_7[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] &= ~0x07; [/SIZE]
[SIZE=2]LPC_IOCON->[/SIZE][SIZE=2][COLOR=#0000c0][SIZE=2][COLOR=#0000c0]PIO1_7[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] |= 0x01; [/SIZE][SIZE=2][COLOR=#3f7f5f][SIZE=2][COLOR=#3f7f5f]/* UART TXD */[/COLOR][/SIZE][/COLOR][/SIZE][/LEFT]