SOLVED: "play tone" take about 5 seconds per note


#1

Hi,

I’m using mBlock_v3.2.2 on MacOSX 10.11.3 with mBot, I have a strange issue with playing tone. The time from playing a note after another have a delay of 5 seconds:

Is it just me having the issue or do I something wrong? Doesn’t matter if I run this as “mBot Program” or not, direct USB attached or bluetooth

Cheers,
Thorsten


#2

I’m not getting the same result. The panda is giving me sub-second times. One thing though, you might want to use the reset timer and timer blocks from the Robot palette instead of the Scratch blocks which won’t compile in an mBot program.

I would suggest upgrading the firmware and resetting the default program to clean out the flash memory and then try again.


#3

Thanks @chuckmcknight for quick answer. I tried this already, update firmware and uploaded latest default program, still the same issue. Here is a “mBot Program”

when run from mBlock, issue is the same, delay of about 5 seconds, you can see this also from the serial communication protocol, timestamp is about 5 seconds per command:

3-4 18:6:54.91 > ff 55 07 00 02 22 06 01 7d 00 3-4 18:6:59.156 > ff 55 07 00 02 22 4a 01 fa 00 3-4 18:7:4.222 > ff 55 07 00 02 22 5d 01 7d 00 3-4 18:7:9.289 > ff 55 05 00 02 22 00 00

When compiling and uploading to Arduino, this is just working as expected. So it doesn’t seems to be a firmware / hardware issue with mBot, but seems to be related to mBlock IDE.


#4

Hmm, that’s bizarre. Does the Arduino code look like the ones below?


#5

Yes, the code looks similar. If I upload the code to mBot the execution time is correct. So seems to be related to transmitting via serial protocol. Try to run the same by double click the “mBot Program”.

I’ve tested same on another system with Win10 / mBlock_v3.2.2 with same behavior.


#6

Hi @Qube2,

I ran the following program (see the list on the stage for the times) connected via USB

And connected via 2.4GHz WiFi.

I did upgrade the firmware before running the programs just to be sure that I was starting with a clean system. Not sure if this sheds any light on your issue though. :frowning:


#7

Hmm, really weird. :confused: I’ve checked that I have latest FW version (V1.20101 from 12/29/2014) and flashed again, nothing changed. I confirmed within the FW that this command do not reply via serial back to mBlock, so the IDE is responsible for timing of the buzzer sound.

As it doesn’t work on my systems but on yours, maybe the settings of the locale (date/time format and/or timezone) might be the influencing factor. I will try to check this later.


#8

SOLVED! The firmware version coming with latest version of mBlock is pretty old. I’ve downloaded the latest firmware (V06.01.104 from 03/14/2016) from GIT repository (https://github.com/Makeblock-official/Makeblock-Libraries) and flash it to mBot, now the delay between the playing the nodes is solved. :thumbsup:

From serial protocol you can see that the mBot is now reply when done:

3-18 11:6:32.817 > ff 55 07 00 02 22 06 01 f4 01
3-18 11:6:33.491 < ff 55 0d 0a
3-18 11:6:33.518 > ff 55 07 00 02 22 f7 00 f4 01
3-18 11:6:34.191 < ff 55 0d 0a
3-18 11:6:34.215 > ff 55 07 00 02 22 06 01 e8 03
3-18 11:6:35.532 < ff 55 0d 0a

#9

Hi,
I have same problem and I upload the new firmata. But the problem is not solved.

Any other suggestions?
by the way I am using Mac .