1
0
mirror of git://sigrok.org/libserialport synced 2023-08-10 21:13:24 +03:00
Commit Graph

370 Commits

Author SHA1 Message Date
Uffe Jakobsen
ccd512d51c Implement FreeBSD OS-specific serial port detection and query 2015-02-15 21:28:15 +01:00
Martin Ling
f446cfbf65 windows: Fix restart of RX/error wait operation after reads.
This fixes bug #421.
2015-02-15 20:52:45 +01:00
Boris Gjenero
e31f2c6b8b Fix free() of uninitialized pointer.
Explicitly set port->usb_path to NULL, otherwise a free(port->usb_path)
can happen where port->usb_path is uninitialized.

This closes bug #512.
2014-12-05 18:42:43 +01:00
Aurelien Jacobs
b328a48b0f windows: Properly handle return value of SetupDiOpenDevRegKey().
This fixes bug #499.
2014-11-27 17:42:28 +01:00
Martin Ling
59182fbbbf linux: Check for BOTHER macro at configure time.
This fixes bug #363.
2014-11-01 18:36:09 +01:00
Janne Huttunen
ad7498553c Flush only the requested buffers
Fix the sp_flush() so that it flushes only the requested buffers
also in unix.
2014-10-12 21:38:03 +02:00
Bert Vermeulen
d66bbceaa7 Fix typos. 2014-10-05 02:38:35 +02:00
Martin Ling
78940e6921 windows: Fix compile issues with multiply or not defined GUIDs.
This fixes bug #416.
2014-09-25 23:04:06 +02:00
Aurelien Jacobs
6c444ade55 windows: Indentation (cosmetics only). 2014-09-24 12:54:36 +02:00
Aurelien Jacobs
7aeb6736bd windows: Fix various memory leaks.
This fixes bug #419.
2014-09-24 12:52:21 +02:00
Aurelien Jacobs
276ef1b92f Add SP_MODE_READ_WRITE enum value. 2014-09-20 21:24:31 +02:00
Uwe Hermann
eb82be98a7 README: Add URL to the libserialport website. 2014-09-07 19:31:23 +02:00
Uwe Hermann
a46ee5b4d7 README: Mention that only MinGW-w64 works (but not MinGW). 2014-09-07 19:27:02 +02:00
Michael B. Trausch
da8730199a windows: -no-undefined is required to make a DLL. 2014-09-07 19:18:22 +02:00
Michael B. Trausch
6692d8c13f windows: Add -lsetupapi when building for WIN32. 2014-09-07 19:18:19 +02:00
Michael B. Trausch
d179da05c0 windows: Include proper GUID defining header to fix build.
The initguid.h header must appear early or it does not have
an effect, at least on cross-build from Linux.
2014-09-07 18:51:04 +02:00
Aurelien Jacobs
653cef3ab1 linux: remove readlinkat() dependency 2014-09-04 20:13:55 +02:00
Aurelien Jacobs
546e9ae5c5 linux_termios: fix return types to actually match returned values
This fixes the following warning :

linux_termios.c: In function 'get_termios_get_ioctl':
linux_termios.c:42:2: warning: overflow in implicit constant conversion [-Woverflow]
  return TCGETS2;
  ^

This fixes bug #396.
2014-09-04 20:13:55 +02:00
Uwe Hermann
23ef3bf125 Fix Mac OS X build (untested). 2014-08-27 14:56:19 +02:00
Uwe Hermann
d38c7d2c70 Fix Windows build. 2014-08-27 14:53:19 +02:00
Martin Ling
0666ccc7ca linux: Fix warning by marking vid, pid variables unsigned. 2014-08-24 14:08:00 +01:00
Martin Ling
7f450f46bd Compile with -pedantic. 2014-08-24 14:06:21 +01:00
Martin Ling
c51b846eee linux: Define feature macros to get required functions.
This is needed to build with -std=c99.
2014-08-24 14:06:21 +01:00
Martin Ling
7890cef6cf Revise debug macros to work in strict C99. 2014-08-24 14:06:21 +01:00
Martin Ling
9caa2e86aa Specialise RETURN_VALUE macro into RETURN_{INT,STRING,POINTER}.
This avoids the need to pass the required format string on every
call and also eliminates the need for the non-standard typeof() call.
2014-08-24 13:31:20 +01:00
Antti Nykanen
79a8004637 libserialport.h.in: remove trailing commas in enum definitions
This makes it easier to use libserialport on projects that build with
the GCC -pedantic flag enabled.
2014-08-24 11:56:45 +01:00
Bert Vermeulen
942a6d349e Bump package version to 0.2.0. 2014-08-20 23:40:19 +02:00
Aurelien Jacobs
f3ccf157cb Rename sp_get_signals() parameter to avoid name clash with Qt headers. 2014-08-20 22:39:29 +02:00
Uwe Hermann
900904638b configure.ac: We no longer need to set WINVER explicitly.
Since we now require MinGW-w64, we no longer have to set WINVER manually,
since MinGW-w64 defaults to WINVER=0x0502 (which corresponds to
Windows Server 2003 SP1 / Windows XP SP2 apparently, which is fine for us).
2014-08-05 21:22:59 +02:00
Uwe Hermann
34906a229b windows.c: Remove MinGW workarounds, require MinGW-w64 instead.
We're switching from MinGW (i686-pc-mingw32.static in MXE)...

  http://mingw.org/

