Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raspberry Pi hardware serial is not seen by the serial module #246

Open
siteswapjuggler opened this issue Aug 23, 2024 · 4 comments
Open

Comments

@siteswapjuggler
Copy link

Environment

  • OS: Rapsberry Pi 4
  • Version: Raspbian Buster

Describe the bug
It's beetween a bug and feature request actually. I try to connect with a teensy via GPIO14/GPIO15 UART. I'm sure of the setting as it works perfectly with a python script but the serial port doesn't appear in Chataigne.

To Reproduce
Steps to reproduce the behavior:

  1. setup the RPi serial port
  2. run Chataigne
  3. create a serial port object
  4. the serial port doesn't appear in the dropdown menu

Expected behavior
Get the serial port in the dropdown menu either the dynamic link '/dev/serial0' or the device tree adress '/dev/ttyAMA0'

Additional context
Actually I suspect that the filter, filters out those result because I can see '/dev/ttyS0' (wich is the serial path when used for the terminal) it can also see the Teensy USB (with the teensy descriptor) but it cannot the hardware port as specified above.

This will be used in an installation by october, I can work on it if and suggest a push request if you point me the file to work on with. Anyhow no urgency as I can use USB as a replacement ;)

Have a nice day

@benkuper
Copy link
Owner

Hey sylvain, long time no see ;)
You will find the code in the Juce_serial repository. It's using wjwood's serial code but it's fully integrated in the repo so you can check that there. There is a Linux specific file there.

Let me know how it goes!
Cheers

@siteswapjuggler
Copy link
Author

Hi Ben, long time no see indeed :) I'll have a look as soon as possible. Thanks a lot for this quick answer :)

Cheers

@siteswapjuggler
Copy link
Author

Evening,

so as far as I can tell the answer would be in this file : https://github.com/benkuper/juce_serial/blob/398c9b30c463c4547ca0b47bc5bc116f36fb5466/lib/serial/impl/list_ports/list_ports_linux.cc#L2

after line 302, we can add :
search_globs.push_back("/dev/serial*");
search_globs.push_back("/dev/ttyAMA*");

By the way I think I can hack the system without even recompiling anything just by adding a dynamic link which math one of the patterns already present in the code :)

Thanks a lot for your help.

@siteswapjuggler
Copy link
Author

Tell me if you prefer for me to transfer or complete an issue on the jusce_serial. By the way I choose not to mess with a pull request as long as I don't have the full compilation workflow to test the modification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants