Connecting via Bluetooth on OS X


#1

Hi All,

Here are the steps for connecting to Bluetooth on the Mac. This works under OS X El Capitan, but the steps should be the same for earlier versions:

  1. Pair the device via the Bluetooth preferences. It will show up as Makeblock. After pairing it will show as Not Connected and this is normal. Pairing the device makes it available, but it is not connected to an application.
  2. Open mBlock and select the Connect menu followed by selecting the Serial Port submenu.
  3. Select the /dev/tty.Makeblock-ELETSPP device.

That should get you connected to mBlock. You cannot upload programs for autonomous operations via Bluetooth or Wifi. They can’t access the avrdude programmer on board, so you will have to use the USB cable for uploading programs for autonomous operations. You can, however, run programs from within mBlock in this fashion. I haven’t gotten to using the Arduino IDE yet, but I suspect it amounts to sending commands over the serial port.

Hope this helps someone out.

P.S. Thanks to @tec_support for helping me work this out.


Bluetooth problems
Can't get Mbot to move!
#2

Thanks! I was about to go insane trying to upload via Bluetooth. I wish this was somewhere in the documentation.

Btw, after loading a program via USB cable, the mBot starts to execute but the cable gets in the way. When I unplug the cable, this stops the robot. Am I missing a step?


#3

You need to power up the robot which means you need batteries connected and power switch fliped on.

mBots with programs uploaded can run in its own, but since the USB cable no longer provides power, the robot need to have its juice elsewhere.


#4

Thanks for the tip! My batteries are attached and the power is on (with LED lights on, too). Looks like I need new batteries.


#5

In fact, on hindsight, the Getting Started page seems to imply that you can do that via Bluetooth: http://learn.makeblock.com/getting-started-programming-with-mblock/

I hope this gets fixed to help us avoid sleepless nights! :slight_smile:


#6

Hi Rubencanlas,

It is true that you cannot upload programs for autonomous operation via Bluetooth or Wifi.
The bluetooth and Wifi connection is available for wireless program to do online debug. After you finished the online debug and want to upload the program into the mBot, then you need use USB cable to do the Upload.

For the other issue that "after loading a program via USB cable, the mBot starts to execute but the cable gets in the way. When I unplug the cable, this stops the robot. Am I missing a step?"
Is it fixed after you changed the battery?
If no, please temporarily move the bluetooth module or 2.4G module from mCore and then upload the program again have a check.


#7

Update: A fresh set of batteries fixed it. mBot is running now.

Thanks, @tec_support!


#8

Hi chuckmcknight, thanks for your knowledge.
However, with following features,

.- Mac OS Sierra
.- MBlock 3.4.5

I hit the Connect —> Serial Port —> Makeblock-ELETSPP thousand times and it does not connect at all :frowning: Bluetooth keeps blinking, the option remains unchecked and the connection is not achieved.

:frowning: … my son is getting bored as I am aaaaabsolutely numb to make out of this expensive toy does something else than a remote controlled.

In general I am having plenty of troubles to get it working right with all its abilities


#9

Hi @urbina,

Hmm, this thread has the steps I use to connect via Bluetooth from macOS Sierra. The issue that I ran into was that connecting via Bluetooth was a two-step process in that I needed to first pair the device to the computer (making sure it wasn’t paired to another device), and then connecting mBlock to the computer as the thread mentions.

Try the steps listed in the thread to see if that helps out (I’m assuming that Bluetooth is turned on on your Mac).

Good luck!

Chuck


#10

Hi back !
Up now I’ve just tested it from my Macbook. With Sierra too and Makeblock 3.4.5. But right now I’ve tested from iMac, with Sierra too but Makeblock 3.4.1 and it seems to bee working fine.
However, it looks like this is not a flawless process. Subtle changes in the process of connecting USB --> uploading firmware —> disconnecting --> connecting via Bluetooth … makes difference. For instance, programming from my Macbook and then running the robot autonomous (for instance just playing with the ultrasonic sensor and say its distance) docs not work, has to be USB connected :frowning:

I’ll keep playing with it. Thanks for all.


#11

Hi there,
the thread you mentioned requires a successful pairing - but this seems impossible. As soon as the mBot is detected, Mac OS X Sierra proposes a pairing but there is only a short screen flash - after that pairing is said to be unsuccessful.
I’m using the latest mBlock version 3.4.8.
Windows - Sierra 1:0
Sylvain


#12

Hmm, at this point I can only point you to @tec_support. The steps I listed are the steps I follow to connect to my mBot via Bluetooth. :frowning:


#13

Hi SylvainPiren,

Is there any problem for you to pair the Mac OS Sierra to Bluetooth from other device instead of mBot?
Besides, you can also try if you can connect mBot Bluetooth to mobile APP successfully.


#14

Hi there,
no, but I don’t use Bluetooth very often.
As you can see, my mouse is connected. The mBot is detected and pairing is offered - when clicked a pairing number appears but automatically disappears within a second.


#15

Hi @SylvainPiren,

Here is a step-by-step that I just did to pair with my mBot:

  1. Make sure you have the latest version of mBlock (3.4.8 at the time of this writing).
  2. Connect the mBot via the USB cable.
  3. Go to the Connect menu and connect via the Serial Port item (mine uses /dev/tty.wchu410).
  4. Go to the Connect menu and upgrade your firmware.
  5. Disconnect the USB cable.
  6. Turn off the mBot.
  7. Close mBlock.
  8. Turn on the mBot.
  9. Go to the System Preferences -> Bluetooth panel.
  10. If you are offered a button to Pair, click the button.
  11. After you click the button, a brief dialog will flash and the Makeblock item will show Not Connected. This is normal and correct.
  12. Launch mBlock.
  13. Go to the Connect->Serial Port menu item and select /dev/.tty-Makeblock-ELETSPP.
  14. mBlock should show “Connected” in the title bar.
  15. Your System Preferences->Bluetooth pane show now also show that the mBot is connected.

The thing to keep in mind about Bluetooth is that it is a serial connection and mBlock does not automatically make that connection for you, unlike other devices such as the Magic Trackpad. That being the case, connecting with the mBot afterwards is merely a case of connecting via mBlock (see above).


#16

This works fine! Thank you very much.
Greetings from tiny Luxembourg.


#17

I’m glad to hear this resolved your issue!

Have a nice evening!

Chuck


#18