aboutsummaryrefslogtreecommitdiff
path: root/cores/arduino/USBAPI.h
AgeCommit message (Collapse)Author
2022-03-07rename arduino core dir to xinputHEADmasterHampusM
2022-02-22Merge tag '1.8.4' into upstream-1.8.4David Madison
2021-05-26Correct typos in comments and documentationper1234
2020-02-01Merge ArduinoCore-avr Release 1.8.2David Madison
2019-02-21Add XInput USB APIDavid Madison
2019-02-19Add XInput device and config descriptorsDavid Madison
2019-02-17Removed USB CDC SerialDavid Madison
This will compile but will NOT enumerate properly without a config descriptor. You've been warned...
2019-02-15Replace Serial with nullDavid Madison
Allows sketches using Serial to compile but discards all data
2018-12-11Add USBDevice.isSuspended()Gergely Nagy
Based on code originally by Rob van der Veer <rob.c.veer@gmail.com>, this adds USBDevice.isSuspended(), so user sketches can run custom code in their `loop` methods after checking if the device is suspended or not. Signed-off-by: Gergely Nagy <algernon@keyboard.io>
2017-05-16Add Print::availableForWriteEric Wieser
If available() is in the base Stream class, then availableForWrite() should be in the base Print class
2015-12-19Added Long USB RecvControl call for >64 bytesNicoHood
2015-09-20Fix CDC Serial buffer size determinationNico
2015-08-14Merge branch 'cdc-settings' of https://github.com/matthijskooijman/ArduinoCristian Maglie
2015-08-12Precised USB Endpoint definitionsNicoHood
2015-08-12Added 16 byte endpoint supportNicoHood
2015-07-31Add Serial_::availableForWrite().Peter Van Hoyweghen
This makes the CDC "Serial" object on the Leonardo and similar boards support this recently introduced method as well. The CDC code in the sam core is not changed.
2015-07-31Add Serial_::readBreak() to process SEND_BREAK requestsMatthijs Kooijman
This allows detecting when the USB host sends a break request and what the value of the request was. See the comments in USBAPI.h for details. This just modifies the avr core, not the sam core.
2015-07-31Expose serial settings from CDC virtual serial portMatthijs Kooijman
This allows a sketch to find out the settings chosen by the USB host (computer) and act accordingly. Other than reading the DTR flag and checking if the baudrate is 1200, the regular CDC code doesn't actually use any of these settings. By exposing these settings to the sketch, it can for example copy them to the hardware UART, turning the Leonardo into a proper USB-to-serial device. This can be useful to let the computer directly talk to whatever device is connected to the hardware serial port (like an XBee module). The Teensy core already supported these methods. This code was independently developed, but the method names were chosen to match the Teensy code, for compatibility (except that `dtr()` and `rtr()` return `bool`, while the Teensy version return a `uint8_t`). This change is applied to both the avr and sam cores, which have a very similar CDC implementation.
2015-07-16rename Setup typedef struct to USBSetupMartino Facchin
was really too common
2015-07-16Add support for waking up a host via USB HIDMartino Facchin
this is a rework of commit fbcf94801b8bba7f1c8c79cc7ae402b6b9dbb2d3
2015-07-16Move EP defines to headerMartino Facchin
2015-07-16Remove HID core libraryMartino Facchin
2015-05-12RX and TX Serial buffer sizes can now be defined independentlyNico
Fixes #2597
2014-09-12Added license to USBAPI.hCristian Maglie
Close #1847
2014-06-19Merge branch 'master' into ide-1.5.xCristian Maglie
2014-06-19Fixed regression in USBAPI and CDC (xaljox)Cristian Maglie
See: https://github.com/arduino/Arduino/commit/9ac7e30252fce5b9dafde3288519b020b73c37bd#commitcomment-6718676
2014-06-13Merge branch 'master' into HEADCristian Maglie
2014-06-10Update USBAPI.hEmbedded Micro
Fixes bug where Serial.read() would always return 0 as the first byte.
2014-05-26Merge branch 'usbcdc-improved' into ide-1.5.xCristian Maglie
2014-05-24Improve CDC read codePaul Brook
Read CDC data from USB FIFO on demand instead of in ISR. Remove superfluous ring buffer. Signed-off-by: Paul Brook <paul@nowt.org>
2014-05-24improved USB write speedsJustin Rajewski
2014-01-22Centrally decide which hardware UARTS are availableMatthijs Kooijman
Before, this decision was made in few different places, based on sometimes different register defines. Now, HardwareSerial.h decides wich UARTS are available, defines USE_HWSERIALn macros and HardwareSerial.cpp simply checks these macros (together with some #ifs to decide which registers to use for UART 0). For consistency, USBAPI.h also defines a HAVE_CDCSERIAL macro when applicable. For supported targets, this should change any behaviour. For unsupported targets, the error messages might subtly change because some checks are moved or changed. Additionally, this moves the USBAPI.h include form HardareSerial.h into Arduino.h and raises an error when both CDC serial and UART0 are available (previously this would silently use UART0 instead of CDC, but there is not currently any Atmel chip available for which this would occur).
2013-09-30Merge branch 'master' into ide-1.5.xCristian Maglie
2013-09-02USB CDC two argument begin()Paul Brook
Add two argument form of Serial_::begin Signed-off-by: Paul Brook <paul@nowt.org>
2013-09-02USB serial baud arg typePaul Brook
Make USB Serial_::begin() function take an unsigned long argument for consistency with HardwareSerial. Signed-off-by: Paul Brook <paul@nowt.org>
2013-07-27Move buffers into USB CDC (look #947 and #1369 for reference)Cristian Maglie
2013-07-26Fixed compile problem for Leonardo after ↵Cristian Maglie
0bd6a2d20fb9664255b20e0db11dd4586ebe9007
2012-06-14Adding write(str) and write(buf, size) for USB CDC.David A. Mellis
So that they work on the Leonardo. http://code.google.com/p/arduino/issues/detail?id=958
2012-05-15Mouse.isPressed() now checks only for left button by defaultZach Eveland
if no argument is given now checks left button by default to be consistent with press() and release() (thanks, David Mellis)
2012-05-01renamed Leonardo USB_ class to USBDevice_ to be unambiguous. renamed "USB" ↵Zach Eveland
object to "USBDevice" to prevent conflict with USB Host library (thanks Massimo)
2012-04-01added Boolean operators to HardwareSerial and CDC to test whether the port ↵Zach Eveland
is ready to send data. Mostly useful for Leonardo - simple way to test whether the port is actually opened by an application and ready to receive data. For Serial objects attached to real UARTs always returns true.
2012-03-28removed horrible multi-key Keyboard.press() and Keyboard.release() methodsZach Eveland
Saves 924 bytes of Flash
2012-03-28eliminated Keyboard.type() - unnecessary duplication of Keyboard.write() ↵Zach Eveland
(David Mellis). Also edit KeyboardReprogram example which was the only example using type()
2012-03-26added methods to Keyboard to handle multiple simultaneous key presses or ↵Zach Eveland
releases (up to six each)
2012-03-26added stub methods for begin() and end() to Mouse and KeyboardZach Eveland
2012-03-03Added Keyboard support for all modifier and all common non-printing keys.Zach Eveland
2012-03-03Removed support for key mapping in Keyboard.Zach Eveland
Was no longer being used and would be damn near impossible to support with the new scheme for handling modifiers and non-printing keyboard characters.
2012-03-03added Keyboard methods press(), release(), and releaseAll()Zach Eveland
Changes mean that a single, persistent key report must be used so keys can be added or removed. Also reimplemented type() using the new methods.
2012-03-03fixed minor compilation warnings for LeonardoZach Eveland
2011-12-20changed Keyboard write() method to type(). Made write() an alias for type() ↵Zach Eveland
to allow subclassing by Stream.