arduino:bk3231
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| arduino:bk3231 [2017/08/07 20:46] – aistis | arduino:bk3231 [2017/08/07 20:49] (current) – aistis | ||
|---|---|---|---|
| Line 2: | Line 2: | ||
| b26782h | b26782h | ||
| + | |||
| + | defaultinis pairinimosi slaptazodis 1234 | ||
| {{: | {{: | ||
| Line 40: | Line 42: | ||
| Next: XBEE FT232RL Chip Serial Ports Expand Board USB to TTL Adapt Base | Next: XBEE FT232RL Chip Serial Ports Expand Board USB to TTL Adapt Base | ||
| + | </ | ||
| + | |||
| + | jungti TX(1) i arduino 10, jungti rx(2) i arduino 11 | ||
| + | |||
| + | |||
| + | <code c> | ||
| + | #include < | ||
| + | |||
| + | SoftwareSerial mySerial(10, | ||
| + | |||
| + | void setup() { | ||
| + | // Open serial communications and wait for port to open: | ||
| + | Serial.begin(38400); | ||
| + | while (!Serial) { | ||
| + | ; // wait for serial port to connect. Needed for native USB port only | ||
| + | } | ||
| + | pinMode(LED_BUILTIN, | ||
| + | |||
| + | Serial.println(" | ||
| + | |||
| + | // set the data rate for the SoftwareSerial port | ||
| + | mySerial.begin(9600); | ||
| + | mySerial.println(" | ||
| + | } | ||
| + | |||
| + | void loop() { // run over and over | ||
| + | mySerial.println(" | ||
| + | digitalWrite(LED_BUILTIN, | ||
| + | delay(1000); | ||
| + | digitalWrite(LED_BUILTIN, | ||
| + | delay(1000); | ||
| + | /* | ||
| + | if (mySerial.available()) { | ||
| + | Serial.write(mySerial.read()); | ||
| + | } | ||
| + | if (Serial.available()) { | ||
| + | mySerial.write(Serial.read()); | ||
| + | } | ||
| + | */ | ||
| + | } | ||
| </ | </ | ||
arduino/bk3231.1502127979.txt.gz · Last modified: by aistis
