Wykres commitów

167 Commity (master)

Autor SHA1 Wiadomość Data
alex f0dda6635c
FTDI: Fix baudrate setting on multiport devices
Correction of https://github.com/felHR85/UsbSerial/pull/274
2021-06-14 18:44:59 -07:00
green-green-avk f537d13ede
Merge pull request #270 from changwoo/ftdi-fix-usb-desc-endian
ftdi: Fix bcdDevice endian
2021-06-14 10:20:15 -07:00
Rob Riggs 6987b48e14 Find the proper control index to use for CDC devices with multiple devices classes present. This fixes the problem which prevented the library from working with STM32 Nucleo boards, among others. 2020-06-12 21:30:12 -05:00
Changwoo Ryu 37eac8d477 ftdi: Fix bcdDevice endian 2019-08-02 20:14:42 +09:00
Felipe Herranz 85c69b540d
Merge pull request #261 from winy57/contribution
Added setBreak method for CP21012 devices
2019-07-11 22:28:20 +02:00
Felipe Herranz b967da3c54
Merge pull request #262 from felHR85/rabidaudio-outputstream-fix
Added sync and streams read/write methods with offsets
2019-07-11 22:20:35 +02:00
Mickael Storck f4889f03cb Added setBreak method for CP21012 devices 2019-07-11 11:03:42 +02:00
Felipe Herranz d0232ed59a
Merge pull request #255 from TheSven73/fix-microchip-v2
Correctly determine Microchip pid:vid 04d8:000a device class
2019-07-07 23:46:12 +02:00
Felipe Herranz 538e2e0483 using syncWrite and syncRead new methods in Streams 2019-07-07 23:07:42 +02:00
Felipe Herranz 90396ab436 ftdi adapted for syncRead with offset method 2019-07-07 22:36:22 +02:00
Felipe Herranz fdfb9f1053 added syncRead with offset except in FTDI 2019-07-07 15:41:19 +02:00
Felipe Herranz 1e68f744c5 checking corner cases 2019-07-07 13:09:12 +02:00
Felipe Herranz 58bc4a47c3
Merge pull request #256 from felHR85/ftdi_sync_fix
Back to previous FTDI sync read method. Referenced in #241
2019-07-06 20:48:41 +02:00
Felipe Herranz 9f32a3b7e9 back to previous ftdi syncRead method 2019-07-03 23:36:44 +02:00
Sven Van Asbroeck 6180eb497c Correctly determine Microchip pid:vid 04d8:000a device class
According to the Linux kernel tree [1], Microchip pid:vid 04d8:000a
is generally a CDC ACM device, implemented by a demo firmware
application.

However, some vendors have re-used this vid:pid for other types of
firmware, emulating FTDI chips. The Linux kernel attempts to detect
such cases by matching on interface class/subclass/proto. If these
are ff/ff/00 it uses FTDI, otherwise CDC.

