Giter Club home page Giter Club logo

Comments (10)

dooriya avatar dooriya commented on June 8, 2024

It works well in Windows with your sample code
serial-port-win
, will try to repro in macOS.

from azure-iot-developer-kit.

technoblogy avatar technoblogy commented on June 8, 2024

from azure-iot-developer-kit.

dooriya avatar dooriya commented on June 8, 2024

The root cause is that the underlying serial port software (screen) we depends on in macOS has limited read buffer. So if you want to read a long string from serial port, you need to split it into chunks.

from azure-iot-developer-kit.

technoblogy avatar technoblogy commented on June 8, 2024

Thank you for your reply. This is a bit of a showstopper for my application: I want to port my Lisp interpreter, uLisp, to the AZ3166. You interface to the Lisp REPL using the Arduino Serial Monitor:

http://www.ulisp.com/show?19XT

On other Arduino platforms this works fine; you can paste in Lisp programs and execute them. However, on the AZ3166 as soon as you try to paste in any significant program the Arduino IDE crashes or hangs up.

Why is this not a problem on other Arduino platforms?

Can I rewrite the serial interface to remove the restriction?

Any other suggestions? Thanks,David

from azure-iot-developer-kit.

technoblogy avatar technoblogy commented on June 8, 2024

Any more suggestions about this issue?

from azure-iot-developer-kit.

github-actions avatar github-actions commented on June 8, 2024

This issue has no recent activities, please take a look and provide updates for it.

from azure-iot-developer-kit.

technoblogy avatar technoblogy commented on June 8, 2024

Is there any progress on this?

As I said in a previous post, this isn't a problem with most other platforms supported by the Arduino IDE (for example, ATSAMD21, ATSAMD51, ESP32, nRF52840). My test program works fine on those.

It therefore must be possible to implement Serial in a way that doesn't impose a 384-character limit. Is there some way I can contribute to fixing this?

from azure-iot-developer-kit.

technoblogy avatar technoblogy commented on June 8, 2024

@dooriya any progress on this?

I tried increasing the buffer size by editing the line in BufferedSerial.h from:

BufferedSerial(PinName tx, PinName rx, uint32_t buf_size = 128, uint32_t tx_multiple = 4, const char* name=NULL, int sample_rate = 115200);

to:

BufferedSerial(PinName tx, PinName rx, uint32_t buf_size = 1024, uint32_t tx_multiple = 4, const char* name=NULL, int sample_rate = 115200);

but it didn't seem to help. Any other suggestions?

from azure-iot-developer-kit.

hellyzh avatar hellyzh commented on June 8, 2024

Normally the input will be shorter than 384 characters. You may need to split long string to chunks and limit each input to 384 characters as a work-around.

from azure-iot-developer-kit.

technoblogy avatar technoblogy commented on June 8, 2024

Thank you for the reply.

My input is not normally shorter than 384 characters, as I'm uploading Lisp programs, and I can't easily break them into chunks. One program may be more than 384 characters. So this essentially makes the MXChip IoT DevKit unusable for my application.

As I mentioned in an earlier message this isn't a problem with most other platforms supported by the Arduino IDE (for example, ATSAMD21, ATSAMD51, ESP32, nRF52840).

from azure-iot-developer-kit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.