Coder Social home page Coder Social logo

Windows: Set DTS via setCommState about go-serial HOT 5 CLOSED

bugst avatar bugst commented on September 27, 2024
Windows: Set DTS via setCommState

from go-serial.

Comments (5)

niondir avatar niondir commented on September 27, 2024

I created a pull request. I hope it gets integrated.

Anyway, I have the feeling this lib is not maintained actively but seems to be the best alternative to deal with serial ports.
I will continue to maintain a Fork on https://github.com/Lobaro/go-serial where even other features will get merged like the non-blocking operation.
We deal a lot with embedded Hardware and serial ports and rely on a feature rich, cross OS serial lib.

from go-serial.

cmaglie avatar cmaglie commented on September 27, 2024

hi @niondir,

thanks for the PR, may I ask you to post an example that shows the problem solved by the PR?
This will surely accelerate the integration.

Anyway, I have the feeling this lib is not maintained actively but seems to be the best alternative to deal with serial ports.
I will continue to maintain a Fork on https://github.com/Lobaro/go-serial where even other features will get merged like the non-blocking operation.

I'm actively maintaining this library, together with other valuable contributors like @albenik or @jcw, but really a lot of people contributed. Sometimes I'm slow to merge new features or give feedback, that's true, unfortunately time is always a scarce resource. BTW I'm much more reactive for bugfixes.

This library is used inside the Arduino Create Agent and a regression may potentially affect hundreds of users, so my priority is about stability and cross-os compatibility that's why, usually, I need more time to carefully test new contributions that touches the core of the library (like for example #33).

I'm working also on a branch that adds an automated test-suite to check for regressions, that will surely give a boost in accepting new feature contributions.

from go-serial.

niondir avatar niondir commented on September 27, 2024

Thanks for the quick response.

The example is what I wrote in "Observation" above and in the comment next to the fix.

The real world problem I'm solving is the following:
DTR is used as the BOOT0 pin
RTS is used as the RESET pin
on a STM32l151CBA

To get into bootloader mode I need to set DTR=false while resetting with a raising RTS flank: RTS=true (low) -> RTS=false (high)
This does not work with the current implementation since the DTR/BOOT pin is released when setting RTS, resulting in the chip starting into normal mode instead of bootloader mode.

from go-serial.

niondir avatar niondir commented on September 27, 2024

In arduino-create-agent there is only one place where SetDTR(false) is called in upload.go touchSerialPortAt1200bps(...). As far as I can see and what I have tested the PR should not affect the behavior at all.

from go-serial.

cmaglie avatar cmaglie commented on September 27, 2024

Fixed by #36, thank you!

from go-serial.

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.