Mimic the Linux kernel's logic in determining whether the Microchip
device is CDC or FTDI.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=f08dea734844aa42ec57c229b0b73b3d7d21f810
2019-07-02 10:17:12 -04:00
Charles Julian Knight f52c67a134 added chunked stream methods 2019-06-26 13:39:01 -04:00
jani c0c5a2848c Added baud rates 1228800 and 2000000 to CH34X driver 2019-05-03 13:45:41 +03:00
Felipe Herranz 1e672fcb96
Merge pull request #243 from felHR85/ftdi_custom_baudrates
Ftdi custom baudrates
2019-05-01 19:47:00 +02:00
xiongyi 33fed5e09c add a setBreak interface to set the break feature, now tested on FTDI chip. 2019-04-26 10:03:48 +08:00
Felipe Herranz 5eddda99e9
Merge pull request #228 from t2t-sonbui/fix-write-thread
Fix Write Thread does not stop when close port
2019-04-06 00:39:47 +02:00
Felipe Herranz 41ced7c2a7
Merge pull request #229 from felHR85/cdc_fix
CDC Default Setup to CDC_CONTROL_LINE_ON
2019-04-06 00:03:02 +02:00
Felipe Herranz 8a0d9c8850 setBaudRated refactored 2019-04-05 23:40:08 +02:00
Felipe Herranz 9c51f4c19b cdc fix 2019-04-01 23:35:57 +02:00
Felipe Herranz 4108a6905e first version with custom baudrates 2019-03-31 22:10:21 +02:00
Felipe Herranz ac88abca1a added encoded baudrates in ftdi driver 2019-03-31 21:57:15 +02:00
sonbuidev 001e745a4a Fix Write Thread does not stop when close pory 2019-03-29 14:02:11 +07:00
phuongnam0907 5ec307966a
Update CP210xIds.java 2019-03-28 10:16:39 +07:00
Felipe Herranz da875752b1
Merge pull request #218 from Arneball/jellybeanapi
Reduce garbage by reading usb data right into the buffer on api >= jellybean
2019-03-09 20:55:26 +01:00
Felipe Herranz 1d7d0d9625
Deleted unused import 2019-03-09 02:05:12 +01:00
Raul Bache b5f7699a52 Runka 2019-03-04 14:26:35 +01:00
Raul Bache b98ea3278d Added proguard rules to the AAR-package 2019-02-26 11:04:13 +01:00
Felipe Herranz 234c83dd28
Merge pull request #212 from Arneball/reuseempty
Reuse same instance of byte array when the destination array is empty
2019-02-23 19:00:16 +01:00
Felipe Herranz af18d10953
Removed unused import 2019-02-23 13:21:38 +01:00
Raul Bache b0f2fd2543 Removed "always-null" parameter 2019-02-20 10:04:23 +01:00
Arneball aeb1227fa2 Reuse same instance of byte array when the destination array is empty
Also using System.arrayCopy in loop instead of manual copying
2019-02-19 14:16:44 +01:00
Raul Bache d874292505 Removed unneccesary classes and made a memory and cpu optimization
After this commit, vendor-product-tuples are stored as longs internally.
This way heap size is conserved and specialized classes are omitted.

This might not be a big deal desktop applications, but for Android,
every bit counts.

The public api is unchanged

Added test to verify that things did not break
2019-02-18 14:52:06 +01:00
Felipe Herranz 04db5825c0 solving issue disconnecting one device with multiple serial ports 2019-01-30 23:47:16 +01:00
Felipe Herranz dc94ea5879 always recognize other people help 2019-01-27 19:22:56 +01:00
Felipe Herranz b5863e22cb changed protocol buffer 2019-01-27 18:31:30 +01:00
Pawit Pornkitprasan f25cc0ab7b
cp210x: Add support for "Windows Update" PID
There are certain PID CP210x devices can be set to to allow Windows to
automatically download drivers from Windows Update. This patch adds
support for those PIDs.

Reference: https://www.silabs.com/community/interface/knowledge-base.entry.html/2016/12/30/downloading_cp210xd-ek07
2019-01-23 19:29:38 +07:00
Felipe Herranz 7db4e625d3
Merge pull request #198 from felHR85/cdc_changes
Line off when starting CDC driver
2019-01-19 20:07:45 +01:00
Felipe Herranz 1030409eb2
Merge pull request #199 from felHR85/cp2102_bug
Fixes for databits, parity and stopbits in CP2102
2019-01-19 19:58:14 +01:00
Felipe Herranz 3c839efd2c
Merge pull request #196 from felHR85/cp2012_improvs
Purging CP2102 when closing
2019-01-19 19:44:28 +01:00
Felipe Herranz 8ee110590d buffer variables to final 2019-01-19 18:21:59 +01:00
Felipe Herranz 3ad63c9311
Merge branch 'master' into okio 2019-01-19 17:30:42 +01:00
Felipe Herranz d43e1a2edb deleted comment 2019-01-19 17:27:58 +01:00
Raul Bache f4a4bd95d0 Refactored so that all common thread methods are handled in a base class
After this commit, common functionality for threads are gathered in a base class.
Less code, removed AtomicBoolean since it can be replaced with a volatile boolean, eliminating an allocation

Some members are made final
2019-01-15 19:53:02 +01:00
Felipe Herranz e41b04b906 line off when starting CDC driver 2019-01-12 19:35:25 +01:00
Felipe Herranz e80893539a purging when closing 2019-01-12 13:35:03 +01:00
Felipe Herranz e99d6b8d56 fixes for databits, parity and stopbits 2019-01-11 20:04:57 +01:00