<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[RemoteXY community — Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
		<link>https://forum.remotexy.com/viewtopic.php?id=1770</link>
		<atom:link href="https://forum.remotexy.com/extern.php?action=feed&amp;tid=1770&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in Problem connecting via bluetooth to DFRobot Romeo BLE board.]]></description>
		<lastBuildDate>Tue, 12 Mar 2024 13:26:04 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
			<link>https://forum.remotexy.com/viewtopic.php?pid=5423#p5423</link>
			<description><![CDATA[<p>I tried the code that you sent me and I have the same problem that I had initially, that the bluetooth device does not appear so I can connect through the RemoteXY app. Attached image.</p><br /><p><a target="_blank" href="https://ibb.co/mCNvmYW"><span class="postimg"><img src="https://i.ibb.co/N6T1XkB/Foto.png" alt="https://i.ibb.co/N6T1XkB/Foto.png" /></span></a></p><br /><p>This link explains how Bluetooth communication works with Romeo plates. It might be of some use.</p><p><a target="_blank" href="https://wiki.dfrobot.com/Bluno_SKU_DFR0267#Wireless_Programming_via_BLE">https://wiki.dfrobot.com/Bluno_SKU_DFR0 … ng_via_BLE</a></p>]]></description>
			<author><![CDATA[null@example.com (KoNGPuTeR)]]></author>
			<pubDate>Tue, 12 Mar 2024 13:26:04 +0000</pubDate>
			<guid>https://forum.remotexy.com/viewtopic.php?pid=5423#p5423</guid>
		</item>
		<item>
			<title><![CDATA[Re: Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
			<link>https://forum.remotexy.com/viewtopic.php?pid=5416#p5416</link>
			<description><![CDATA[<p>Fine. I see that the command <em>Serial.begin(115200);</em> called in the <em>setup()</em> function initializes the Bluetooth connection. But the same command can initialize communication with a PC in order to receive information in the terminal log. What is the difference?<br />Try the following code. This code initializes the <em>Serial </em>in the <em>setup()</em> function.<br /></p><div class="codebox"><pre><code>#include &lt;RemoteXY.h&gt;


// RemoteXY configurate  
#pragma pack(push, 1)
uint8_t RemoteXY_CONF[] =
  { 255,1,0,1,0,27,0,10,13,2,
  1,0,9,9,46,46,6,7,50,50,
  2,31,88,0,65,4,62,16,31,31,
  14,62,35,35 };
  
// this structure defines all the variables and events of your control interface 
struct {

    // input variables
  uint8_t button_1; // =1 if button pressed, else =0 

    // output variables
  uint8_t led_1_r; // =0..255 LED Red brightness 

    // other variable
  uint8_t connect_flag;  // =1 if wire connected, else =0 

} RemoteXY;
#pragma pack(pop)



/////////////////////////////////////////////
//           END RemoteXY include          //
/////////////////////////////////////////////


CRemoteXY *remotexy;

void setup() 
{

  Serial.begin(115200);
  remotexy = new CRemoteXY (
    RemoteXY_CONF_PROGMEM, 
    &amp;RemoteXY, 
    &amp;Serial
  ); 
  
  
  // TODO you setup code
  
}

void loop()        
{ 
  remotexy-&gt;handler ();
  
  if (RemoteXY.button_1)  RemoteXY.led_1_r = 255;
  else RemoteXY.led_1_r = 0;
  
  // TODO you loop code
  // use the RemoteXY structure for data transfer
  // do not call delay() 


}</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (remotexy)]]></author>
			<pubDate>Sun, 10 Mar 2024 06:40:34 +0000</pubDate>
			<guid>https://forum.remotexy.com/viewtopic.php?pid=5416#p5416</guid>
		</item>
		<item>
			<title><![CDATA[Re: Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
			<link>https://forum.remotexy.com/viewtopic.php?pid=5412#p5412</link>
			<description><![CDATA[<p>Thank you very much for the clarification.</p><p>I am sending you a basic example of serial communication that works perfectly with the Romeo board, as you can see it is the typical example of bidirectional serial communication.</p><div class="codebox"><pre><code>void setup() {
  Serial.begin(115200);  //initial the Serial
}

void loop() {
  if (Serial.available())  {
    Serial.write(Serial.read());//send what has been received
    Serial.println();   //print line feed character
  }
}</code></pre></div><p>I also sent you the wiki page of the board that talks about BLE communication, that example is there.</p><p><a target="_blank" href="https://wiki.dfrobot.com/Bluno_SKU_DFR0267#Wireless_Programming_via_BLE">https://wiki.dfrobot.com/Bluno_SKU_DFR0 … ng_via_BLE</a></p><p>I also attach a program that I wrote to be able to connect said board (mounted on a MiniQ robot) to be controlled from Blynk Legacy (which no longer exists).</p><div class="codebox"><pre><code>// PROGRAMA PARA USO CON ROBOT MINIQ ROMEO
#include &lt;BlynkSimpleSerialBLE.h&gt;

char auth[] = &quot;&lt;codigo autentificacion&gt;&quot;;

int E1 = 5;     // Control Velocidad Motor 1
int E2 = 6;     // Control Velocidad Motor 2
int M1 = 4;     // Control Direccion Motor 1
int M2 = 7;     // Control Direccion Motor 2

int v = 100;
int vg = 50;

void setup() { 
  int i;
  for (i = 4; i &lt;= 7; i++)
    pinMode(i, OUTPUT);  
  Serial.begin(115200);
  Blynk.begin(Serial, auth);
}

void loop() {
  Blynk.run();
}

// Utilizado desde blynk para recibir la velocidad desde un Slider
BLYNK_WRITE(V0) {
  v = param.asInt(); 
}

// Utilizado desde blynk para recibir posiciones desde un joystick
BLYNK_WRITE(V1) {
  int x = param[0].asInt();
  int y = param[1].asInt();

  if (x == 128 &amp;&amp; y == 128)
    Detener();
    
  if (y &gt; 148 &amp;&amp; x &gt; 108 &amp;&amp; x &lt; 148)
    Avanzar(v, v);
    
  else if (y &lt; 108 &amp;&amp; x &gt; 108 &amp;&amp; x &lt; 148)
    Retroceder(v, v);

  if (x &lt; 108 &amp;&amp; y &lt; 150)
    Izquierda(vg, vg);

  if (x &gt; 148 &amp;&amp; y &lt; 150)
    Derecha(vg, vg);
}

// Utilizado desde blynk para recibir la velocidad de giro desde un Slider
BLYNK_WRITE(V2) {
  vg = param.asInt(); 
}

void Detener() {
  digitalWrite(E1, LOW);   
  digitalWrite(E2, LOW);      
}

void Avanzar(char a, char b) {
  analogWrite (E1, a);
  digitalWrite(M1, HIGH);    
  analogWrite (E2, b);    
  digitalWrite(M2, HIGH);
}

void Retroceder(char a, char b) {
  analogWrite (E1, a);
  digitalWrite(M1, LOW);   
  analogWrite (E2, b);    
  digitalWrite(M2, LOW);
}

void Izquierda(char a, char b) {
  analogWrite (E1, a);
  digitalWrite(M1, LOW);    
  analogWrite (E2, b);    
  digitalWrite(M2, HIGH);
}

void Derecha(char a,char b) {
  analogWrite (E1, a);
  digitalWrite(M1, HIGH);    
  analogWrite (E2, b);    
  digitalWrite(M2, LOW);
}</code></pre></div><p>I hope you can help me, thank you very much.</p><p>Excuse my English, I am using a translator, my language is Spanish.</p>]]></description>
			<author><![CDATA[null@example.com (KoNGPuTeR)]]></author>
			<pubDate>Fri, 08 Mar 2024 13:01:45 +0000</pubDate>
			<guid>https://forum.remotexy.com/viewtopic.php?pid=5412#p5412</guid>
		</item>
		<item>
			<title><![CDATA[Re: Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
			<link>https://forum.remotexy.com/viewtopic.php?pid=5411#p5411</link>
			<description><![CDATA[<p>Sorry. I probably didn&#039;t explain it correctly.<br />Please share the example code for the Romeo BLE board that uses bluetooth. So that I can understand how bluetooth rises specifically for this board. And I&#039;ll try to give you the RemoteXY code.</p>]]></description>
			<author><![CDATA[null@example.com (remotexy)]]></author>
			<pubDate>Fri, 08 Mar 2024 09:39:55 +0000</pubDate>
			<guid>https://forum.remotexy.com/viewtopic.php?pid=5411#p5411</guid>
		</item>
		<item>
			<title><![CDATA[Re: Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
			<link>https://forum.remotexy.com/viewtopic.php?pid=5406#p5406</link>
			<description><![CDATA[<p>I&#039;ve used a basic example of turning LED 13 on and off.</p><div class="codebox"><pre><code>/*
   -- New project --
   
   This source code of graphical user interface 
   has been generated automatically by RemoteXY editor.
   To compile this code using RemoteXY library 3.1.10 or later version 
   download by link http://remotexy.com/en/library/
   To connect using RemoteXY mobile app by link http://remotexy.com/en/download/                   
     - for ANDROID 4.13.1 or later version;
     - for iOS 1.10.1 or later version;
    
   This source code is free software; you can redistribute it and/or
   modify it under the terms of the GNU Lesser General Public
   License as published by the Free Software Foundation; either
   version 2.1 of the License, or (at your option) any later version.    
*/

//////////////////////////////////////////////
//        RemoteXY include library          //
//////////////////////////////////////////////

// you can enable debug logging to Serial at 115200
//#define REMOTEXY__DEBUGLOG    

// RemoteXY select connection mode and include library 
#define REMOTEXY_MODE__HARDSERIAL

#include &lt;RemoteXY.h&gt;

// RemoteXY connection settings 
#define REMOTEXY_SERIAL Serial
#define REMOTEXY_SERIAL_SPEED 9600



// RemoteXY configurate  
#pragma pack(push, 1)
uint8_t RemoteXY_CONF[] =   // 36 bytes
  { 255,1,0,0,0,29,0,17,0,0,0,31,1,106,200,1,1,1,0,2,
  31,47,44,22,0,2,26,31,31,79,78,0,79,70,70,0 };
  
// this structure defines all the variables and events of your control interface 
struct {

    // input variables
  uint8_t switch_01; // =1 if switch ON and =0 if OFF

    // other variable
  uint8_t connect_flag;  // =1 if wire connected, else =0

} RemoteXY;
#pragma pack(pop)
 
/////////////////////////////////////////////
//           END RemoteXY include          //
/////////////////////////////////////////////

#define PIN_SWITCH_01 13


void setup() 
{
  RemoteXY_Init (); 
  
  pinMode (PIN_SWITCH_01, OUTPUT);
  
  // TODO you setup code
  
}

void loop() 
{ 
  RemoteXY_Handler ();
  
  digitalWrite(PIN_SWITCH_01, (RemoteXY.switch_01==0)?LOW:HIGH);
  
  // TODO you loop code
  // use the RemoteXY structure for data transfer
  // do not call delay(), use instead RemoteXY_delay() 


}</code></pre></div><p>As I said, the code compiles and loads well, but when I try to connect from the RemoteXY app the device does not appear to be able to connect.</p>]]></description>
			<author><![CDATA[null@example.com (KoNGPuTeR)]]></author>
			<pubDate>Thu, 07 Mar 2024 12:52:21 +0000</pubDate>
			<guid>https://forum.remotexy.com/viewtopic.php?pid=5406#p5406</guid>
		</item>
		<item>
			<title><![CDATA[Re: Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
			<link>https://forum.remotexy.com/viewtopic.php?pid=5403#p5403</link>
			<description><![CDATA[<p>The HM-10 firmware is configured so that the module does not require configuration and simply transmits data like a regular serial port.<br />Most likely, in the Romeo BLE 1.0 board, the CC2540 chip has a different firmware and requires some kind of preliminary configuration in order to transmit data as a serial port.<br />Can you share an example of sketch that works for you without RemoteXY?</p>]]></description>
			<author><![CDATA[null@example.com (remotexy)]]></author>
			<pubDate>Thu, 07 Mar 2024 05:25:22 +0000</pubDate>
			<guid>https://forum.remotexy.com/viewtopic.php?pid=5403#p5403</guid>
		</item>
		<item>
			<title><![CDATA[Problem connecting via bluetooth to DFRobot Romeo BLE board]]></title>
			<link>https://forum.remotexy.com/viewtopic.php?pid=5398#p5398</link>
			<description><![CDATA[<p>I am using the Romeo BLE 1.0 board that has a CC2540 bluetooth chip (similar to the one used by the HM-10 module) and an ATmega328P microcontroller with Arduino UNO bootloader.</p><p><a target="_blank" href="https://www.dfrobot.com/product-1176.html">https://www.dfrobot.com/product-1176.html</a></p><p>On the RemoteXY page I configure my project as an Arduino UNO with HM-10 module (since the CC2540 module does not exist) and I create an example of on and off for LED 13. I use the hardware serial port. Later I load said program on the board.</p><p>When trying to perform the search from the RemoteXY mobile app (iOS), the bluetooth device &quot;Bluno&quot; is not displayed, which corresponds to said board, which is why I cannot test said example on the board.</p><p>It should be noted that from the Bluetooth configuration of my iPhone and from other apps such as Bluetooth terminals I can view and connect perfectly to the Bluno device.</p><p>I hope you can help me, thanks.</p>]]></description>
			<author><![CDATA[null@example.com (KoNGPuTeR)]]></author>
			<pubDate>Wed, 06 Mar 2024 18:44:05 +0000</pubDate>
			<guid>https://forum.remotexy.com/viewtopic.php?pid=5398#p5398</guid>
		</item>
	</channel>
</rss>
