Programming Examples
15-50
ADSP-BF50x Blackfin Processor Hardware Reference
The parent routine in
Listing 15-3
performs autobaud detection using
UART0
and
TIMER2
.
Listing 15-3. UART Autobaud Detection Parent Routine
p0.l = lo(PORTG_FER); /* function enable on UART0 pins PG12
and PG13 */
p0.h = hi(PORTG_FER); /* by default PORTG_MUX register is all
set */
r0 = PG12 | PG13 (z)
w[p0] = r0;
p0.l = lo(UART0_GCTL); /* select UART 0 */
p0.h = hi(UART0_GCTL);
p1.l = lo(TIMER2_CONFIG); /* select TIMER 2 */
p1.h = hi(TIMER2_CONFIG);
call uart_autobaud;
r0 >>= 7;
/* divide PERIOD value by (16 x 8) */
call uart_init;
...
The subroutine in
Listing 15-4
transmits a character by polling operation.
Listing 15-4. UART Character Transmission
/*******************************************************
* Transmit a single byte by polling the THRE bit.
* Input parameters: r0 holds the character to be transmitted
*
p0 contains UARTx_GCTL register address
* Return values: none
*******************************************************/
uart_putc:
[--sp] = r7;
uart_putc.wait:
r7 = w[p0+UART0_LSR-UART0_GCTL] (z);
Содержание EZ-KIT Lite ADSP-BF506F
Страница 50: ...Contents l ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 92: ...Development Tools 1 30 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 110: ...Interface Overview 3 12 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 132: ...Unique Information for the ADSP BF50x Processor 4 22 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 236: ...Internal Flash Memory Control Registers 6 92 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 342: ...Unique Information for the ADSP BF50x Processor 7 106 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 484: ...Unique Information for the ADSP BF50x Processor 10 60 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 493: ...ADSP BF50x Blackfin Processor Hardware Reference 11 9 Core Timer Unique Information for the ADSP BF50x Processor None ...
Страница 494: ...Unique Information for the ADSP BF50x Processor 11 10 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 506: ...Unique Information for the ADSP BF50x Processor 12 12 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 544: ...Unique Information for the ADSP BF50x Processor 13 38 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 650: ...Programming Examples 15 56 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 712: ...Unique Information for the ADSP BF50x Processor 16 62 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 804: ...Programming Examples 17 92 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 972: ...Unique Information for the ADSP BF50x Processor 20 38 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 1194: ...Programming Examples 24 90 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 1256: ...ACM Registers A 50 ADSP BF50x Blackfin Processor Hardware Reference ...
Страница 1264: ...Boundary Scan Architecture B 8 ADSP BF50x Blackfin Processor Hardware Reference ...