Electronic Components Datasheet Search
  English  ▼

X  

DFR0627 Datasheet(PDF) 9 Page - DFROBOT

Part # DFR0627
Description  Gravity: IIC to dual UART module
PDF  16 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  DFROBOT [DFROBOT]
Direct Link  https://www.dfrobot.com/
Logo DFROBOT - DFROBOT

DFR0627 Datasheet(HTML) 9 Page - DFROBOT

Back Button DFR0627 Datasheet HTML 5Page - DFROBOT DFR0627 Datasheet HTML 6Page - DFROBOT DFR0627 Datasheet HTML 7Page - DFROBOT DFR0627 Datasheet HTML 8Page - DFROBOT DFR0627 Datasheet HTML 9Page - DFROBOT DFR0627 Datasheet HTML 10Page - DFROBOT DFR0627 Datasheet HTML 11Page - DFROBOT DFR0627 Datasheet HTML 12Page - DFROBOT DFR0627 Datasheet HTML 13Page - DFROBOT Next Button
Zoom Inzoom in Zoom Outzoom out
 9 / 16 page
background image
2023/10/12 10:51
Gravity: IIC to dual UART module Wiki - DFRobot
https://wiki.dfrobot.com/Gravity: IIC to Dual UART Module SKU: DFR0627
9/16
*@n The 4th and 3rd bits are fixed, value 1 and 0 respectively
*@n The values of the 2nd and 1st bits are the sub UART channels, 00 for sub UART 1, 01 for sub UART 2.
*@n The 0 bit represents the operation object: 0 for register, 1 for FIFO cache.
*/
DFRobot_IICSerial iicSerial1(Wire, /*subUartChannel =*/SUBUART_CHANNEL_1,/*IA1 = */1,/*IA0 = */1);//Construct UART1
//DFRobot_IICSerial iicSerial1;//Default constructor, UART1, IA1 = 1, IA0 = 1
DFRobot_IICSerial iicSerial2(Wire, /*subUartChannel =*/SUBUART_CHANNEL_2, /*IA1 = */1,/*IA0 = */1);//Construct UART2
uint8_t flag = 0;//A flag bit, judge whether to print the prompt information of UART1 and UART2.
//if it is 0, print "UART1 receive data: " or "UART2 receive data: "
void setup() {
Serial.begin(115200);
/*begin Init function, set band rate according to the selected crystal frequency.
begin(long unsigned baud) Call the function, set sub UART band rate.
default setting->Band rate: baud, data format
:IIC_SERIAL_8N1, 8 bits data, no check mode, 1 bit stop bit.
begin(long unsigned baud, uint8_t format)Use the function to set band rate and data format:
Parameter supported baud:2400, 4800, 57600, 7200, 9600, 14400, 19200, 28800, 38400,
76800, 115200, 153600, 230400, 460800, 307200, 921600
Parameter available format:
IIC_SERIAL_8N1
IIC_SERIAL_8N2
IIC_SERIAL_8Z1
IIC_SERIAL_8Z2
IIC_SERIAL_8O1
IIC_SERIAL_8O2
IIC_SERIAL_8E1
IIC_SERIAL_8E2
IIC_SERIAL_8F1
IIC_SERIAL_8F2
8 represents the number of data bit, N for no parity, Z for 0 parity, O for Odd parity, E for Even parity,
F for 1 parity, 1 or 2 for the number of stop bit. Default IIC_SERIAL_8N1
*/
iicSerial1.begin(/*baud = */115200);/*UART1 init*/
//iicSerial1.begin(/*baud = */115200, /*format = */IIC_SERIAL_8N1);
iicSerial2.begin(/*baud = */115200);/*UART2 init*/
Serial.println("\n+--------------------------------------------+");
Serial.println("|
Connected UART1's TX pin to RX pin.
|");//Connect pin TX and RX of UART1
Serial.println("|
Connected UART2's TX pin to RX pin.
|");//Connect pin TX and RX of UART2
Serial.println("|
UART1 send a String: \"hello, Serial1!\"
|");//UART1 transmit a string "hello, Serial1!"
Serial.println("|
UART2 send a number: 123
|");//UART2 transmit numbers 123
Serial.println("+--------------------------------------------+");
iicSerial1.println("hello, Serial1!");//UART1 transmit string:"hello, Serial1!"
iicSerial2.write(123);//UART2 transmit:123
S
i l
i tl ("S
i l t
i t UART1
d UART2'
i
d t
") //
i t th
d t
i
d b
UART1
d UART2



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
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