...to MinGW-w64 (i686-w64-mingw32.static in MXE):

  http://mingw-w64.sourceforge.net/

The latter is a fork which nowadays seems to be more active and also to
have a more complete set of win32 API headers and libs.

History:
http://sourceforge.net/p/mingw-w64/wiki2/History/

This closes bug #393.
2014-08-05 21:22:50 +02:00
Uwe Hermann
8eb18f7b5a windows.c: Define a bunch of stuff that's not in MinGW, yet.
Without these defineѕ the build fails with various (many) compile errors.
2014-07-31 23:14:35 +02:00
Uwe Hermann
9a8d04bca6 configure.ac: MinGW build fix (setting WINVER=0x0501).
Without this the build fails with:

  windows.c:40:43: error: 'WC_NO_BEST_FIT_CHARS' undeclared (first use in
  this function)
2014-07-31 23:11:40 +02:00
Uwe Hermann
5a8810e2b2 serialport.c: Fix an 'unused variable' compiler warning. 2014-07-31 23:09:24 +02:00
Marcus Comstedt
12056e2f75 Avoid use of struct serial_struct on systems which don't have it (Android)
This fixes bug #376.
2014-07-06 14:16:56 +02:00
Marcus Comstedt
5bd33b7c8b Don't use readlinkat if it does not exist
This fixes bug #377.
2014-07-06 14:15:46 +02:00
Aurelien Jacobs
970f279ae4 Introduce SP_API/SP_PRIV to mark visibility of functions. 2014-07-02 14:43:32 +02:00
Martin Ling
e4ce975a54 Fix build for platforms without enumeration & port metadata support. 2014-06-14 12:27:54 +01:00
Aurelien Jacobs
48a4076f69 Move list_ports() implementations to OS-specific files. 2014-06-14 01:28:49 +02:00
Aurelien Jacobs
235269990b Fix missing variable on macosx. 2014-06-13 23:47:45 +02:00
Bert Vermeulen
e59ecb3359 Ignore build leftovers. 2014-06-11 20:41:20 +02:00
Aurelien Jacobs
65172beffe Check bus:address and vid:pid validity. 2014-06-11 17:21:51 +02:00
Martin Ling
e33dcf90a0 Tidy up and split most OS-specific code to separate files. 2014-06-11 15:10:29 +01:00
Aurelien Jacobs
a93fb46888 Add new APIs to get some USB descriptor details for USB serial ports. 2014-06-10 23:51:11 +02:00
Aurelien Jacobs
98cac5d63e Remove the udev dependency and parse the /sys hierarchy instead. 2014-06-10 22:17:07 +02:00
Aurelien Jacobs
073c86bd07 Simplify Mac OS implementation of sp_list_ports(). 2014-06-10 22:17:07 +02:00
Aurelien Jacobs
f095f84164 Remove useless declaration. 2014-06-10 22:17:07 +02:00
Aurelien Jacobs
da2ede60e4 Remove duplicated include. 2014-06-10 22:16:46 +02:00
Aurelien Jacobs
8edf649caf Add format string support to RETURN_ERROR() and RETURN_FAIL(). 2014-06-02 12:08:54 +02:00
Uwe Hermann
41a6f28718 NEWS: Bump date. 2014-05-06 20:49:11 +02:00
Uwe Hermann
67765669d5 NEWS: Update for upcoming 0.1.0 release. 2014-05-05 02:09:11 +02:00