Trying to understand what can I use in mBlock > "Robots"


#1

Hello,
I’m writing here, because I have some problems to understand what can I really use in the Robots part of mBlock, for my mBot.

I’m really begining, and I have some problems with the English development vocabulary.
I know that I can change the language to French (yes, hello from France !), but the translation isn’t perfect too…

So I though it would be a good idea if someone could tell me if what I understand is ok, and could complete this, too. :blush:

1. So, first… I don’t see why we have these 2 possibilities.

I understand that the two are made to start the action, but “When on board button pressed” needs is a part of the mBot Program, isn’t it ?

2. What do you call “servo” ?

3. What can I make with this ?.. even in French, I don’t really understand…

4. I presume that all of this is used when we add new elements ?


for example, LED Matrix = show face ?
Could you help me to make the association with the different components ?

And… I would be very interested to understand how I could associate a camera to the mBot. I don’t see camera for mBot on Arduino store…

Well… a lot of questions… I have others, but I don’t want you to hate me with my first message on the forum ! :stuck_out_tongue:

I think that when I will have well understood everything, I’ll make documentation to help newbies like me… and a translation in French too… :yum:

Have a nice day !

Aurélie


#2

The mBot Program block will make the program start when the robot is turned on. The other block will wait until the button is pressed.

However, these are for the offline mode.

Short explanation: the robot has a default program installed. This listens to the commands of the remote control. It also listens to the commands from the program you run on your tablet / computer in Scratch - the programs which you begin with the green flag. Nice thing is that because the program runs on your computer, you dont need to upload it to the robot. You can also display information from the robot on the computer using the SAY block. That is called online mode.

When you use the offline mode, you need to connect the robot to the computer by USB. You need to start the program with one of the two blocks for the offline mode, Then you can compile and upload it to the robot. Attention: this will replace the default program, because the robot can only execute one program.
Advantage is that you dont need a connection to a computer to run the program.
To get back to the default program, you need to restore it through USB using the menu function “Restore default program”.

I recommend to start with the online more.

Servos are small motors.
All the other blocks you showed above are for additional parts which you can buy and connect to the robot.


#3

Hello Andreas,

Thank you for your answer :slight_smile:

I ever experimented the big stress of “nothing work ! how can I restore all !” on friday :grin:
And I would say that when we have to restore, it’s important to disconnect the battery from the robot too !
It made my computer restart, it made a big bug for me ! (on mac and on pc, I tried it at work too)

Well, now, it’s ok, I know how to do :slight_smile:

But for the moment, I can’t make the robot work direct from my computer. Maybe I do something wrong.
When I put the block with the flag, and that I click on the flag, it does’nt seem to work.

For the servos… I don’t remember that I have other motors than the classic ones (on left and right). I don’t see them on the documentation of the mBot.
So I’m not sure that I can do something with that :

Well… for the moment, I wrote this and it works.
But I am surprised that there is not “switch… case” in the mBlock. It makes a lot of “if”.


#4

Greetings!

  1. The mBot Program header block allows you to upload the program to the mBot. The other header block is normally used as a subroutine, but I was never able to get it to work properly when the mBot is in standalone mode. Likely it is meant for use over WiFi or Bluetooth when the program is running on the computer.

  2. A servo is a small motor driven device that can be connected to pushrods or gears to move a hinge, turn a gear, etc. (Wikipedia link

  3. If you have the LED strip (a strip of LEDs that can be controlled individually), this block allows you to turn each LED on or off as well as setting the color of the LED.

  4. Each of the blocks you reference controls a device on the robot. Many of the devices will need to be purchased separately. For example, the show face, show time, and show drawing blocks are used for the LED panel. The sensor blocks are (mostly) for separately purchased devices.
    The mBot has on an onboard timer, light sensor, a line follower sensor, and an ultrasonic sensor, as well as a buzzer, an infrared emitter/transmitter, and a pair of LEDs (do not confuse these with the LED strip).

I’ve written a short ebook (link) aimed at teaching the fundamentals of mBot programming that you may or may not find useful. Unfortunately it is only in English at this time but I’m active on the forums and will be happy to answer any questions you might have.

With regard to associating a camera to the mBot, what are you trying to do?

Bonne chance mon ami!


#5

It is important to remember that mBlock is based on the Scratch 2.0 offline editor and only provides the Robot extensions. The choice to avoid a case statement was that of the Scratch team. :slight_smile:


#6