Robot Not a Dev? Buy Now
Not a Dev?

Misty Community Forum

Using Blockly with Misty

We are attempting to code Misty in a group setting using Blockly. Is there anyway to code her bumper sensors or utilize known faces currently on her system (ex. similar to the hello world tutorial have her recognize and respond differently to different known faces)?

Hi @rwines! At this point in time, we do not have the ability to interact with the bump sensors with the Blockly interface.

The easiest way to interact with these sensors is through a JavaScript Skill, here is some sample code on how to use the Bump Sensors and another one for using Face Recognition.

Let me know if that helps!

Thanks for your question, @rwines!

Coding Misty to do something in response to bump sensor input or face recognition messages requires first subscribing to those websocket streams, then parsing the data returned to look for an IsBumped value equaling true or PersonName value not equaling “unknown person”, and finally specifying what should be done when those conditions are met.

It is not possible to do this using Blockly because Blockly is not capable of handling websocket subscription at this time.

1 Like

Do you know if this is something that maybe added in the future? I’m going to be working with a similar group of teens in the spring and it will help with developing a program plan for the team.

At this time, we do not have plans in place to enhance the current functionality of Blockly :slightly_frowning_face:

If this is something that would be highly valuable for your use case, please submit it to our wishlist page! Misty’s Product Managers regularly monitor these requests and prioritize new features and functionality.

We also are considering simply sharing the Blockly code with the community and allowing them to run with it (though you can already largely do this since it is a webpage). If that is something you would be interested in, please also add that to the wishlist. Our team looks at that at least every week.

1 Like

@rwines While discussing your questions with folks here yesterday, I realized that the version of Blockly that was active on the website was actually outdated. That has now been fixed. The updated version is more robust with many more commands and a slightly different categorization scheme for the command toolbar. Wanted to alert you to that, since it sounds like you are working on some kind of lesson plan.

1 Like

With a link

We are having issues getting some of the code previously created using Blockly to run. Does the old code not translate to the new version?


Yes, I think you will have to generate some new code using new block configurations. Let us know how it goes.