Show /dev/tty.* devices on macOS. (#883)

* Show /dev/tty.* devices on macOS.

* Add PR #883 to changelog.
ms-windows-layout-fix
Mooneer Salem 2025-05-15 09:07:05 -05:00 committed by GitHub
parent 943ebab428
commit d405ee770c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 11 additions and 8 deletions

View File

@ -918,6 +918,7 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes
* Update default 80 and 160m calling frequencies. (PR #831)
* Shorten PulseAudio/pipewire app name. (PR #843)
* Hamlib: support CAT PTT via the Data port instead of Mic (needed for some older radios). (PR #875)
* macOS: Show /dev/tty.* devices in CAT/PTT options. (PR #883)
3. Build system:
* Allow overriding the version tag when building. (PR #727)
* Update wxWidgets to 3.2.8. (PR #861)

View File

@ -1038,11 +1038,12 @@ void EasySetupDialog::updateHamlibDevices_()
#if defined(__FreeBSD__) || defined(__WXOSX__)
glob_t gl;
#ifdef __FreeBSD__
if(glob("/dev/tty*", GLOB_MARK, NULL, &gl)==0) {
#if defined(__FreeBSD__)
if(glob("/dev/tty*", GLOB_MARK, NULL, &gl)==0 ||
#else
if(glob("/dev/cu.*", GLOB_MARK, NULL, &gl)==0) {
#endif
if(glob("/dev/tty.*", GLOB_MARK, NULL, &gl)==0 ||
#endif // defined(__FreeBSD__)
glob("/dev/cu.*", GLOB_MARK, NULL, &gl)==0) {
for(unsigned int i=0; i<gl.gl_pathc; i++) {
if(gl.gl_pathv[i][strlen(gl.gl_pathv[i])-1]=='/')
continue;

View File

@ -395,11 +395,12 @@ void ComPortsDlg::populatePortList()
#if defined(__FreeBSD__) || defined(__WXOSX__)
glob_t gl;
#ifdef __FreeBSD__
if(glob("/dev/tty*", GLOB_MARK, NULL, &gl)==0) {
#if defined(__FreeBSD__)
if(glob("/dev/tty*", GLOB_MARK, NULL, &gl)==0 ||
#else
if(glob("/dev/cu.*", GLOB_MARK, NULL, &gl)==0) {
#endif
if(glob("/dev/tty.*", GLOB_MARK, NULL, &gl)==0 ||
#endif // defined(__FreeBSD__)
glob("/dev/cu.*", GLOB_MARK, NULL, &gl)==0) {
for(unsigned int i=0; i<gl.gl_pathc; i++) {
if(gl.gl_pathv[i][strlen(gl.gl_pathv[i])-1]=='/')
continue;