element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
microbit
  • Learn
  • Learning Center
  • STEM Academy
  • microbit
  • More
  • Cancel
microbit
microbit Forum Some garbled serial comms from Micro:bit
  • Blog
  • Forum
  • Documents
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join microbit to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Suggested Answer
  • Replies 7 replies
  • Answers 1 answer
  • Subscribers 48 subscribers
  • Views 1988 views
  • Users 0 members are here
Related

Some garbled serial comms from Micro:bit

pmulvey
pmulvey over 1 year ago

My Serial writes are garbled when sent out to TeraTerm terminal program but Ok when viewed on the Serial monitor. Characters get dropped. This is quite useless as I want my class to receive the data in Python on the PC. I get this in both micro:bit Python editor and MS Makecode. I have used different micro:bits on different PCs, same result.

I tried Mu Editor and the micro:bit sends data across the serial port perfectly. I'm using V2. Is there an issue with the firmware used by MS Makecode and micro:bit Python editor?

I wrote a short Python program to read the serial port on the PC and I get the same results as with TeraTerm i.e. dropped characters, about 10% only, no major garbling.

 

  • Sign in to reply
  • Cancel

Top Replies

  • pmulvey
    pmulvey over 1 year ago +4 suggested
    Finally an answer: Thanks for contacting the Micro:bit Educational Foundation. When a WebUSB connection is used to send a program directly to micro:bit, MakeCode and the Python Editor stay connected…
  • Gough Lui
    Gough Lui over 1 year ago +2
    Are you sure you are matching the correct baud-rate, parity, bit-length and stop-bits? This needs to match what is used by the program running on the Micro:bit and should match whatever serial monitor…
  • pmulvey
    pmulvey over 1 year ago in reply to Gough Lui +1
    Later I will prepare a full report of what is happening and put code up here etc.
Parents
  • pmulvey
    0 pmulvey over 1 year ago
    Finally an answer:
    Thanks for contacting the Micro:bit Educational Foundation.
    When a WebUSB connection is used to send a program directly to micro:bit, MakeCode and the Python Editor stay connected and ready for incoming serial data.
    With a serial terminal program connected, for some reason an occasional character still finds it's way to WebUSB.
    ​
    Use the three dots menu on the Download/send to micro:bit button to Disconnect, or close the WebUSB connected browser tab.
    ​
    I have found this easy to forget. It's taken a while, but I finally now do think "shut MakeCode" when serial is misbehaving!
    For the same reason, having more than one tab with MakeCode or the Python Editor open can lead to errors.
    • Cancel
    • Vote Up +4 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Reply
  • pmulvey
    0 pmulvey over 1 year ago
    Finally an answer:
    Thanks for contacting the Micro:bit Educational Foundation.
    When a WebUSB connection is used to send a program directly to micro:bit, MakeCode and the Python Editor stay connected and ready for incoming serial data.
    With a serial terminal program connected, for some reason an occasional character still finds it's way to WebUSB.
    ​
    Use the three dots menu on the Download/send to micro:bit button to Disconnect, or close the WebUSB connected browser tab.
    ​
    I have found this easy to forget. It's taken a while, but I finally now do think "shut MakeCode" when serial is misbehaving!
    For the same reason, having more than one tab with MakeCode or the Python Editor open can lead to errors.
    • Cancel
    • Vote Up +4 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Children
  • baldengineer
    0 baldengineer over 1 year ago in reply to pmulvey

    That's a really good tip (and one I would have never thought of!)

    Thanks for sharing your finding.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube