7 Segment Display problems with mBot and mBlock 2.2.1


#1

I have two MakeBlock 7 segment displays. I cannot get either of them to light up when connected to any port on the mBot and controlled with mBlock 2.2.1 (the latest Mac version). I’ve tried the usual solutions (ensure the Port is correct color, ensure the port number matches, tried various values in the input field, tried putting it inside a “forever” loop).

Has anyone gotten the 7 segment display working with an mBot?


#2

I have the 7 segment from the inventor kit connected to my mBot and it works fine.
Show us your mBlock code.


#3


#4

Ah! I was trying to use it connected via the 2.4G connection using a “When Flag is Clicked” program. When I tried uploading it to the mBot via Arduino mode it worked. When I went back and created a similar loop (with a slight delay so it wouldn’t overrun the serial buffer and crash mBlock) via 2.4G it didn’t work. This looks like an mBlock bug. I wonder if v3.0 will fix it when it is released for the Mac.


#5

I’ve heard from others that running certain items in a tight loop through the 2.4GHz serial can cause crashes. Adding in a .1 sec delay does do the trick most of the time but clearly this isn’t optimal. I’d love to see some of the bugs worked out too.
The bluetooth doesn’t seem to exhibit these issues but since the calls are all going out and back data does get dropped. For testing I usually keep the USB connected but uploading to arduino and running off-line is the best way to go.


#6

I’m teaching a weekend class for kids and using it connected is definitely the way to go. It allows interaction between the sprite and the bot, allows the code to be modified live, and allows far easier debugging. And the 2.4G is definitely the best option for the classroom, since each kids’ bot automatically connects to only their computer. It’s a bummer the 7-segment display won’t work in this mode, as I think it would be a fun thing to add to a bot.

Lots of things crash mBlock in a tight loop over 2.4G. Setting a servo position is a sure-fire way to crash without a tiny delay in there. The 7-segment display does it sometimes.

The code is purportedly available on github, but it looks like it hasn’t been updated in months so I haven’t bothered to try to build it.


#7

Yea, I’m doing a class on using mBot but I decided that I would structure the lessons around a little bit of connected activity with USB just to show the basics but switch to download and run sooner than later since that part is pretty solid; until you reach some of the major bugs in the mblock libraries. I’ll work around them for now but I have really wanted to try and address them myself in the github too but I just don’t have the time to work out the Scratch extension methodology. I do think we should post issues to github when we do find bugs and maybe someone that knows more will get to them.


#8

Let me know if you can figure out which github library corresponds to which Makeblock product.


#9

Hi, I’m having the same problem. I connected the 7-segment display to port 4 on mBot and it does nothing. I tested also in an Orion board and it worked If I loaded as a program but not if I tried to do it online from mBlock IDE… so it’s not a problem with the 7-seg display itself but, for some reason, it seens that it doesn’t work when I try to display something directly from the mBlock (I’ve tested with the last 3.2 version released two days ago)…
Any idea?


#10

I had it working with mBlock 3.1 by connecting it with a serial cable and selecting “Restore Firmware” on the mBot (and NOT selecting “Restore Default Program”). Haven’t tried 3.2 yet.


#11

Hello
Can I know the purpose of 7 segment ?
Is it necessary if I want to build a robot?
I saw a video, which use me 7 segment with every sensor but I don’t know why !
Can you help me ?
Thank you


#12