Skip to content
Parallax Learn

Parallax Learn

  • Welcome
  • Tutorials
        • Tutorial Series head tag

          Tutorial Series
        • Tutorial Series

          The special, classroom-ready series pages are organized collections of tutorials for our most popular hardware and/or languages. The tutorials for each topic are conveniently accessible from a single page, shown in the order it is recommended that they be completed.
        • Robotics Series Head tag

          Robotics Series
        • Robotics Series

          • Artificial Intelligence
          • Cybersecurity: Radio Data tutorialCybersecurity
          • cyber:bot + Python
          • cyber:bot + MakeCode
          • Boe-Bot Tutorial SeriesBoe-Bot
          • Arduino Shield-Bot
          • ActivityBot with C TutorialsActivityBot + C
          • ActivityBot with BlocklyProp Tutorial SeriesActivityBot + BlocklyProp
          • Scribbler 3 Tutorial SeriesScribbler 3
        • Electronics & Programming Series Head tag

          Electronics & Programming Series
          • BS2 Board of Education Tutorial SeriesBS2 Board of Education
          • Propeller C-Language BasicsPropeller C Basics
          • FLiP Try-It Kit C Tutorial SeriesFLiP Try-It Kit + C
          • FLiP Try-It Kit BlocklyProp TutorialsFLiP Try-It Kit + BlocklyProp
          • Badge WX Tutorial SeriesBadge WX
          • Propeller BlocklyProp Basics and ProjectsPropeller BlocklyProp Basics
          • View All Tutorial Series »
        • Browse Tutorials
        • Browse Tutorials

          Individual tutorials sorted by robot or kit, and language.
        • By Robot or Kit
          • ActivityBot
          • SumoBot WX
          • Boe-Bot
          • Shield-Bot
          • cyber:bot
          • Badge WX
          • ELEV-8
          • ARLO
        • By Language
        • By Language

          • Propeller C
          • Arduino
          • BlocklyProp
          • PBASIC
          • Python
          • MakeCode
          • View All Tutorials »
  • Educators
  • Reference
  • Downloads
  • Home
  • All Courses
  • Cybersecurity: Malformed Packet Attacks & Defenses

Cybersecurity: Malformed Packet Attacks & Defenses

Test the Radio Connection to the cyber:bot

Let’s first make sure the sender micro:bit and receiver micro:bit in the cyber:bot work as expected with normal packets.  Since we are going to leave the cyber:bot tethered with USB, we’ll use some short distance maneuvers with low speeds and short run times.   

  • Plug the battery pack’s plug into the cyber:bot board’s battery jack.
  • Set the cyber:bot board’s PWR switch to 2.
  • Click the Show serial buttons in both python.microbit.org editors.
  • If the left speed prompt does not appear in the sender Serial terminal connected to the sender micro:bit, try clicking Hide serial, and then Show serial again.
  • Type these responses to the prompts, and remember to press Enter after typing each value:
    • Enter left speed: 25
    • Enter right speed: 25
    • Enter ms to run: 500
  • Verify that the cyber:bot moved forward slowly for a half a second.
  • Decide on another maneuver, type in the prompts, and verify that the cyber:bot maneuvers as expected.

Now it is time to see the effect that a malformed packet can have.  

  • Type these responses to the prompts, and remember to press Enter after typing each value:
    • Enter left speed: 25
    • Enter right speed: 25
    • Enter ms to run: -1
  • Did the cyber:bot robot’s micro:bit display an error?  
  • Did an exception appear in the terminal connected to the cyber:bot robot’s receiver micro:bit?

If your micro:bit was not tethered, it would be stuck until a human came and restarted it by pressing and releasing the micro:bit module’s reset button! That is not always possible in a competition, but you can do it now.

  • On the cyber:bot, locate the micro:bit module’s reset button; it’s on the bottom side between the USB and battery sockets.
  • Press and release it to restart the receiver micro:bit script execution.
  • Type a maneuver into the Serial terminal connected to the sender micro:bit, and verify that you can control the cyber:bot robot’s motion again.

 


Printer-friendly version
Malformed Packets and Keyboard cyber:bot Control
Prev
Try This: Add Exception Handling
Next

DISCUSSION FORUMS | PARALLAX INC. STORE

About | Terms of Use | Feedback: learn@parallax.com | Copyright©Parallax Inc. 2024

© 2025 Parallax Learn • Built with GeneratePress