Motore di ricerca datesheet componenti elettronici
  Italian  ▼
ALLDATASHEETIT.COM

X  

DS41356B Scheda tecnica(PDF) 39 Page - Microchip Technology

Il numero della parte DS41356B
Spiegazioni elettronici  Low Pin Count USB Development Kit
PDF  54 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Produttore elettronici  MICROCHIP [Microchip Technology]
Homepage  http://www.microchip.com
Logo MICROCHIP - Microchip Technology

DS41356B Scheda tecnica(HTML) 39 Page - Microchip Technology

Back Button DS41356B Datasheet HTML 35Page - Microchip Technology DS41356B Datasheet HTML 36Page - Microchip Technology DS41356B Datasheet HTML 37Page - Microchip Technology DS41356B Datasheet HTML 38Page - Microchip Technology DS41356B Datasheet HTML 39Page - Microchip Technology DS41356B Datasheet HTML 40Page - Microchip Technology DS41356B Datasheet HTML 41Page - Microchip Technology DS41356B Datasheet HTML 42Page - Microchip Technology DS41356B Datasheet HTML 43Page - Microchip Technology Next Button
Zoom Inzoom in Zoom Outzoom out
 39 / 54 page
background image
© 2009 Microchip Technology Inc.
DS41356B-page 35
EXAMPLE 2-10:
INITIALIZEUSART() CODE
The reader is encouraged to review the data sheet for the PIC18F14K50 EUSART
section for more information on the specifics of the configuration code.
Next, the application specific code will be added that will implement the flowchart
shown in Figure 2-6.
10. Scroll down to the ProcessIO()and copy and paste the contents of
Example 2-11 into the section labeled:
/*****************************************************
ADD CODE TO CHECK IF RS232 HAS
BEEN SENT ALONG USB
AND THE CODE TO CHECK IF
ANY NEW RS232 TRANSMISSION
HAS BEEN RECEIVED AND STORED
******************************************************/
As per the flowchart in Figure 2-6, this code will ensure that the buffer containing the
data transmitted from the RS-232 has been sent to the USB firmware. If so, the code
then checks for any new RS-232 data that has been stored in the buffer.
#if defined(__18CXX)
unsigned char c;
#if defined(__18F14K50)
ANSELHbits.ANS11 = 0;
// Make RB5 digital so USART can
//use pin for Rx
#endif
UART_TRISRx=1;
// RX
UART_TRISTx=0;
// TX
TXSTA = 0x24;
// TX enable BRGH=1
RCSTA = 0x90;
// Single Character RX
SPBRG = 0x70;
SPBRGH = 0x02;
// 0x0271 for 48MHz -> 19200 baud
BAUDCON = 0x08;
// BRG16 = 1
c = RCREG;
// read
#endif



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54


Scheda tecnica Scarica

Go To PDF Page


Link URL



Lei ha avuto il aiuto da alldatasheet?  [ DONATE ] 

Di alldatasheet   |   Richest di pubblicita   |   contatti   |   Privacy Policy   |   Collegamento alla scheda tecnica    |   scambio Link   |   Ricerca produttore
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com