diff --git a/.codespellrc b/.codespellrc new file mode 100644 index 000000000..7d9fef573 --- /dev/null +++ b/.codespellrc @@ -0,0 +1,8 @@ +# See: https://github.com/codespell-project/codespell#using-a-config-file +[codespell] +# In the event of a false positive, add the problematic word, in all lowercase, to a comma-separated list here: +ignore-words-list = clearin,clen,hart,pullrequest,shiftin,waitin +builtin = clear +check-filenames = +check-hidden = +skip = ./.git,./firmwares/arduinoISP,./firmwares/wifishield,./bootloaders diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 000000000..03600dd7d --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,10 @@ +# See: https://docs.github.com/en/github/administering-a-repository/configuration-options-for-dependency-updates#about-the-dependabotyml-file +version: 2 + +updates: + # Configure check for outdated GitHub Actions actions in workflows. + # See: https://docs.github.com/en/github/administering-a-repository/keeping-your-actions-up-to-date-with-dependabot + - package-ecosystem: github-actions + directory: / # Check the repository's workflows under /.github/workflows/ + schedule: + interval: daily diff --git a/.github/workflows/check-arduino.yml b/.github/workflows/check-arduino.yml new file mode 100644 index 000000000..3991385f1 --- /dev/null +++ b/.github/workflows/check-arduino.yml @@ -0,0 +1,27 @@ +name: Check Arduino + +# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows +on: + push: + pull_request: + schedule: + # Run every Tuesday at 8 AM UTC to catch breakage caused by new rules added to Arduino Lint. + - cron: "0 8 * * TUE" + workflow_dispatch: + repository_dispatch: + +jobs: + lint: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Arduino Lint + uses: arduino/arduino-lint-action@v2 + with: + compliance: specification + # Always use this setting for official repositories. Remove for 3rd party projects. + official: true + project-type: platform diff --git a/.github/workflows/compile-platform-examples.yml b/.github/workflows/compile-platform-examples.yml new file mode 100644 index 000000000..58cfd3409 --- /dev/null +++ b/.github/workflows/compile-platform-examples.yml @@ -0,0 +1,247 @@ +name: Compile Examples + +# See: https://docs.github.com/en/actions/reference/events-that-trigger-workflows +on: + push: + paths: + - ".github/workflows/compile-platform-examples.ya?ml" + - "cores/**" + - "libraries/**" + - "variants/**" + - "boards.txt" + - "platform.txt" + pull_request: + paths: + - ".github/workflows/compile-platform-examples.ya?ml" + - "cores/**" + - "libraries/**" + - "variants/**" + - "boards.txt" + - "platform.txt" + workflow_dispatch: + repository_dispatch: + +jobs: + build: + name: ${{ matrix.board.fqbn }} + runs-on: ubuntu-latest + + env: + SKETCHES_REPORTS_PATH: sketches-reports + + strategy: + fail-fast: false + + matrix: + board: + - fqbn: arduino:avr:yun + artifact-name-suffix: arduino-avr-yun + serial: true + softwareserial: true + - fqbn: arduino:avr:uno + artifact-name-suffix: arduino-avr-uno + serial: true + softwareserial: true + - fqbn: arduino:avr:diecimila:cpu=atmega328 + artifact-name-suffix: arduino-avr-diecimila-cpu-atmega328 + serial: true + softwareserial: true + - fqbn: arduino:avr:diecimila:cpu=atmega168 + artifact-name-suffix: arduino-avr-diecimila-cpu-atmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:nano:cpu=atmega328 + artifact-name-suffix: arduino-avr-nano-cpu-atmega328 + serial: true + softwareserial: true + - fqbn: arduino:avr:nano:cpu=atmega328old + artifact-name-suffix: arduino-avr-nano-cpu-atmega328old + serial: true + softwareserial: true + - fqbn: arduino:avr:nano:cpu=atmega168 + artifact-name-suffix: arduino-avr-nano-cpu-atmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:mega:cpu=atmega2560 + artifact-name-suffix: arduino-avr-mega-cpu-atmega2560 + serial: true + softwareserial: true + - fqbn: arduino:avr:mega:cpu=atmega1280 + artifact-name-suffix: arduino-avr-mega-cpu-atmega1280 + serial: true + softwareserial: true + - fqbn: arduino:avr:megaADK + artifact-name-suffix: arduino-avr-megaADK + serial: true + softwareserial: true + - fqbn: arduino:avr:leonardo + artifact-name-suffix: arduino-avr-leonardo + serial: true + softwareserial: true + - fqbn: arduino:avr:leonardoeth + artifact-name-suffix: arduino-avr-leonardoeth + serial: true + softwareserial: true + - fqbn: arduino:avr:micro + artifact-name-suffix: arduino-avr-micro + serial: true + softwareserial: true + - fqbn: arduino:avr:esplora + artifact-name-suffix: arduino-avr-esplora + serial: true + softwareserial: true + - fqbn: arduino:avr:mini:cpu=atmega328 + artifact-name-suffix: arduino-avr-mini-cpu-atmega328 + serial: true + softwareserial: true + - fqbn: arduino:avr:mini:cpu=atmega168 + artifact-name-suffix: arduino-avr-mini-cpu-atmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:ethernet + artifact-name-suffix: arduino-avr-ethernet + serial: true + softwareserial: true + - fqbn: arduino:avr:fio + artifact-name-suffix: arduino-avr-fio + serial: true + softwareserial: true + - fqbn: arduino:avr:bt:cpu=atmega328 + artifact-name-suffix: arduino-avr-bt-cpu-atmega328 + serial: true + softwareserial: true + - fqbn: arduino:avr:bt:cpu=atmega168 + artifact-name-suffix: arduino-avr-bt-cpu-atmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:LilyPadUSB + artifact-name-suffix: arduino-avr-LilyPadUSB + serial: true + softwareserial: true + - fqbn: arduino:avr:lilypad:cpu=atmega328 + artifact-name-suffix: arduino-avr-lilypad-cpu-atmega328 + serial: true + softwareserial: true + - fqbn: arduino:avr:lilypad:cpu=atmega168 + artifact-name-suffix: arduino-avr-lilypad-cpu-atmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:pro:cpu=16MHzatmega328 + artifact-name-suffix: arduino-avr-pro-cpu-16MHzatmega328 + serial: true + softwareserial: true + - fqbn: arduino:avr:pro:cpu=8MHzatmega328 + artifact-name-suffix: arduino-avr-pro-cpu-8MHzatmega328 + serial: true + softwareserial: true + - fqbn: arduino:avr:pro:cpu=16MHzatmega168 + artifact-name-suffix: arduino-avr-pro-cpu-16MHzatmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:pro:cpu=8MHzatmega168 + artifact-name-suffix: arduino-avr-pro-cpu-8MHzatmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:atmegang:cpu=atmega168 + artifact-name-suffix: arduino-avr-atmegang-cpu-atmega168 + serial: true + softwareserial: true + - fqbn: arduino:avr:atmegang:cpu=atmega8 + artifact-name-suffix: arduino-avr-atmegang-cpu-atmega8 + serial: true + softwareserial: false + - fqbn: arduino:avr:robotControl + artifact-name-suffix: arduino-avr-robotControl + serial: true + softwareserial: false + - fqbn: arduino:avr:robotMotor + artifact-name-suffix: arduino-avr-robotMotor + serial: true + softwareserial: false + - fqbn: arduino:avr:gemma + artifact-name-suffix: arduino-avr-gemma + serial: false + softwareserial: false + - fqbn: arduino:avr:circuitplay32u4cat + artifact-name-suffix: arduino-avr-circuitplay32u4cat + serial: true + softwareserial: true + - fqbn: arduino:avr:yunmini + artifact-name-suffix: arduino-avr-yunmini + serial: true + softwareserial: true + - fqbn: arduino:avr:chiwawa + artifact-name-suffix: arduino-avr-chiwawa + serial: true + softwareserial: true + - fqbn: arduino:avr:one + artifact-name-suffix: arduino-avr-one + serial: true + softwareserial: true + - fqbn: arduino:avr:unowifi + artifact-name-suffix: arduino-avr-unowifi + serial: true + softwareserial: true + - fqbn: arduino:avr:unomini + artifact-name-suffix: arduino-avr-unomini + serial: true + softwareserial: true + + # Make board type-specific customizations to the matrix jobs + include: + - board: + # Boards with Serial interface + serial: true + # Compile these sketches in addition to the ones compiled for all boards + serial-sketch-paths: | + - libraries/EEPROM/examples/eeprom_crc + - libraries/EEPROM/examples/eeprom_get + - libraries/EEPROM/examples/eeprom_put + - libraries/EEPROM/examples/eeprom_read + - libraries/SPI + - libraries/Wire + - board: + serial: false + serial-sketch-paths: "" + - board: + # Boards compatible with the SoftwareSerial library + softwareserial: true + softwareserial-sketch-paths: | + - libraries/SoftwareSerial + - board: + softwareserial: false + softwareserial-sketch-paths: "" + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Compile examples + uses: arduino/compile-sketches@v1 + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + fqbn: ${{ matrix.board.fqbn }} + platforms: | + # Use Boards Manager to install the latest release of the platform to get the toolchain. + - name: arduino:avr + # Overwrite the Boards Manager installation with the platform from the repository. + - source-path: ./ + name: arduino:avr + sketch-paths: | + # Compile these sketches for all boards + - libraries/EEPROM/examples/eeprom_clear + - libraries/EEPROM/examples/eeprom_iteration + - libraries/EEPROM/examples/eeprom_update + - libraries/EEPROM/examples/eeprom_write + # Board-specific sketches + ${{ matrix.serial-sketch-paths }} + ${{ matrix.softwareserial-sketch-paths }} + enable-deltas-report: true + sketches-report-path: ${{ env.SKETCHES_REPORTS_PATH }} + + - name: Save sketches report as workflow artifact + uses: actions/upload-artifact@v4 + with: + if-no-files-found: error + path: ${{ env.SKETCHES_REPORTS_PATH }} + name: sketches-report-${{ matrix.board.artifact-name-suffix }} diff --git a/.github/workflows/report-size-deltas.yml b/.github/workflows/report-size-deltas.yml new file mode 100644 index 000000000..39e2a0ad2 --- /dev/null +++ b/.github/workflows/report-size-deltas.yml @@ -0,0 +1,24 @@ +name: Report Size Deltas + +# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows +on: + push: + paths: + - ".github/workflows/report-size-deltas.yml" + schedule: + # Run at the minimum interval allowed by GitHub Actions. + # Note: GitHub Actions periodically has outages which result in workflow failures. + # In this event, the workflows will start passing again once the service recovers. + - cron: "*/5 * * * *" + workflow_dispatch: + repository_dispatch: + +jobs: + report: + runs-on: ubuntu-latest + steps: + - name: Comment size deltas reports to PRs + uses: arduino/report-size-deltas@v1 + with: + # Regex matching the names of the workflow artifacts created by the "Compile Examples" workflow + sketches-reports-source: ^sketches-report-.+ diff --git a/.github/workflows/spell-check.yml b/.github/workflows/spell-check.yml new file mode 100644 index 000000000..ef7d89414 --- /dev/null +++ b/.github/workflows/spell-check.yml @@ -0,0 +1,22 @@ +name: Spell Check + +# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows +on: + push: + pull_request: + schedule: + # Run every Tuesday at 8 AM UTC to catch new misspelling detections resulting from dictionary updates. + - cron: "0 8 * * TUE" + workflow_dispatch: + repository_dispatch: + +jobs: + spellcheck: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Spell check + uses: codespell-project/actions-codespell@master diff --git a/README.md b/README.md new file mode 100644 index 000000000..42a1f043c --- /dev/null +++ b/README.md @@ -0,0 +1,8 @@ +# Arduino AVR Boards + +[![Check Arduino status](https://github.com/arduino/ArduinoCore-avr/actions/workflows/check-arduino.yml/badge.svg)](https://github.com/arduino/ArduinoCore-avr/actions/workflows/check-arduino.yml) +[![Compile Examples status](https://github.com/arduino/ArduinoCore-avr/actions/workflows/compile-platform-examples.yml/badge.svg)](https://github.com/arduino/ArduinoCore-avr/actions/workflows/compile-platform-examples.yml) +[![Spell Check status](https://github.com/arduino/ArduinoCore-avr/actions/workflows/spell-check.yml/badge.svg)](https://github.com/arduino/ArduinoCore-avr/actions/workflows/spell-check.yml) + +This repository contains the source code and configuration files of the Arduino AVR Boards +[platform](https://arduino.github.io/arduino-cli/latest/platform-specification/). diff --git a/boards.txt b/boards.txt index 1344fbb5c..b9add104a 100644 --- a/boards.txt +++ b/boards.txt @@ -1,4 +1,4 @@ -# See: http://code.google.com/p/arduino/wiki/Platforms +# See: https://arduino.github.io/arduino-cli/latest/platform-specification/ menu.cpu=Processor @@ -15,8 +15,19 @@ yun.vid.2=0x2A03 yun.pid.2=0x0041 yun.vid.3=0x2A03 yun.pid.3=0x8041 +yun.upload_port.0.vid=0x2341 +yun.upload_port.0.pid=0x0041 +yun.upload_port.1.vid=0x2341 +yun.upload_port.1.pid=0x8041 +yun.upload_port.2.vid=0x2A03 +yun.upload_port.2.pid=0x0041 +yun.upload_port.3.vid=0x2A03 +yun.upload_port.3.pid=0x8041 +yun.upload_port.4.board=yun yun.upload.tool=avrdude +yun.upload.tool.default=avrdude +yun.upload.tool.network=arduino_ota yun.upload.protocol=avr109 yun.upload.maximum_size=28672 yun.upload.maximum_data_size=2560 @@ -26,6 +37,7 @@ yun.upload.use_1200bps_touch=true yun.upload.wait_for_upload_port=true yun.bootloader.tool=avrdude +yun.bootloader.tool.default=avrdude yun.bootloader.low_fuses=0xff yun.bootloader.high_fuses=0xd8 yun.bootloader.extended_fuses=0xfb @@ -46,7 +58,7 @@ yun.build.extra_flags={build.usb_flags} ############################################################## -uno.name=Arduino Uno +uno.name=Arduino UNO uno.vid.0=0x2341 uno.pid.0=0x0043 @@ -56,14 +68,30 @@ uno.vid.2=0x2A03 uno.pid.2=0x0043 uno.vid.3=0x2341 uno.pid.3=0x0243 +uno.vid.4=0x2341 +uno.pid.4=0x006A +uno.upload_port.0.vid=0x2341 +uno.upload_port.0.pid=0x0043 +uno.upload_port.1.vid=0x2341 +uno.upload_port.1.pid=0x0001 +uno.upload_port.2.vid=0x2A03 +uno.upload_port.2.pid=0x0043 +uno.upload_port.3.vid=0x2341 +uno.upload_port.3.pid=0x0243 +uno.upload_port.4.vid=0x2341 +uno.upload_port.4.pid=0x006A +uno.upload_port.5.board=uno uno.upload.tool=avrdude +uno.upload.tool.default=avrdude +uno.upload.tool.network=arduino_ota uno.upload.protocol=arduino uno.upload.maximum_size=32256 uno.upload.maximum_data_size=2048 uno.upload.speed=115200 uno.bootloader.tool=avrdude +uno.bootloader.tool.default=avrdude uno.bootloader.low_fuses=0xFF uno.bootloader.high_fuses=0xDE uno.bootloader.extended_fuses=0xFD @@ -79,12 +107,50 @@ uno.build.variant=standard ############################################################## +unomini.name=Arduino UNO Mini + +unomini.vid.0=0x2341 +unomini.pid.0=0x0062 +unomini.upload_port.0.vid=0x2341 +unomini.upload_port.0.pid=0x0062 +unomini.upload_port.4.board=unomini + +unomini.upload.tool=avrdude +unomini.upload.tool.default=avrdude +unomini.upload.tool.network=arduino_ota +unomini.upload.protocol=arduino +unomini.upload.maximum_size=32256 +unomini.upload.maximum_data_size=2048 +unomini.upload.speed=115200 + +unomini.bootloader.tool=avrdude +unomini.bootloader.tool.default=avrdude +unomini.bootloader.low_fuses=0xFF +unomini.bootloader.high_fuses=0xDE +unomini.bootloader.extended_fuses=0xFD +unomini.bootloader.unlock_bits=0x3F +unomini.bootloader.lock_bits=0x0F +unomini.bootloader.file=optiboot/optiboot_atmega328.hex + +unomini.build.mcu=atmega328p +unomini.build.f_cpu=16000000L +unomini.build.board=AVR_UNO +unomini.build.core=arduino +unomini.build.variant=standard + +############################################################## + diecimila.name=Arduino Duemilanove or Diecimila +diecimila.upload_port.0.board=diecimila + diecimila.upload.tool=avrdude +diecimila.upload.tool.default=avrdude +diecimila.upload.tool.network=arduino_ota diecimila.upload.protocol=arduino diecimila.bootloader.tool=avrdude +diecimila.bootloader.tool.default=avrdude diecimila.bootloader.low_fuses=0xFF diecimila.bootloader.unlock_bits=0x3F diecimila.bootloader.lock_bits=0x0F @@ -126,10 +192,15 @@ diecimila.menu.cpu.atmega168.build.mcu=atmega168 nano.name=Arduino Nano +nano.upload_port.0.board=nano + nano.upload.tool=avrdude +nano.upload.tool.default=avrdude +nano.upload.tool.network=arduino_ota nano.upload.protocol=arduino nano.bootloader.tool=avrdude +nano.bootloader.tool.default=avrdude nano.bootloader.unlock_bits=0x3F nano.bootloader.lock_bits=0x0F @@ -199,11 +270,27 @@ mega.vid.4=0x2341 mega.pid.4=0x0210 mega.vid.5=0x2341 mega.pid.5=0x0242 +mega.upload_port.0.vid=0x2341 +mega.upload_port.0.pid=0x0010 +mega.upload_port.1.vid=0x2341 +mega.upload_port.1.pid=0x0042 +mega.upload_port.2.vid=0x2A03 +mega.upload_port.2.pid=0x0010 +mega.upload_port.3.vid=0x2A03 +mega.upload_port.3.pid=0x0042 +mega.upload_port.4.vid=0x2341 +mega.upload_port.4.pid=0x0210 +mega.upload_port.5.vid=0x2341 +mega.upload_port.5.pid=0x0242 +mega.upload_port.6.board=mega mega.upload.tool=avrdude +mega.upload.tool.default=avrdude +mega.upload.tool.network=arduino_ota mega.upload.maximum_data_size=8192 mega.bootloader.tool=avrdude +mega.bootloader.tool.default=avrdude mega.bootloader.low_fuses=0xFF mega.bootloader.unlock_bits=0x3F mega.bootloader.lock_bits=0x0F @@ -256,14 +343,26 @@ megaADK.vid.2=0x2A03 megaADK.pid.2=0x003f megaADK.vid.3=0x2A03 megaADK.pid.3=0x0044 +megaADK.upload_port.0.vid=0x2341 +megaADK.upload_port.0.pid=0x003f +megaADK.upload_port.1.vid=0x2341 +megaADK.upload_port.1.pid=0x0044 +megaADK.upload_port.2.vid=0x2A03 +megaADK.upload_port.2.pid=0x003f +megaADK.upload_port.3.vid=0x2A03 +megaADK.upload_port.3.pid=0x0044 +megaADK.upload_port.4.board=megaADK megaADK.upload.tool=avrdude +megaADK.upload.tool.default=avrdude +megaADK.upload.tool.network=arduino_ota megaADK.upload.protocol=wiring megaADK.upload.maximum_size=253952 megaADK.upload.maximum_data_size=8192 megaADK.upload.speed=115200 megaADK.bootloader.tool=avrdude +megaADK.bootloader.tool.default=avrdude megaADK.bootloader.low_fuses=0xFF megaADK.bootloader.high_fuses=0xD8 megaADK.bootloader.extended_fuses=0xFD @@ -288,8 +387,19 @@ leonardo.vid.2=0x2A03 leonardo.pid.2=0x0036 leonardo.vid.3=0x2A03 leonardo.pid.3=0x8036 +leonardo.upload_port.0.vid=0x2341 +leonardo.upload_port.0.pid=0x0036 +leonardo.upload_port.1.vid=0x2341 +leonardo.upload_port.1.pid=0x8036 +leonardo.upload_port.2.vid=0x2A03 +leonardo.upload_port.2.pid=0x0036 +leonardo.upload_port.3.vid=0x2A03 +leonardo.upload_port.3.pid=0x8036 +leonardo.upload_port.4.board=leonardo leonardo.upload.tool=avrdude +leonardo.upload.tool.default=avrdude +leonardo.upload.tool.network=arduino_ota leonardo.upload.protocol=avr109 leonardo.upload.maximum_size=28672 leonardo.upload.maximum_data_size=2560 @@ -299,6 +409,7 @@ leonardo.upload.use_1200bps_touch=true leonardo.upload.wait_for_upload_port=true leonardo.bootloader.tool=avrdude +leonardo.bootloader.tool.default=avrdude leonardo.bootloader.low_fuses=0xff leonardo.bootloader.high_fuses=0xd8 leonardo.bootloader.extended_fuses=0xcb @@ -323,8 +434,15 @@ leonardoeth.vid.0=0x2a03 leonardoeth.pid.0=0x0040 leonardoeth.vid.1=0x2a03 leonardoeth.pid.1=0x8040 +leonardoeth.upload_port.0.vid=0x2a03 +leonardoeth.upload_port.0.pid=0x0040 +leonardoeth.upload_port.1.vid=0x2a03 +leonardoeth.upload_port.1.pid=0x8040 +leonardoeth.upload_port.2.board=leonardoeth leonardoeth.upload.tool=avrdude +leonardoeth.upload.tool.default=avrdude +leonardoeth.upload.tool.network=arduino_ota leonardoeth.upload.protocol=avr109 leonardoeth.upload.maximum_size=28672 leonardoeth.upload.maximum_data_size=2560 @@ -334,6 +452,7 @@ leonardoeth.upload.use_1200bps_touch=true leonardoeth.upload.wait_for_upload_port=true leonardoeth.bootloader.tool=avrdude +leonardoeth.bootloader.tool.default=avrdude leonardoeth.bootloader.low_fuses=0xff leonardoeth.bootloader.high_fuses=0xd8 leonardoeth.bootloader.extended_fuses=0xcb @@ -367,8 +486,23 @@ micro.vid.4=0x2341 micro.pid.4=0x0237 micro.vid.5=0x2341 micro.pid.5=0x8237 +micro.upload_port.0.vid=0x2341 +micro.upload_port.0.pid=0x0037 +micro.upload_port.1.vid=0x2341 +micro.upload_port.1.pid=0x8037 +micro.upload_port.2.vid=0x2A03 +micro.upload_port.2.pid=0x0037 +micro.upload_port.3.vid=0x2A03 +micro.upload_port.3.pid=0x8037 +micro.upload_port.4.vid=0x2341 +micro.upload_port.4.pid=0x0237 +micro.upload_port.5.vid=0x2341 +micro.upload_port.5.pid=0x8237 +micro.upload_port.6.board=micro micro.upload.tool=avrdude +micro.upload.tool.default=avrdude +micro.upload.tool.network=arduino_ota micro.upload.protocol=avr109 micro.upload.maximum_size=28672 micro.upload.maximum_data_size=2560 @@ -378,6 +512,7 @@ micro.upload.use_1200bps_touch=true micro.upload.wait_for_upload_port=true micro.bootloader.tool=avrdude +micro.bootloader.tool.default=avrdude micro.bootloader.low_fuses=0xff micro.bootloader.high_fuses=0xd8 micro.bootloader.extended_fuses=0xcb @@ -406,8 +541,19 @@ esplora.vid.2=0x2A03 esplora.pid.2=0x003C esplora.vid.3=0x2A03 esplora.pid.3=0x803C +esplora.upload_port.0.vid=0x2341 +esplora.upload_port.0.pid=0x003C +esplora.upload_port.1.vid=0x2341 +esplora.upload_port.1.pid=0x803C +esplora.upload_port.2.vid=0x2A03 +esplora.upload_port.2.pid=0x003C +esplora.upload_port.3.vid=0x2A03 +esplora.upload_port.3.pid=0x803C +esplora.upload_port.4.board=esplora esplora.upload.tool=avrdude +esplora.upload.tool.default=avrdude +esplora.upload.tool.network=arduino_ota esplora.upload.protocol=avr109 esplora.upload.maximum_size=28672 esplora.upload.maximum_data_size=2560 @@ -417,6 +563,7 @@ esplora.upload.use_1200bps_touch=true esplora.upload.wait_for_upload_port=true esplora.bootloader.tool=avrdude +esplora.bootloader.tool.default=avrdude esplora.bootloader.low_fuses=0xff esplora.bootloader.high_fuses=0xd8 esplora.bootloader.extended_fuses=0xcb @@ -438,10 +585,15 @@ esplora.build.extra_flags={build.usb_flags} mini.name=Arduino Mini +mini.upload_port.0.board=mini + mini.upload.tool=avrdude +mini.upload.tool.default=avrdude +mini.upload.tool.network=arduino_ota mini.upload.protocol=arduino mini.bootloader.tool=avrdude +mini.bootloader.tool.default=avrdude mini.bootloader.low_fuses=0xff mini.bootloader.unlock_bits=0x3F mini.bootloader.lock_bits=0x0F @@ -483,13 +635,18 @@ mini.menu.cpu.atmega168.build.mcu=atmega168 ethernet.name=Arduino Ethernet +ethernet.upload_port.0.board=ethernet + ethernet.upload.tool=avrdude +ethernet.upload.tool.default=avrdude +ethernet.upload.tool.network=arduino_ota ethernet.upload.protocol=arduino ethernet.upload.maximum_size=32256 ethernet.upload.maximum_data_size=2048 ethernet.upload.speed=115200 ethernet.bootloader.tool=avrdude +ethernet.bootloader.tool.default=avrdude ethernet.bootloader.low_fuses=0xff ethernet.bootloader.high_fuses=0xde ethernet.bootloader.extended_fuses=0xFD @@ -507,13 +664,18 @@ ethernet.build.core=arduino fio.name=Arduino Fio +fio.upload_port.0.board=fio + fio.upload.tool=avrdude +fio.upload.tool.default=avrdude +fio.upload.tool.network=arduino_ota fio.upload.protocol=arduino fio.upload.maximum_size=30720 fio.upload.maximum_data_size=2048 fio.upload.speed=57600 fio.bootloader.tool=avrdude +fio.bootloader.tool.default=avrdude fio.bootloader.low_fuses=0xFF fio.bootloader.high_fuses=0xDA fio.bootloader.extended_fuses=0xFD @@ -531,12 +693,17 @@ fio.build.variant=eightanaloginputs bt.name=Arduino BT +bt.upload_port.0.board=bt + bt.upload.tool=avrdude +bt.upload.tool.default=avrdude +bt.upload.tool.network=arduino_ota bt.upload.protocol=arduino bt.upload.speed=19200 bt.upload.disable_flushing=true bt.bootloader.tool=avrdude +bt.bootloader.tool.default=avrdude bt.bootloader.low_fuses=0xff bt.bootloader.unlock_bits=0x3F bt.bootloader.lock_bits=0x0F @@ -577,8 +744,15 @@ LilyPadUSB.vid.0=0x1B4F LilyPadUSB.pid.0=0x9207 LilyPadUSB.vid.1=0x1B4F LilyPadUSB.pid.1=0x9208 +LilyPadUSB.upload_port.0.vid=0x1B4F +LilyPadUSB.upload_port.0.pid=0x9207 +LilyPadUSB.upload_port.1.vid=0x1B4F +LilyPadUSB.upload_port.1.pid=0x9208 +LilyPadUSB.upload_port.2.board=LilyPadUSB LilyPadUSB.upload.tool=avrdude +LilyPadUSB.upload.tool.default=avrdude +LilyPadUSB.upload.tool.network=arduino_ota LilyPadUSB.upload.protocol=avr109 LilyPadUSB.upload.maximum_size=28672 LilyPadUSB.upload.maximum_data_size=2560 @@ -588,6 +762,7 @@ LilyPadUSB.upload.use_1200bps_touch=true LilyPadUSB.upload.wait_for_upload_port=true LilyPadUSB.bootloader.tool=avrdude +LilyPadUSB.bootloader.tool.default=avrdude LilyPadUSB.bootloader.low_fuses=0xff LilyPadUSB.bootloader.high_fuses=0xd8 LilyPadUSB.bootloader.extended_fuses=0xce @@ -609,10 +784,15 @@ LilyPadUSB.build.extra_flags={build.usb_flags} lilypad.name=LilyPad Arduino +lilypad.upload_port.0.board=lilypad + lilypad.upload.tool=avrdude +lilypad.upload.tool.default=avrdude +lilypad.upload.tool.network=arduino_ota lilypad.upload.protocol=arduino lilypad.bootloader.tool=avrdude +lilypad.bootloader.tool.default=avrdude lilypad.bootloader.unlock_bits=0x3F lilypad.bootloader.lock_bits=0x0F @@ -655,10 +835,15 @@ lilypad.menu.cpu.atmega168.build.mcu=atmega168 pro.name=Arduino Pro or Pro Mini +pro.upload_port.0.board=pro + pro.upload.tool=avrdude +pro.upload.tool.default=avrdude +pro.upload.tool.network=arduino_ota pro.upload.protocol=arduino pro.bootloader.tool=avrdude +pro.bootloader.tool.default=avrdude pro.bootloader.unlock_bits=0x3F pro.bootloader.lock_bits=0x0F @@ -734,11 +919,16 @@ pro.menu.cpu.8MHzatmega168.build.f_cpu=8000000L atmegang.name=Arduino NG or older +atmegang.upload_port.0.board=atmegang + atmegang.upload.tool=avrdude +atmegang.upload.tool.default=avrdude +atmegang.upload.tool.network=arduino_ota atmegang.upload.protocol=arduino atmegang.upload.speed=19200 atmegang.bootloader.tool=avrdude +atmegang.bootloader.tool.default=avrdude atmegang.bootloader.unlock_bits=0x3F atmegang.bootloader.lock_bits=0x0F @@ -787,8 +977,19 @@ robotControl.vid.2=0x2A03 robotControl.pid.2=0x0038 robotControl.vid.3=0x2A03 robotControl.pid.3=0x8038 +robotControl.upload_port.0.vid=0x2341 +robotControl.upload_port.0.pid=0x0038 +robotControl.upload_port.1.vid=0x2341 +robotControl.upload_port.1.pid=0x8038 +robotControl.upload_port.2.vid=0x2A03 +robotControl.upload_port.2.pid=0x0038 +robotControl.upload_port.3.vid=0x2A03 +robotControl.upload_port.3.pid=0x8038 +robotControl.upload_port.4.board=robotControl robotControl.upload.tool=avrdude +robotControl.upload.tool.default=avrdude +robotControl.upload.tool.network=arduino_ota robotControl.upload.protocol=avr109 robotControl.upload.maximum_size=28672 robotControl.upload.maximum_data_size=2560 @@ -798,6 +999,7 @@ robotControl.upload.use_1200bps_touch=true robotControl.upload.wait_for_upload_port=true robotControl.bootloader.tool=avrdude +robotControl.bootloader.tool.default=avrdude robotControl.bootloader.low_fuses=0xff robotControl.bootloader.high_fuses=0xd8 robotControl.bootloader.extended_fuses=0xcb @@ -826,8 +1028,19 @@ robotMotor.vid.2=0x2A03 robotMotor.pid.2=0x0039 robotMotor.vid.3=0x2A03 robotMotor.pid.3=0x8039 +robotMotor.upload_port.0.vid=0x2341 +robotMotor.upload_port.0.pid=0x0039 +robotMotor.upload_port.1.vid=0x2341 +robotMotor.upload_port.1.pid=0x8039 +robotMotor.upload_port.2.vid=0x2A03 +robotMotor.upload_port.2.pid=0x0039 +robotMotor.upload_port.3.vid=0x2A03 +robotMotor.upload_port.3.pid=0x8039 +robotMotor.upload_port.4.board=robotMotor robotMotor.upload.tool=avrdude +robotMotor.upload.tool.default=avrdude +robotMotor.upload.tool.network=arduino_ota robotMotor.upload.protocol=avr109 robotMotor.upload.maximum_size=28672 robotMotor.upload.maximum_data_size=2560 @@ -837,6 +1050,7 @@ robotMotor.upload.use_1200bps_touch=true robotMotor.upload.wait_for_upload_port=true robotMotor.bootloader.tool=avrdude +robotMotor.bootloader.tool.default=avrdude robotMotor.bootloader.low_fuses=0xff robotMotor.bootloader.high_fuses=0xd8 robotMotor.bootloader.extended_fuses=0xcb @@ -858,6 +1072,9 @@ robotMotor.build.extra_flags={build.usb_flags} gemma.vid.0=0x2341 gemma.pid.0=0x0c9f +gemma.upload_port.0.vid=0x2341 +gemma.upload_port.0.pid=0x0c9f +gemma.upload_port.1.board=gemma gemma.name=Arduino Gemma @@ -865,6 +1082,7 @@ gemma.bootloader.low_fuses=0xF1 gemma.bootloader.high_fuses=0xD5 gemma.bootloader.extended_fuses=0xFE gemma.bootloader.tool=avrdude +gemma.bootloader.tool.default=avrdude gemma.bootloader.lock_bits= gemma.bootloader.unlock_bits= gemma.bootloader.file=gemma/gemma_v1.hex @@ -876,6 +1094,8 @@ gemma.build.variant=gemma gemma.build.board=AVR_GEMMA gemma.upload.tool=avrdude +gemma.upload.tool.default=avrdude +gemma.upload.tool.network=arduino_ota gemma.upload.maximum_size=5310 ############################################################## @@ -889,6 +1109,7 @@ circuitplay32u4cat.bootloader.file=caterina/Caterina-Circuitplay32u4.hex circuitplay32u4cat.bootloader.unlock_bits=0x3F circuitplay32u4cat.bootloader.lock_bits=0x2F circuitplay32u4cat.bootloader.tool=avrdude +circuitplay32u4cat.bootloader.tool.default=avrdude circuitplay32u4cat.build.mcu=atmega32u4 circuitplay32u4cat.build.f_cpu=8000000L circuitplay32u4cat.build.vid=0x239A @@ -906,8 +1127,13 @@ circuitplay32u4cat.upload.disable_flushing=true circuitplay32u4cat.upload.use_1200bps_touch=true circuitplay32u4cat.upload.wait_for_upload_port=true circuitplay32u4cat.upload.tool=avrdude +circuitplay32u4cat.upload.tool.default=avrdude +circuitplay32u4cat.upload.tool.network=arduino_ota circuitplay32u4cat.vid.0=0x239A circuitplay32u4cat.pid.0=0x8011 +circuitplay32u4cat.upload_port.0.vid=0x239A +circuitplay32u4cat.upload_port.0.pid=0x8011 +circuitplay32u4cat.upload_port.1.board=circuitplay32u4cat ############################################################## @@ -918,8 +1144,15 @@ yunmini.vid.0=0x2a03 yunmini.pid.0=0x0050 yunmini.vid.1=0x2a03 yunmini.pid.1=0x8050 +yunmini.upload_port.0.vid=0x2a03 +yunmini.upload_port.0.pid=0x0050 +yunmini.upload_port.1.vid=0x2a03 +yunmini.upload_port.1.pid=0x8050 +yunmini.upload_port.2.board=yunmini yunmini.upload.tool=avrdude +yunmini.upload.tool.default=avrdude +yunmini.upload.tool.network=arduino_ota yunmini.upload.protocol=avr109 yunmini.upload.maximum_size=28672 yunmini.upload.maximum_data_size=2560 @@ -929,6 +1162,7 @@ yunmini.upload.use_1200bps_touch=true yunmini.upload.wait_for_upload_port=true yunmini.bootloader.tool=avrdude +yunmini.bootloader.tool.default=avrdude yunmini.bootloader.low_fuses=0xff yunmini.bootloader.high_fuses=0xd8 yunmini.bootloader.extended_fuses=0xfb @@ -955,8 +1189,15 @@ chiwawa.vid.0=0x2a03 chiwawa.pid.0=0x0056 chiwawa.vid.1=0x2a03 chiwawa.pid.1=0x8056 +chiwawa.upload_port.0.vid=0x2a03 +chiwawa.upload_port.0.pid=0x0056 +chiwawa.upload_port.1.vid=0x2a03 +chiwawa.upload_port.1.pid=0x8056 +chiwawa.upload_port.2.board=chiwawa chiwawa.upload.tool=avrdude +chiwawa.upload.tool.default=avrdude +chiwawa.upload.tool.network=arduino_ota chiwawa.upload.protocol=avr109 chiwawa.upload.maximum_size=28672 chiwawa.upload.maximum_data_size=2560 @@ -966,6 +1207,7 @@ chiwawa.upload.use_1200bps_touch=true chiwawa.upload.wait_for_upload_port=true chiwawa.bootloader.tool=avrdude +chiwawa.bootloader.tool.default=avrdude chiwawa.bootloader.low_fuses=0xff chiwawa.bootloader.high_fuses=0xd8 chiwawa.bootloader.extended_fuses=0xfb @@ -992,8 +1234,15 @@ one.vid.0=0x2a03 one.pid.0=0x0001 one.vid.1=0x2a03 one.pid.1=0x8001 +one.upload_port.0.vid=0x2a03 +one.upload_port.0.pid=0x0001 +one.upload_port.1.vid=0x2a03 +one.upload_port.1.pid=0x8001 +one.upload_port.2.board=one one.upload.tool=avrdude +one.upload.tool.default=avrdude +one.upload.tool.network=arduino_ota one.upload.protocol=avr109 one.upload.maximum_size=28672 one.upload.maximum_data_size=2560 @@ -1003,6 +1252,7 @@ one.upload.use_1200bps_touch=true one.upload.wait_for_upload_port=true one.bootloader.tool=avrdude +one.bootloader.tool.default=avrdude one.bootloader.low_fuses=0xff one.bootloader.high_fuses=0xd8 one.bootloader.extended_fuses=0xfb @@ -1022,11 +1272,16 @@ one.build.extra_flags={build.usb_flags} ############################################################## -unowifi.name=Arduino Uno WiFi +unowifi.name=Arduino UNO WiFi unowifi.vid.0=0x2A03 unowifi.pid.0=0x0057 +unowifi.upload_port.0.vid=0x2A03 +unowifi.upload_port.0.pid=0x0057 +unowifi.upload_port.1.board=unowifi unowifi.upload.tool=avrdude +unowifi.upload.tool.default=avrdude +unowifi.upload.tool.network=arduino_ota unowifi.upload.protocol=arduino unowifi.upload.maximum_size=32256 unowifi.upload.maximum_data_size=2048 @@ -1038,6 +1293,7 @@ unowifi.upload.network.endpoint_reset=/log/reset unowifi.upload.network.port=80 unowifi.bootloader.tool=avrdude +unowifi.bootloader.tool.default=avrdude unowifi.bootloader.low_fuses=0xFF unowifi.bootloader.high_fuses=0xDE unowifi.bootloader.extended_fuses=0x05 @@ -1052,3 +1308,5 @@ unowifi.build.core=arduino unowifi.build.variant=standard unowifi.build.esp_ch_uart_br=19200 unowifi.build.extra_flags=-DESP_CH_UART -DESP_CH_UART_BR={build.esp_ch_uart_br} + +############################################################## diff --git a/bootloaders/atmega/ATmegaBOOT_168.c b/bootloaders/atmega/ATmegaBOOT_168.c index ff2c4e486..143e7a7ca 100644 --- a/bootloaders/atmega/ATmegaBOOT_168.c +++ b/bootloaders/atmega/ATmegaBOOT_168.c @@ -387,7 +387,7 @@ int main(void) UCSR0C = (1< 256, the buffer index // variables are automatically increased in size, but the extra diff --git a/cores/arduino/HardwareSerial0.cpp b/cores/arduino/HardwareSerial0.cpp index 1146eebab..7d47ed2f6 100644 --- a/cores/arduino/HardwareSerial0.cpp +++ b/cores/arduino/HardwareSerial0.cpp @@ -26,7 +26,7 @@ #include "HardwareSerial.h" #include "HardwareSerial_private.h" -// Each HardwareSerial is defined in its own file, sine the linker pulls +// Each HardwareSerial is defined in its own file, since the linker pulls // in the entire file when any element inside is used. --gc-sections can // additionally cause unused symbols to be dropped, but ISRs have the // "used" attribute so are never dropped and they keep the diff --git a/cores/arduino/HardwareSerial1.cpp b/cores/arduino/HardwareSerial1.cpp index 19625e235..a345cdbbc 100644 --- a/cores/arduino/HardwareSerial1.cpp +++ b/cores/arduino/HardwareSerial1.cpp @@ -26,7 +26,7 @@ #include "HardwareSerial.h" #include "HardwareSerial_private.h" -// Each HardwareSerial is defined in its own file, sine the linker pulls +// Each HardwareSerial is defined in its own file, since the linker pulls // in the entire file when any element inside is used. --gc-sections can // additionally cause unused symbols to be dropped, but ISRs have the // "used" attribute so are never dropped and they keep the diff --git a/cores/arduino/HardwareSerial2.cpp b/cores/arduino/HardwareSerial2.cpp index fd334ae15..8e433b6fc 100644 --- a/cores/arduino/HardwareSerial2.cpp +++ b/cores/arduino/HardwareSerial2.cpp @@ -26,7 +26,7 @@ #include "HardwareSerial.h" #include "HardwareSerial_private.h" -// Each HardwareSerial is defined in its own file, sine the linker pulls +// Each HardwareSerial is defined in its own file, since the linker pulls // in the entire file when any element inside is used. --gc-sections can // additionally cause unused symbols to be dropped, but ISRs have the // "used" attribute so are never dropped and they keep the diff --git a/cores/arduino/HardwareSerial3.cpp b/cores/arduino/HardwareSerial3.cpp index a68095b37..26aaee81d 100644 --- a/cores/arduino/HardwareSerial3.cpp +++ b/cores/arduino/HardwareSerial3.cpp @@ -26,7 +26,7 @@ #include "HardwareSerial.h" #include "HardwareSerial_private.h" -// Each HardwareSerial is defined in its own file, sine the linker pulls +// Each HardwareSerial is defined in its own file, since the linker pulls // in the entire file when any element inside is used. --gc-sections can // additionally cause unused symbols to be dropped, but ISRs have the // "used" attribute so are never dropped and they keep the diff --git a/cores/arduino/HardwareSerial_private.h b/cores/arduino/HardwareSerial_private.h index 761a5e559..2e23cec0c 100644 --- a/cores/arduino/HardwareSerial_private.h +++ b/cores/arduino/HardwareSerial_private.h @@ -63,7 +63,7 @@ #endif #endif // !defined TXC0 -// Check at compiletime that it is really ok to use the bit positions of +// Check at compile time that it is really ok to use the bit positions of // UART0 for the other UARTs as well, in case these values ever get // changed for future hardware. #if defined(TXC1) && (TXC1 != TXC0 || RXEN1 != RXEN0 || RXCIE1 != RXCIE0 || \ diff --git a/cores/arduino/Print.h b/cores/arduino/Print.h index 058a2abbd..0097cc11d 100644 --- a/cores/arduino/Print.h +++ b/cores/arduino/Print.h @@ -59,7 +59,7 @@ class Print } // default to zero, meaning "a single write may block" - // should be overriden by subclasses with buffering + // should be overridden by subclasses with buffering virtual int availableForWrite() { return 0; } size_t print(const __FlashStringHelper *); diff --git a/cores/arduino/Stream.h b/cores/arduino/Stream.h index 8e950c731..21a247a0d 100644 --- a/cores/arduino/Stream.h +++ b/cores/arduino/Stream.h @@ -25,7 +25,7 @@ #include #include "Print.h" -// compatability macros for testing +// compatibility macros for testing /* #define getInt() parseInt() #define getInt(ignore) parseInt(ignore) diff --git a/cores/arduino/USBAPI.h b/cores/arduino/USBAPI.h index 701a14f78..3ff145916 100644 --- a/cores/arduino/USBAPI.h +++ b/cores/arduino/USBAPI.h @@ -32,7 +32,7 @@ typedef unsigned long u32; #include "Arduino.h" -// This definitions is usefull if you want to reduce the EP_SIZE to 16 +// This definitions is useful if you want to reduce the EP_SIZE to 16 // at the moment only 64 and 16 as EP_SIZE for all EPs are supported except the control endpoint #ifndef USB_EP_SIZE #define USB_EP_SIZE 64 diff --git a/cores/arduino/USBCore.cpp b/cores/arduino/USBCore.cpp index dc6bc387e..933523873 100644 --- a/cores/arduino/USBCore.cpp +++ b/cores/arduino/USBCore.cpp @@ -69,8 +69,18 @@ const u8 STRING_MANUFACTURER[] PROGMEM = USB_MANUFACTURER; #define DEVICE_CLASS 0x02 // DEVICE DESCRIPTOR + +#ifdef CDC_ENABLED const DeviceDescriptor USB_DeviceDescriptorIAD = D_DEVICE(0xEF,0x02,0x01,64,USB_VID,USB_PID,0x100,IMANUFACTURER,IPRODUCT,ISERIAL,1); +#else // CDC_DISABLED +// The default descriptor uses USB class OxEF, subclass 0x02 with protocol 1 +// which means "Interface Association Descriptor" - that's needed for the CDC, +// but doesn't make much sense as a default for custom devices when CDC is disabled. +// (0x00 means "Use class information in the Interface Descriptors" which should be generally ok) +const DeviceDescriptor USB_DeviceDescriptorIAD = + D_DEVICE(0x00,0x00,0x00,64,USB_VID,USB_PID,0x100,IMANUFACTURER,IPRODUCT,ISERIAL,1); +#endif //================================================================== //================================================================== @@ -328,10 +338,12 @@ int USB_Send(u8 ep, const void* d, int len) u8 _initEndpoints[USB_ENDPOINTS] = { 0, // Control Endpoint - + +#ifdef CDC_ENABLED EP_TYPE_INTERRUPT_IN, // CDC_ENDPOINT_ACM EP_TYPE_BULK_OUT, // CDC_ENDPOINT_OUT EP_TYPE_BULK_IN, // CDC_ENDPOINT_IN +#endif // Following endpoints are automatically initialized to 0 }; @@ -373,10 +385,12 @@ void InitEndpoints() static bool ClassInterfaceRequest(USBSetup& setup) { +#ifdef CDC_ENABLED u8 i = setup.wIndex; if (CDC_ACM_INTERFACE == i) return CDC_Setup(setup); +#endif #ifdef PLUGGABLE_USB_ENABLED return PluggableUSB().setup(setup); @@ -466,7 +480,9 @@ static u8 SendInterfaces() { u8 interfaces = 0; +#ifdef CDC_ENABLED CDC_GetInterface(&interfaces); +#endif #ifdef PLUGGABLE_USB_ENABLED PluggableUSB().getInterface(&interfaces); diff --git a/cores/arduino/USBCore.h b/cores/arduino/USBCore.h index 0c63c2b1f..8642382f1 100644 --- a/cores/arduino/USBCore.h +++ b/cores/arduino/USBCore.h @@ -191,7 +191,7 @@ typedef struct } EndpointDescriptor; // Interface Association Descriptor -// Used to bind 2 interfaces together in CDC compostite device +// Used to bind 2 interfaces together in CDC composite device typedef struct { u8 len; // 8 diff --git a/cores/arduino/USBDesc.h b/cores/arduino/USBDesc.h index c0dce079e..b55ac20bc 100644 --- a/cores/arduino/USBDesc.h +++ b/cores/arduino/USBDesc.h @@ -26,8 +26,25 @@ #define ISERIAL_MAX_LEN 20 +// Uncomment the following line or pass -DCDC_DISABLED to the compiler +// to disable CDC (serial console via USB). +// That's useful if you want to create an USB device (like an USB Boot Keyboard) +// that works even with problematic devices (like KVM switches). +// Keep in mind that with this change you'll have to use the Arduino's +// reset button to be able to flash it. +//#define CDC_DISABLED + +#ifndef CDC_DISABLED +#define CDC_ENABLED +#endif + +#ifdef CDC_ENABLED #define CDC_INTERFACE_COUNT 2 #define CDC_ENPOINT_COUNT 3 +#else // CDC_DISABLED +#define CDC_INTERFACE_COUNT 0 +#define CDC_ENPOINT_COUNT 0 +#endif #define CDC_ACM_INTERFACE 0 // CDC ACM #define CDC_DATA_INTERFACE 1 // CDC Data diff --git a/cores/arduino/WInterrupts.c b/cores/arduino/WInterrupts.c index ac72dda44..38ea15800 100644 --- a/cores/arduino/WInterrupts.c +++ b/cores/arduino/WInterrupts.c @@ -102,6 +102,39 @@ void attachInterrupt(uint8_t interruptNum, void (*userFunc)(void), int mode) { EICRB = (EICRB & ~((1< + +namespace std { + struct nothrow_t {}; + extern const nothrow_t nothrow; + + // These are not actually implemented, to prevent overhead and + // complexity. They are still declared to allow implementing + // them in user code if needed. + typedef void (*new_handler)(); + new_handler set_new_handler(new_handler new_p) noexcept; + new_handler get_new_handler() noexcept; + + // This is normally declared in various headers that we do not have + // available, so just define it here. We could also use ::size_t + // below, but then anyone including can no longer assume + // std::size_t is available. + using size_t = ::size_t; +} // namespace std + +[[gnu::weak]] void * operator new(std::size_t size); +[[gnu::weak]] void * operator new[](std::size_t size); + +[[gnu::weak]] void * operator new(std::size_t size, const std::nothrow_t tag) noexcept; +[[gnu::weak]] void * operator new[](std::size_t size, const std::nothrow_t& tag) noexcept; + +void * operator new(std::size_t size, void *place) noexcept; +void * operator new[](std::size_t size, void *place) noexcept; + +[[gnu::weak]] void operator delete(void * ptr) noexcept; +[[gnu::weak]] void operator delete[](void * ptr) noexcept; + +#if __cplusplus >= 201402L +[[gnu::weak]] void operator delete(void* ptr, std::size_t size) noexcept; +[[gnu::weak]] void operator delete[](void * ptr, std::size_t size) noexcept; +#endif // __cplusplus >= 201402L + +[[gnu::weak]] void operator delete(void* ptr, const std::nothrow_t& tag) noexcept; +[[gnu::weak]] void operator delete[](void* ptr, const std::nothrow_t& tag) noexcept; + +void operator delete(void* ptr, void* place) noexcept; +void operator delete[](void* ptr, void* place) noexcept; + +#endif + diff --git a/cores/arduino/new.cpp b/cores/arduino/new.cpp index fc30cf887..7ca493169 100644 --- a/cores/arduino/new.cpp +++ b/cores/arduino/new.cpp @@ -16,26 +16,102 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#include +#include "new.h" -void *operator new(size_t size) { - return malloc(size); +// The C++ spec dictates that allocation failure should cause the +// (non-nothrow version of the) operator new to throw an exception. +// Since we expect to have exceptions disabled, it would be more +// appropriate (and probably standards-compliant) to terminate instead. +// Historically failure causes null to be returned, but this define +// allows switching to more robust terminating behaviour (that might +// become the default at some point in the future). Note that any code +// that wants null to be returned can (and should) use the nothrow +// versions of the new statement anyway and is unaffected by this. +// #define NEW_TERMINATES_ON_FAILURE + +namespace std { + // Defined in abi.cpp + void terminate(); + + const nothrow_t nothrow; } -void *operator new[](size_t size) { +static void * new_helper(std::size_t size) { + // Even zero-sized allocations should return a unique pointer, but + // malloc does not guarantee this + if (size == 0) + size = 1; return malloc(size); } -void * operator new(size_t size, void * ptr) noexcept { - (void)size; - return ptr; +void * operator new(std::size_t size) { + void *res = new_helper(size); +#if defined(NEW_TERMINATES_ON_FAILURE) + if (!res) + std::terminate(); +#endif + return res; +} +void * operator new[](std::size_t size) { + return operator new(size); } -void operator delete(void * ptr) { - free(ptr); +void * operator new(std::size_t size, const std::nothrow_t tag) noexcept { +#if defined(NEW_TERMINATES_ON_FAILURE) + // Cannot call throwing operator new as standard suggests, so call + // new_helper directly then + return new_helper(size); +#else + return operator new(size); +#endif +} +void * operator new[](std::size_t size, const std::nothrow_t& tag) noexcept { +#if defined(NEW_TERMINATES_ON_FAILURE) + // Cannot call throwing operator new[] as standard suggests, so call + // malloc directly then + return new_helper(size); +#else + return operator new[](size); +#endif +} + +void * operator new(std::size_t size, void *place) noexcept { + // Nothing to do + (void)size; // unused + return place; +} +void * operator new[](std::size_t size, void *place) noexcept { + return operator new(size, place); } -void operator delete[](void * ptr) { +void operator delete(void * ptr) noexcept { free(ptr); } +void operator delete[](void * ptr) noexcept { + operator delete(ptr); +} +#if __cplusplus >= 201402L +void operator delete(void* ptr, std::size_t size) noexcept { + operator delete(ptr); +} +void operator delete[](void * ptr, std::size_t size) noexcept { + operator delete[](ptr); +} +#endif // __cplusplus >= 201402L + +void operator delete(void* ptr, const std::nothrow_t& tag) noexcept { + operator delete(ptr); +} +void operator delete[](void* ptr, const std::nothrow_t& tag) noexcept { + operator delete[](ptr); +} + +void operator delete(void* ptr, void* place) noexcept { + (void)ptr; (void)place; // unused + // Nothing to do +} +void operator delete[](void* ptr, void* place) noexcept { + (void)ptr; (void)place; // unused + // Nothing to do +} diff --git a/cores/arduino/new.h b/cores/arduino/new.h index 763f5cca3..d52985368 100644 --- a/cores/arduino/new.h +++ b/cores/arduino/new.h @@ -1,31 +1,3 @@ -/* - Copyright (c) 2014 Arduino. All right reserved. - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - See the GNU Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -*/ - -#ifndef NEW_H -#define NEW_H - -#include - -void * operator new(size_t size); -void * operator new[](size_t size); -void * operator new(size_t size, void * ptr) noexcept; -void operator delete(void * ptr); -void operator delete[](void * ptr); - -#endif - +// This file originally used a non-standard name for this Arduino core +// only, so still expose the old new.h name for compatibility. +#include "new" diff --git a/cores/arduino/wiring.c b/cores/arduino/wiring.c index 972713581..8caf45521 100644 --- a/cores/arduino/wiring.c +++ b/cores/arduino/wiring.c @@ -125,7 +125,7 @@ void delayMicroseconds(unsigned int us) // 2 microseconds) gives delays longer than desired. //delay_us(us); #if F_CPU >= 24000000L - // for the 24 MHz clock for the aventurous ones, trying to overclock + // for the 24 MHz clock for the adventurous ones trying to overclock // zero delay fix if (!us) return; // = 3 cycles, (4 when true) @@ -135,9 +135,9 @@ void delayMicroseconds(unsigned int us) // delay requested. us *= 6; // x6 us, = 7 cycles - // account for the time taken in the preceeding commands. + // account for the time taken in the preceding commands. // we just burned 22 (24) cycles above, remove 5, (5*4=20) - // us is at least 6 so we can substract 5 + // us is at least 6 so we can subtract 5 us -= 5; //=2 cycles #elif F_CPU >= 20000000L @@ -157,9 +157,9 @@ void delayMicroseconds(unsigned int us) // delay requested. us = (us << 2) + us; // x5 us, = 7 cycles - // account for the time taken in the preceeding commands. + // account for the time taken in the preceding commands. // we just burned 26 (28) cycles above, remove 7, (7*4=28) - // us is at least 10 so we can substract 7 + // us is at least 10 so we can subtract 7 us -= 7; // 2 cycles #elif F_CPU >= 16000000L @@ -174,9 +174,9 @@ void delayMicroseconds(unsigned int us) // delay requested. us <<= 2; // x4 us, = 4 cycles - // account for the time taken in the preceeding commands. + // account for the time taken in the preceding commands. // we just burned 19 (21) cycles above, remove 5, (5*4=20) - // us is at least 8 so we can substract 5 + // us is at least 8 so we can subtract 5 us -= 5; // = 2 cycles, #elif F_CPU >= 12000000L @@ -191,9 +191,9 @@ void delayMicroseconds(unsigned int us) // delay requested. us = (us << 1) + us; // x3 us, = 5 cycles - // account for the time taken in the preceeding commands. + // account for the time taken in the preceding commands. // we just burned 20 (22) cycles above, remove 5, (5*4=20) - // us is at least 6 so we can substract 5 + // us is at least 6 so we can subtract 5 us -= 5; //2 cycles #elif F_CPU >= 8000000L @@ -208,9 +208,9 @@ void delayMicroseconds(unsigned int us) // delay requested. us <<= 1; //x2 us, = 2 cycles - // account for the time taken in the preceeding commands. + // account for the time taken in the preceding commands. // we just burned 17 (19) cycles above, remove 4, (4*4=16) - // us is at least 6 so we can substract 4 + // us is at least 6 so we can subtract 4 us -= 4; // = 2 cycles #else @@ -218,9 +218,9 @@ void delayMicroseconds(unsigned int us) // the overhead of the function calls is 14 (16) cycles if (us <= 16) return; //= 3 cycles, (4 when true) - if (us <= 25) return; //= 3 cycles, (4 when true), (must be at least 25 if we want to substract 22) + if (us <= 25) return; //= 3 cycles, (4 when true), (must be at least 25 if we want to subtract 22) - // compensate for the time taken by the preceeding and next commands (about 22 cycles) + // compensate for the time taken by the preceding and next commands (about 22 cycles) us -= 22; // = 2 cycles // the following loop takes 4 microseconds (4 cycles) // per iteration, so execute it us/4 times diff --git a/cores/arduino/wiring_analog.c b/cores/arduino/wiring_analog.c index 967c2b976..0de64f785 100644 --- a/cores/arduino/wiring_analog.c +++ b/cores/arduino/wiring_analog.c @@ -37,7 +37,6 @@ void analogReference(uint8_t mode) int analogRead(uint8_t pin) { - uint8_t low, high; #if defined(analogPinToChannel) #if defined(__AVR_ATmega32U4__) @@ -74,27 +73,20 @@ int analogRead(uint8_t pin) // without a delay, we seem to read from the wrong channel //delay(1); -#if defined(ADCSRA) && defined(ADCL) +#if defined(ADCSRA) && defined(ADC) // start the conversion sbi(ADCSRA, ADSC); // ADSC is cleared when the conversion finishes while (bit_is_set(ADCSRA, ADSC)); - // we have to read ADCL first; doing so locks both ADCL - // and ADCH until ADCH is read. reading ADCL second would - // cause the results of each conversion to be discarded, - // as ADCL and ADCH would be locked when it completed. - low = ADCL; - high = ADCH; + // ADC macro takes care of reading ADC register. + // avr-gcc implements the proper reading order: ADCL is read first. + return ADC; #else // we dont have an ADC, return 0 - low = 0; - high = 0; + return 0; #endif - - // combine the two bytes - return (high << 8) | low; } // Right now, PWM output only works on the pins with @@ -164,7 +156,7 @@ void analogWrite(uint8_t pin, int val) #if defined(TCCR1A) && defined(COM1C1) case TIMER1C: - // connect pwm to pin on timer 1, channel B + // connect pwm to pin on timer 1, channel C sbi(TCCR1A, COM1C1); OCR1C = val; // set pwm duty break; diff --git a/cores/arduino/wiring_digital.c b/cores/arduino/wiring_digital.c index 27a62fc6c..432a15065 100644 --- a/cores/arduino/wiring_digital.c +++ b/cores/arduino/wiring_digital.c @@ -67,7 +67,7 @@ void pinMode(uint8_t pin, uint8_t mode) // // Mark Sproul: // - Removed inline. Save 170 bytes on atmega1280 -// - changed to a switch statment; added 32 bytes but much easier to read and maintain. +// - changed to a switch statement; added 32 bytes but much easier to read and maintain. // - Added more #ifdefs, now compiles for atmega645 // //static inline void turnOffPWM(uint8_t timer) __attribute__ ((always_inline)); diff --git a/drivers/AdafruitCircuitPlayground.cat b/drivers/AdafruitCircuitPlayground.cat new file mode 100644 index 000000000..4bc53bc90 Binary files /dev/null and b/drivers/AdafruitCircuitPlayground.cat differ diff --git a/drivers/AdafruitCircuitPlayground.inf b/drivers/AdafruitCircuitPlayground.inf new file mode 100644 index 000000000..cb8b836f9 --- /dev/null +++ b/drivers/AdafruitCircuitPlayground.inf @@ -0,0 +1,109 @@ +;************************************************************ +; Windows USB CDC ACM Setup File +; Copyright (c) 2000 Microsoft Corporation +; For Adafruit Circuit Playground Board by Adafruit Industries LLC 2016 + +[Version] +Signature="$Windows NT$" +Class=Ports +ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} +Provider=%MFGNAME% +LayoutFile=layout.inf +CatalogFile=%MFGFILENAME%.cat +DriverVer=02/25/2016,6.2.2600.0 + +[Manufacturer] +%MFGNAME%=DeviceList, NTamd64 + +[DestinationDirs] +DefaultDestDir=12 + +[DefaultInstall] +CopyINF="AdafruitCircuitPlayground.inf" + +;------------------------------------------------------------------------------ +; Windows 2000/XP/Vista/Win7/Win8/Win8.1/Win10 32 bit Sections +;------------------------------------------------------------------------------ + +[DriverInstall.nt] +include=mdmcpq.inf +CopyFiles=DriverCopyFiles.nt +AddReg=DriverInstall.nt.AddReg + +[DriverCopyFiles.nt] +usbser.sys,,,0x20 + +[DriverInstall.nt.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,%DRIVERFILENAME%.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.nt.Services] +AddService=usbser, 0x00000002, DriverService.nt + +[DriverService.nt] +DisplayName=%SERVICE% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\%DRIVERFILENAME%.sys + +;------------------------------------------------------------------------------ +; Vista/Win7/Win8/Win8.1/Win10 64 bit Sections +;------------------------------------------------------------------------------ + +[DriverInstall.NTamd64] +include=mdmcpq.inf +CopyFiles=DriverCopyFiles.NTamd64 +AddReg=DriverInstall.NTamd64.AddReg + +[DriverCopyFiles.NTamd64] +%DRIVERFILENAME%.sys,,,0x20 + +[DriverInstall.NTamd64.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,%DRIVERFILENAME%.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.NTamd64.Services] +AddService=usbser, 0x00000002, DriverService.NTamd64 + +[DriverService.NTamd64] +DisplayName=%SERVICE% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\%DRIVERFILENAME%.sys + +;------------------------------------------------------------------------------ +; Vendor and Product ID Definitions +;------------------------------------------------------------------------------ +; When developing your USB device, the VID and PID used in the PC side +; application program and the firmware on the microcontroller must match. +; Modify the below line to use your VID and PID. Use the format as shown below. +; Note: One INF file can be used for multiple devices with different VID and PIDs. +; For each supported device, append ",USB\VID_xxxx&PID_yyyy" to the end of the line. +;------------------------------------------------------------------------------ +[SourceDisksFiles] +[SourceDisksNames] +[DeviceList] +%DESCRIPTION%=DriverInstall, USB\VID_239A&PID_0011 +%DESCRIPTION%=DriverInstall, USB\VID_239A&PID_8011&MI_00 + +[DeviceList.NTamd64] +%DESCRIPTION%=DriverInstall, USB\VID_239A&PID_0011 +%DESCRIPTION%=DriverInstall, USB\VID_239A&PID_8011&MI_00 + +;------------------------------------------------------------------------------ +; String Definitions +;------------------------------------------------------------------------------ +; Modify these strings to customize your device +; NOTE: Do not put spaces in %MFGFILENAME% to maintain Windows 7 compatibility +;------------------------------------------------------------------------------ +[Strings] +MFGFILENAME="AdafruitCircuitPlayground" +DRIVERFILENAME ="usbser" +MFGNAME="Adafruit Industries LLC" +INSTDISK="Circuit Playground Board Driver Installer" +DESCRIPTION="Adafruit Circuit Playground" +SERVICE="USB RS-232 Emulation Driver" \ No newline at end of file diff --git a/drivers/FTDI USB Drivers/Static/amd64/ftd2xx.lib b/drivers/FTDI USB Drivers/Static/amd64/ftd2xx.lib new file mode 100644 index 000000000..ab5e81273 Binary files /dev/null and b/drivers/FTDI USB Drivers/Static/amd64/ftd2xx.lib differ diff --git a/drivers/FTDI USB Drivers/Static/i386/ftd2xx.lib b/drivers/FTDI USB Drivers/Static/i386/ftd2xx.lib new file mode 100644 index 000000000..eb54e5202 Binary files /dev/null and b/drivers/FTDI USB Drivers/Static/i386/ftd2xx.lib differ diff --git a/drivers/FTDI USB Drivers/amd64/ftbusui.dll b/drivers/FTDI USB Drivers/amd64/ftbusui.dll new file mode 100644 index 000000000..cab5e6bed Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftbusui.dll differ diff --git a/drivers/FTDI USB Drivers/amd64/ftcserco.dll b/drivers/FTDI USB Drivers/amd64/ftcserco.dll new file mode 100644 index 000000000..ad02c2ded Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftcserco.dll differ diff --git a/drivers/FTDI USB Drivers/amd64/ftd2xx.lib b/drivers/FTDI USB Drivers/amd64/ftd2xx.lib new file mode 100644 index 000000000..7b28fab0d Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftd2xx.lib differ diff --git a/drivers/FTDI USB Drivers/amd64/ftd2xx64.dll b/drivers/FTDI USB Drivers/amd64/ftd2xx64.dll new file mode 100644 index 000000000..bd6246a50 Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftd2xx64.dll differ diff --git a/drivers/FTDI USB Drivers/amd64/ftdibus.sys b/drivers/FTDI USB Drivers/amd64/ftdibus.sys new file mode 100644 index 000000000..d803f07b2 Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftdibus.sys differ diff --git a/drivers/FTDI USB Drivers/amd64/ftlang.dll b/drivers/FTDI USB Drivers/amd64/ftlang.dll new file mode 100644 index 000000000..23987a6b5 Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftlang.dll differ diff --git a/drivers/FTDI USB Drivers/amd64/ftser2k.sys b/drivers/FTDI USB Drivers/amd64/ftser2k.sys new file mode 100644 index 000000000..f146245c2 Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftser2k.sys differ diff --git a/drivers/FTDI USB Drivers/amd64/ftserui2.dll b/drivers/FTDI USB Drivers/amd64/ftserui2.dll new file mode 100644 index 000000000..e1708b220 Binary files /dev/null and b/drivers/FTDI USB Drivers/amd64/ftserui2.dll differ diff --git a/drivers/FTDI USB Drivers/ftd2xx.h b/drivers/FTDI USB Drivers/ftd2xx.h new file mode 100644 index 000000000..322526859 --- /dev/null +++ b/drivers/FTDI USB Drivers/ftd2xx.h @@ -0,0 +1,1667 @@ +/*++ + +Copyright © 2001-2021 Future Technology Devices International Limited + +THIS SOFTWARE IS PROVIDED BY FUTURE TECHNOLOGY DEVICES INTERNATIONAL LIMITED "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +FUTURE TECHNOLOGY DEVICES INTERNATIONAL LIMITED BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT +OF SUBSTITUTE GOODS OR SERVICES LOSS OF USE, DATA, OR PROFITS OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, +EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +FTDI DRIVERS MAY BE USED ONLY IN CONJUNCTION WITH PRODUCTS BASED ON FTDI PARTS. + +FTDI DRIVERS MAY BE DISTRIBUTED IN ANY FORM AS LONG AS LICENSE INFORMATION IS NOT MODIFIED. + +IF A CUSTOM VENDOR ID AND/OR PRODUCT ID OR DESCRIPTION STRING ARE USED, IT IS THE +RESPONSIBILITY OF THE PRODUCT MANUFACTURER TO MAINTAIN ANY CHANGES AND SUBSEQUENT WHQL +RE-CERTIFICATION AS A RESULT OF MAKING THESE CHANGES. + + +Module Name: + +ftd2xx.h + +Abstract: + +Native USB device driver for FTDI FT232x, FT245x, FT2232x, FT4232x, FT2233H and FT4233H devices +FTD2XX library definitions + +Environment: + +kernel & user mode + + +--*/ + + +#ifndef FTD2XX_H +#define FTD2XX_H + +#ifdef _WIN32 +// Compiling on Windows +#include + +// The following ifdef block is the standard way of creating macros +// which make exporting from a DLL simpler. All files within this DLL +// are compiled with the FTD2XX_EXPORTS symbol defined on the command line. +// This symbol should not be defined on any project that uses this DLL. +// This way any other project whose source files include this file see +// FTD2XX_API functions as being imported from a DLL, whereas this DLL +// sees symbols defined with this macro as being exported. + +#ifdef FTD2XX_EXPORTS +#define FTD2XX_API __declspec(dllexport) +#elif defined(FTD2XX_STATIC) +// Avoid decorations when linking statically to D2XX. +#define FTD2XX_API +// Static D2XX depends on these Windows libs: +#pragma comment(lib, "setupapi.lib") +#pragma comment(lib, "advapi32.lib") +#pragma comment(lib, "user32.lib") +#else +#define FTD2XX_API __declspec(dllimport) +#endif + +#else // _WIN32 +// Compiling on non-Windows platform. +#include "WinTypes.h" +// No decorations needed. +#define FTD2XX_API + +#endif // _WIN32 + +typedef PVOID FT_HANDLE; +typedef ULONG FT_STATUS; + +// +// Device status +// +enum { + FT_OK, + FT_INVALID_HANDLE, + FT_DEVICE_NOT_FOUND, + FT_DEVICE_NOT_OPENED, + FT_IO_ERROR, + FT_INSUFFICIENT_RESOURCES, + FT_INVALID_PARAMETER, + FT_INVALID_BAUD_RATE, + + FT_DEVICE_NOT_OPENED_FOR_ERASE, + FT_DEVICE_NOT_OPENED_FOR_WRITE, + FT_FAILED_TO_WRITE_DEVICE, + FT_EEPROM_READ_FAILED, + FT_EEPROM_WRITE_FAILED, + FT_EEPROM_ERASE_FAILED, + FT_EEPROM_NOT_PRESENT, + FT_EEPROM_NOT_PROGRAMMED, + FT_INVALID_ARGS, + FT_NOT_SUPPORTED, + FT_OTHER_ERROR, + FT_DEVICE_LIST_NOT_READY, +}; + + +#define FT_SUCCESS(status) ((status) == FT_OK) + +// +// FT_OpenEx Flags +// + +#define FT_OPEN_BY_SERIAL_NUMBER 1 +#define FT_OPEN_BY_DESCRIPTION 2 +#define FT_OPEN_BY_LOCATION 4 + +#define FT_OPEN_MASK (FT_OPEN_BY_SERIAL_NUMBER | \ + FT_OPEN_BY_DESCRIPTION | \ + FT_OPEN_BY_LOCATION) + +// +// FT_ListDevices Flags (used in conjunction with FT_OpenEx Flags +// + +#define FT_LIST_NUMBER_ONLY 0x80000000 +#define FT_LIST_BY_INDEX 0x40000000 +#define FT_LIST_ALL 0x20000000 + +#define FT_LIST_MASK (FT_LIST_NUMBER_ONLY|FT_LIST_BY_INDEX|FT_LIST_ALL) + +// +// Baud Rates +// + +#define FT_BAUD_300 300 +#define FT_BAUD_600 600 +#define FT_BAUD_1200 1200 +#define FT_BAUD_2400 2400 +#define FT_BAUD_4800 4800 +#define FT_BAUD_9600 9600 +#define FT_BAUD_14400 14400 +#define FT_BAUD_19200 19200 +#define FT_BAUD_38400 38400 +#define FT_BAUD_57600 57600 +#define FT_BAUD_115200 115200 +#define FT_BAUD_230400 230400 +#define FT_BAUD_460800 460800 +#define FT_BAUD_921600 921600 + +// +// Word Lengths +// + +#define FT_BITS_8 (UCHAR) 8 +#define FT_BITS_7 (UCHAR) 7 + +// +// Stop Bits +// + +#define FT_STOP_BITS_1 (UCHAR) 0 +#define FT_STOP_BITS_2 (UCHAR) 2 + +// +// Parity +// + +#define FT_PARITY_NONE (UCHAR) 0 +#define FT_PARITY_ODD (UCHAR) 1 +#define FT_PARITY_EVEN (UCHAR) 2 +#define FT_PARITY_MARK (UCHAR) 3 +#define FT_PARITY_SPACE (UCHAR) 4 + +// +// Flow Control +// + +#define FT_FLOW_NONE 0x0000 +#define FT_FLOW_RTS_CTS 0x0100 +#define FT_FLOW_DTR_DSR 0x0200 +#define FT_FLOW_XON_XOFF 0x0400 + +// +// Purge rx and tx buffers +// +#define FT_PURGE_RX 1 +#define FT_PURGE_TX 2 + +// +// Events +// + +typedef void(*PFT_EVENT_HANDLER)(DWORD, DWORD); + +#define FT_EVENT_RXCHAR 1 +#define FT_EVENT_MODEM_STATUS 2 +#define FT_EVENT_LINE_STATUS 4 + +// +// Timeouts +// + +#define FT_DEFAULT_RX_TIMEOUT 300 +#define FT_DEFAULT_TX_TIMEOUT 300 + +// +// Device types +// + +typedef ULONG FT_DEVICE; + +enum { + FT_DEVICE_BM, + FT_DEVICE_AM, + FT_DEVICE_100AX, + FT_DEVICE_UNKNOWN, + FT_DEVICE_2232C, + FT_DEVICE_232R, + FT_DEVICE_2232H, + FT_DEVICE_4232H, + FT_DEVICE_232H, + FT_DEVICE_X_SERIES, + FT_DEVICE_4222H_0, + FT_DEVICE_4222H_1_2, + FT_DEVICE_4222H_3, + FT_DEVICE_4222_PROG, + FT_DEVICE_900, + FT_DEVICE_930, + FT_DEVICE_UMFTPD3A, + FT_DEVICE_2233HP, + FT_DEVICE_4233HP, + FT_DEVICE_2232HP, + FT_DEVICE_4232HP, + FT_DEVICE_233HP, + FT_DEVICE_232HP, + FT_DEVICE_2232HA, + FT_DEVICE_4232HA, + FT_DEVICE_232RN, +}; + +// +// Bit Modes +// + +#define FT_BITMODE_RESET 0x00 +#define FT_BITMODE_ASYNC_BITBANG 0x01 +#define FT_BITMODE_MPSSE 0x02 +#define FT_BITMODE_SYNC_BITBANG 0x04 +#define FT_BITMODE_MCU_HOST 0x08 +#define FT_BITMODE_FAST_SERIAL 0x10 +#define FT_BITMODE_CBUS_BITBANG 0x20 +#define FT_BITMODE_SYNC_FIFO 0x40 + +// +// FT232R CBUS Options EEPROM values +// + +#define FT_232R_CBUS_TXDEN 0x00 // Tx Data Enable +#define FT_232R_CBUS_PWRON 0x01 // Power On +#define FT_232R_CBUS_RXLED 0x02 // Rx LED +#define FT_232R_CBUS_TXLED 0x03 // Tx LED +#define FT_232R_CBUS_TXRXLED 0x04 // Tx and Rx LED +#define FT_232R_CBUS_SLEEP 0x05 // Sleep +#define FT_232R_CBUS_CLK48 0x06 // 48MHz clock +#define FT_232R_CBUS_CLK24 0x07 // 24MHz clock +#define FT_232R_CBUS_CLK12 0x08 // 12MHz clock +#define FT_232R_CBUS_CLK6 0x09 // 6MHz clock +#define FT_232R_CBUS_IOMODE 0x0A // IO Mode for CBUS bit-bang +#define FT_232R_CBUS_BITBANG_WR 0x0B // Bit-bang write strobe +#define FT_232R_CBUS_BITBANG_RD 0x0C // Bit-bang read strobe + +// +// FT232H CBUS Options EEPROM values +// + +#define FT_232H_CBUS_TRISTATE 0x00 // Tristate +#define FT_232H_CBUS_TXLED 0x01 // Tx LED +#define FT_232H_CBUS_RXLED 0x02 // Rx LED +#define FT_232H_CBUS_TXRXLED 0x03 // Tx and Rx LED +#define FT_232H_CBUS_PWREN 0x04 // Power Enable +#define FT_232H_CBUS_SLEEP 0x05 // Sleep +#define FT_232H_CBUS_DRIVE_0 0x06 // Drive pin to logic 0 +#define FT_232H_CBUS_DRIVE_1 0x07 // Drive pin to logic 1 +#define FT_232H_CBUS_IOMODE 0x08 // IO Mode for CBUS bit-bang +#define FT_232H_CBUS_TXDEN 0x09 // Tx Data Enable +#define FT_232H_CBUS_CLK30 0x0A // 30MHz clock +#define FT_232H_CBUS_CLK15 0x0B // 15MHz clock +#define FT_232H_CBUS_CLK7_5 0x0C // 7.5MHz clock + +// +// FT X Series CBUS Options EEPROM values +// + +#define FT_X_SERIES_CBUS_TRISTATE 0x00 // Tristate +#define FT_X_SERIES_CBUS_TXLED 0x01 // Tx LED +#define FT_X_SERIES_CBUS_RXLED 0x02 // Rx LED +#define FT_X_SERIES_CBUS_TXRXLED 0x03 // Tx and Rx LED +#define FT_X_SERIES_CBUS_PWREN 0x04 // Power Enable +#define FT_X_SERIES_CBUS_SLEEP 0x05 // Sleep +#define FT_X_SERIES_CBUS_DRIVE_0 0x06 // Drive pin to logic 0 +#define FT_X_SERIES_CBUS_DRIVE_1 0x07 // Drive pin to logic 1 +#define FT_X_SERIES_CBUS_IOMODE 0x08 // IO Mode for CBUS bit-bang +#define FT_X_SERIES_CBUS_TXDEN 0x09 // Tx Data Enable +#define FT_X_SERIES_CBUS_CLK24 0x0A // 24MHz clock +#define FT_X_SERIES_CBUS_CLK12 0x0B // 12MHz clock +#define FT_X_SERIES_CBUS_CLK6 0x0C // 6MHz clock +#define FT_X_SERIES_CBUS_BCD_CHARGER 0x0D // Battery charger detected +#define FT_X_SERIES_CBUS_BCD_CHARGER_N 0x0E // Battery charger detected inverted +#define FT_X_SERIES_CBUS_I2C_TXE 0x0F // I2C Tx empty +#define FT_X_SERIES_CBUS_I2C_RXF 0x10 // I2C Rx full +#define FT_X_SERIES_CBUS_VBUS_SENSE 0x11 // Detect VBUS +#define FT_X_SERIES_CBUS_BITBANG_WR 0x12 // Bit-bang write strobe +#define FT_X_SERIES_CBUS_BITBANG_RD 0x13 // Bit-bang read strobe +#define FT_X_SERIES_CBUS_TIMESTAMP 0x14 // Toggle output when a USB SOF token is received +#define FT_X_SERIES_CBUS_KEEP_AWAKE 0x15 // + + +// Driver types +#define FT_DRIVER_TYPE_D2XX 0 +#define FT_DRIVER_TYPE_VCP 1 + + + +#ifdef __cplusplus +extern "C" { +#endif + + +#ifdef FTD2XX_STATIC + FTD2XX_API + FT_STATUS WINAPI FT_Initialise( + void + ); + + FTD2XX_API + void WINAPI FT_Finalise( + void + ); +#endif // FTD2XX_STATIC + + FTD2XX_API + FT_STATUS WINAPI FT_Open( + int deviceNumber, + FT_HANDLE *pHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_OpenEx( + PVOID pArg1, + DWORD Flags, + FT_HANDLE *pHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ListDevices( + PVOID pArg1, + PVOID pArg2, + DWORD Flags + ); + + FTD2XX_API + FT_STATUS WINAPI FT_Close( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_Read( + FT_HANDLE ftHandle, + LPVOID lpBuffer, + DWORD dwBytesToRead, + LPDWORD lpBytesReturned + ); + + FTD2XX_API + FT_STATUS WINAPI FT_Write( + FT_HANDLE ftHandle, + LPVOID lpBuffer, + DWORD dwBytesToWrite, + LPDWORD lpBytesWritten + ); + + FTD2XX_API + FT_STATUS WINAPI FT_IoCtl( + FT_HANDLE ftHandle, + DWORD dwIoControlCode, + LPVOID lpInBuf, + DWORD nInBufSize, + LPVOID lpOutBuf, + DWORD nOutBufSize, + LPDWORD lpBytesReturned, + LPOVERLAPPED lpOverlapped + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetBaudRate( + FT_HANDLE ftHandle, + ULONG BaudRate + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetDivisor( + FT_HANDLE ftHandle, + USHORT Divisor + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetDataCharacteristics( + FT_HANDLE ftHandle, + UCHAR WordLength, + UCHAR StopBits, + UCHAR Parity + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetFlowControl( + FT_HANDLE ftHandle, + USHORT FlowControl, + UCHAR XonChar, + UCHAR XoffChar + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ResetDevice( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetDtr( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ClrDtr( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetRts( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ClrRts( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetModemStatus( + FT_HANDLE ftHandle, + ULONG *pModemStatus + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetChars( + FT_HANDLE ftHandle, + UCHAR EventChar, + UCHAR EventCharEnabled, + UCHAR ErrorChar, + UCHAR ErrorCharEnabled + ); + + FTD2XX_API + FT_STATUS WINAPI FT_Purge( + FT_HANDLE ftHandle, + ULONG Mask + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetTimeouts( + FT_HANDLE ftHandle, + ULONG ReadTimeout, + ULONG WriteTimeout + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetQueueStatus( + FT_HANDLE ftHandle, + DWORD *dwRxBytes + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetEventNotification( + FT_HANDLE ftHandle, + DWORD Mask, + PVOID Param + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetStatus( + FT_HANDLE ftHandle, + DWORD *dwRxBytes, + DWORD *dwTxBytes, + DWORD *dwEventDWord + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetBreakOn( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetBreakOff( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetWaitMask( + FT_HANDLE ftHandle, + DWORD Mask + ); + + FTD2XX_API + FT_STATUS WINAPI FT_WaitOnMask( + FT_HANDLE ftHandle, + DWORD *Mask + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetEventStatus( + FT_HANDLE ftHandle, + DWORD *dwEventDWord + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ReadEE( + FT_HANDLE ftHandle, + DWORD dwWordOffset, + LPWORD lpwValue + ); + + FTD2XX_API + FT_STATUS WINAPI FT_WriteEE( + FT_HANDLE ftHandle, + DWORD dwWordOffset, + WORD wValue + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EraseEE( + FT_HANDLE ftHandle + ); + + // + // structure to hold program data for FT_EE_Program, FT_EE_ProgramEx, FT_EE_Read + // and FT_EE_ReadEx functions + // + typedef struct ft_program_data { + + DWORD Signature1; // Header - must be 0x00000000 + DWORD Signature2; // Header - must be 0xffffffff + DWORD Version; // Header - FT_PROGRAM_DATA version + // 0 = original + // 1 = FT2232 extensions + // 2 = FT232R extensions + // 3 = FT2232H extensions + // 4 = FT4232H extensions + // 5 = FT232H extensions + + WORD VendorId; // 0x0403 + WORD ProductId; // 0x6001 + char *Manufacturer; // "FTDI" + char *ManufacturerId; // "FT" + char *Description; // "USB HS Serial Converter" + char *SerialNumber; // "FT000001" if fixed, or NULL + WORD MaxPower; // 0 < MaxPower <= 500 + WORD PnP; // 0 = disabled, 1 = enabled + WORD SelfPowered; // 0 = bus powered, 1 = self powered + WORD RemoteWakeup; // 0 = not capable, 1 = capable + // + // Rev4 (FT232B) extensions + // + UCHAR Rev4; // non-zero if Rev4 chip, zero otherwise + UCHAR IsoIn; // non-zero if in endpoint is isochronous + UCHAR IsoOut; // non-zero if out endpoint is isochronous + UCHAR PullDownEnable; // non-zero if pull down enabled + UCHAR SerNumEnable; // non-zero if serial number to be used + UCHAR USBVersionEnable; // non-zero if chip uses USBVersion + WORD USBVersion; // BCD (0x0200 => USB2) + // + // Rev 5 (FT2232) extensions + // + UCHAR Rev5; // non-zero if Rev5 chip, zero otherwise + UCHAR IsoInA; // non-zero if in endpoint is isochronous + UCHAR IsoInB; // non-zero if in endpoint is isochronous + UCHAR IsoOutA; // non-zero if out endpoint is isochronous + UCHAR IsoOutB; // non-zero if out endpoint is isochronous + UCHAR PullDownEnable5; // non-zero if pull down enabled + UCHAR SerNumEnable5; // non-zero if serial number to be used + UCHAR USBVersionEnable5; // non-zero if chip uses USBVersion + WORD USBVersion5; // BCD (0x0200 => USB2) + UCHAR AIsHighCurrent; // non-zero if interface is high current + UCHAR BIsHighCurrent; // non-zero if interface is high current + UCHAR IFAIsFifo; // non-zero if interface is 245 FIFO + UCHAR IFAIsFifoTar; // non-zero if interface is 245 FIFO CPU target + UCHAR IFAIsFastSer; // non-zero if interface is Fast serial + UCHAR AIsVCP; // non-zero if interface is to use VCP drivers + UCHAR IFBIsFifo; // non-zero if interface is 245 FIFO + UCHAR IFBIsFifoTar; // non-zero if interface is 245 FIFO CPU target + UCHAR IFBIsFastSer; // non-zero if interface is Fast serial + UCHAR BIsVCP; // non-zero if interface is to use VCP drivers + // + // Rev 6 (FT232R) extensions + // + UCHAR UseExtOsc; // Use External Oscillator + UCHAR HighDriveIOs; // High Drive I/Os + UCHAR EndpointSize; // Endpoint size + UCHAR PullDownEnableR; // non-zero if pull down enabled + UCHAR SerNumEnableR; // non-zero if serial number to be used + UCHAR InvertTXD; // non-zero if invert TXD + UCHAR InvertRXD; // non-zero if invert RXD + UCHAR InvertRTS; // non-zero if invert RTS + UCHAR InvertCTS; // non-zero if invert CTS + UCHAR InvertDTR; // non-zero if invert DTR + UCHAR InvertDSR; // non-zero if invert DSR + UCHAR InvertDCD; // non-zero if invert DCD + UCHAR InvertRI; // non-zero if invert RI + UCHAR Cbus0; // Cbus Mux control + UCHAR Cbus1; // Cbus Mux control + UCHAR Cbus2; // Cbus Mux control + UCHAR Cbus3; // Cbus Mux control + UCHAR Cbus4; // Cbus Mux control + UCHAR RIsD2XX; // non-zero if using D2XX driver + // + // Rev 7 (FT2232H) Extensions + // + UCHAR PullDownEnable7; // non-zero if pull down enabled + UCHAR SerNumEnable7; // non-zero if serial number to be used + UCHAR ALSlowSlew; // non-zero if AL pins have slow slew + UCHAR ALSchmittInput; // non-zero if AL pins are Schmitt input + UCHAR ALDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR AHSlowSlew; // non-zero if AH pins have slow slew + UCHAR AHSchmittInput; // non-zero if AH pins are Schmitt input + UCHAR AHDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR BLSlowSlew; // non-zero if BL pins have slow slew + UCHAR BLSchmittInput; // non-zero if BL pins are Schmitt input + UCHAR BLDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR BHSlowSlew; // non-zero if BH pins have slow slew + UCHAR BHSchmittInput; // non-zero if BH pins are Schmitt input + UCHAR BHDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR IFAIsFifo7; // non-zero if interface is 245 FIFO + UCHAR IFAIsFifoTar7; // non-zero if interface is 245 FIFO CPU target + UCHAR IFAIsFastSer7; // non-zero if interface is Fast serial + UCHAR AIsVCP7; // non-zero if interface is to use VCP drivers + UCHAR IFBIsFifo7; // non-zero if interface is 245 FIFO + UCHAR IFBIsFifoTar7; // non-zero if interface is 245 FIFO CPU target + UCHAR IFBIsFastSer7; // non-zero if interface is Fast serial + UCHAR BIsVCP7; // non-zero if interface is to use VCP drivers + UCHAR PowerSaveEnable; // non-zero if using BCBUS7 to save power for self-powered designs + // + // Rev 8 (FT4232H) Extensions + // + UCHAR PullDownEnable8; // non-zero if pull down enabled + UCHAR SerNumEnable8; // non-zero if serial number to be used + UCHAR ASlowSlew; // non-zero if A pins have slow slew + UCHAR ASchmittInput; // non-zero if A pins are Schmitt input + UCHAR ADriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR BSlowSlew; // non-zero if B pins have slow slew + UCHAR BSchmittInput; // non-zero if B pins are Schmitt input + UCHAR BDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR CSlowSlew; // non-zero if C pins have slow slew + UCHAR CSchmittInput; // non-zero if C pins are Schmitt input + UCHAR CDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR DSlowSlew; // non-zero if D pins have slow slew + UCHAR DSchmittInput; // non-zero if D pins are Schmitt input + UCHAR DDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR ARIIsTXDEN; // non-zero if port A uses RI as RS485 TXDEN + UCHAR BRIIsTXDEN; // non-zero if port B uses RI as RS485 TXDEN + UCHAR CRIIsTXDEN; // non-zero if port C uses RI as RS485 TXDEN + UCHAR DRIIsTXDEN; // non-zero if port D uses RI as RS485 TXDEN + UCHAR AIsVCP8; // non-zero if interface is to use VCP drivers + UCHAR BIsVCP8; // non-zero if interface is to use VCP drivers + UCHAR CIsVCP8; // non-zero if interface is to use VCP drivers + UCHAR DIsVCP8; // non-zero if interface is to use VCP drivers + // + // Rev 9 (FT232H) Extensions + // + UCHAR PullDownEnableH; // non-zero if pull down enabled + UCHAR SerNumEnableH; // non-zero if serial number to be used + UCHAR ACSlowSlewH; // non-zero if AC pins have slow slew + UCHAR ACSchmittInputH; // non-zero if AC pins are Schmitt input + UCHAR ACDriveCurrentH; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR ADSlowSlewH; // non-zero if AD pins have slow slew + UCHAR ADSchmittInputH; // non-zero if AD pins are Schmitt input + UCHAR ADDriveCurrentH; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR Cbus0H; // Cbus Mux control + UCHAR Cbus1H; // Cbus Mux control + UCHAR Cbus2H; // Cbus Mux control + UCHAR Cbus3H; // Cbus Mux control + UCHAR Cbus4H; // Cbus Mux control + UCHAR Cbus5H; // Cbus Mux control + UCHAR Cbus6H; // Cbus Mux control + UCHAR Cbus7H; // Cbus Mux control + UCHAR Cbus8H; // Cbus Mux control + UCHAR Cbus9H; // Cbus Mux control + UCHAR IsFifoH; // non-zero if interface is 245 FIFO + UCHAR IsFifoTarH; // non-zero if interface is 245 FIFO CPU target + UCHAR IsFastSerH; // non-zero if interface is Fast serial + UCHAR IsFT1248H; // non-zero if interface is FT1248 + UCHAR FT1248CpolH; // FT1248 clock polarity - clock idle high (1) or clock idle low (0) + UCHAR FT1248LsbH; // FT1248 data is LSB (1) or MSB (0) + UCHAR FT1248FlowControlH; // FT1248 flow control enable + UCHAR IsVCPH; // non-zero if interface is to use VCP drivers + UCHAR PowerSaveEnableH; // non-zero if using ACBUS7 to save power for self-powered designs + + } FT_PROGRAM_DATA, *PFT_PROGRAM_DATA; + + FTD2XX_API + FT_STATUS WINAPI FT_EE_Program( + FT_HANDLE ftHandle, + PFT_PROGRAM_DATA pData + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_ProgramEx( + FT_HANDLE ftHandle, + PFT_PROGRAM_DATA pData, + char *Manufacturer, + char *ManufacturerId, + char *Description, + char *SerialNumber + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_Read( + FT_HANDLE ftHandle, + PFT_PROGRAM_DATA pData + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_ReadEx( + FT_HANDLE ftHandle, + PFT_PROGRAM_DATA pData, + char *Manufacturer, + char *ManufacturerId, + char *Description, + char *SerialNumber + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_UASize( + FT_HANDLE ftHandle, + LPDWORD lpdwSize + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_UAWrite( + FT_HANDLE ftHandle, + PUCHAR pucData, + DWORD dwDataLen + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_UARead( + FT_HANDLE ftHandle, + PUCHAR pucData, + DWORD dwDataLen, + LPDWORD lpdwBytesRead + ); + + + typedef struct ft_eeprom_header { + FT_DEVICE deviceType; // FTxxxx device type to be programmed + // Device descriptor options + WORD VendorId; // 0x0403 + WORD ProductId; // 0x6001 + UCHAR SerNumEnable; // non-zero if serial number to be used + // Config descriptor options + WORD MaxPower; // 0 < MaxPower <= 500 + UCHAR SelfPowered; // 0 = bus powered, 1 = self powered + UCHAR RemoteWakeup; // 0 = not capable, 1 = capable + // Hardware options + UCHAR PullDownEnable; // non-zero if pull down in suspend enabled + } FT_EEPROM_HEADER, *PFT_EEPROM_HEADER; + + + // FT232B EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_232b { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + } FT_EEPROM_232B, *PFT_EEPROM_232B; + + + // FT2232 EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_2232 { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + // Drive options + UCHAR AIsHighCurrent; // non-zero if interface is high current + UCHAR BIsHighCurrent; // non-zero if interface is high current + // Hardware options + UCHAR AIsFifo; // non-zero if interface is 245 FIFO + UCHAR AIsFifoTar; // non-zero if interface is 245 FIFO CPU target + UCHAR AIsFastSer; // non-zero if interface is Fast serial + UCHAR BIsFifo; // non-zero if interface is 245 FIFO + UCHAR BIsFifoTar; // non-zero if interface is 245 FIFO CPU target + UCHAR BIsFastSer; // non-zero if interface is Fast serial + // Driver option + UCHAR ADriverType; // non-zero if interface is to use VCP drivers + UCHAR BDriverType; // non-zero if interface is to use VCP drivers + } FT_EEPROM_2232, *PFT_EEPROM_2232; + + + // FT232R EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_232r { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + // Drive options + UCHAR IsHighCurrent; // non-zero if interface is high current + // Hardware options + UCHAR UseExtOsc; // Use External Oscillator + UCHAR InvertTXD; // non-zero if invert TXD + UCHAR InvertRXD; // non-zero if invert RXD + UCHAR InvertRTS; // non-zero if invert RTS + UCHAR InvertCTS; // non-zero if invert CTS + UCHAR InvertDTR; // non-zero if invert DTR + UCHAR InvertDSR; // non-zero if invert DSR + UCHAR InvertDCD; // non-zero if invert DCD + UCHAR InvertRI; // non-zero if invert RI + UCHAR Cbus0; // Cbus Mux control + UCHAR Cbus1; // Cbus Mux control + UCHAR Cbus2; // Cbus Mux control + UCHAR Cbus3; // Cbus Mux control + UCHAR Cbus4; // Cbus Mux control + // Driver option + UCHAR DriverType; // non-zero if using D2XX driver + } FT_EEPROM_232R, *PFT_EEPROM_232R; + + + // FT2232H EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_2232h { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + // Drive options + UCHAR ALSlowSlew; // non-zero if AL pins have slow slew + UCHAR ALSchmittInput; // non-zero if AL pins are Schmitt input + UCHAR ALDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR AHSlowSlew; // non-zero if AH pins have slow slew + UCHAR AHSchmittInput; // non-zero if AH pins are Schmitt input + UCHAR AHDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR BLSlowSlew; // non-zero if BL pins have slow slew + UCHAR BLSchmittInput; // non-zero if BL pins are Schmitt input + UCHAR BLDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR BHSlowSlew; // non-zero if BH pins have slow slew + UCHAR BHSchmittInput; // non-zero if BH pins are Schmitt input + UCHAR BHDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + // Hardware options + UCHAR AIsFifo; // non-zero if interface is 245 FIFO + UCHAR AIsFifoTar; // non-zero if interface is 245 FIFO CPU target + UCHAR AIsFastSer; // non-zero if interface is Fast serial + UCHAR BIsFifo; // non-zero if interface is 245 FIFO + UCHAR BIsFifoTar; // non-zero if interface is 245 FIFO CPU target + UCHAR BIsFastSer; // non-zero if interface is Fast serial + UCHAR PowerSaveEnable; // non-zero if using BCBUS7 to save power for self-powered designs + // Driver option + UCHAR ADriverType; // non-zero if interface is to use VCP drivers + UCHAR BDriverType; // non-zero if interface is to use VCP drivers + } FT_EEPROM_2232H, *PFT_EEPROM_2232H; + + + // FT4232H EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_4232h { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + // Drive options + UCHAR ASlowSlew; // non-zero if A pins have slow slew + UCHAR ASchmittInput; // non-zero if A pins are Schmitt input + UCHAR ADriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR BSlowSlew; // non-zero if B pins have slow slew + UCHAR BSchmittInput; // non-zero if B pins are Schmitt input + UCHAR BDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR CSlowSlew; // non-zero if C pins have slow slew + UCHAR CSchmittInput; // non-zero if C pins are Schmitt input + UCHAR CDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR DSlowSlew; // non-zero if D pins have slow slew + UCHAR DSchmittInput; // non-zero if D pins are Schmitt input + UCHAR DDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + // Hardware options + UCHAR ARIIsTXDEN; // non-zero if port A uses RI as RS485 TXDEN + UCHAR BRIIsTXDEN; // non-zero if port B uses RI as RS485 TXDEN + UCHAR CRIIsTXDEN; // non-zero if port C uses RI as RS485 TXDEN + UCHAR DRIIsTXDEN; // non-zero if port D uses RI as RS485 TXDEN + // Driver option + UCHAR ADriverType; // non-zero if interface is to use VCP drivers + UCHAR BDriverType; // non-zero if interface is to use VCP drivers + UCHAR CDriverType; // non-zero if interface is to use VCP drivers + UCHAR DDriverType; // non-zero if interface is to use VCP drivers + } FT_EEPROM_4232H, *PFT_EEPROM_4232H; + + + // FT232H EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_232h { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + // Drive options + UCHAR ACSlowSlew; // non-zero if AC bus pins have slow slew + UCHAR ACSchmittInput; // non-zero if AC bus pins are Schmitt input + UCHAR ACDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR ADSlowSlew; // non-zero if AD bus pins have slow slew + UCHAR ADSchmittInput; // non-zero if AD bus pins are Schmitt input + UCHAR ADDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + // CBUS options + UCHAR Cbus0; // Cbus Mux control + UCHAR Cbus1; // Cbus Mux control + UCHAR Cbus2; // Cbus Mux control + UCHAR Cbus3; // Cbus Mux control + UCHAR Cbus4; // Cbus Mux control + UCHAR Cbus5; // Cbus Mux control + UCHAR Cbus6; // Cbus Mux control + UCHAR Cbus7; // Cbus Mux control + UCHAR Cbus8; // Cbus Mux control + UCHAR Cbus9; // Cbus Mux control + // FT1248 options + UCHAR FT1248Cpol; // FT1248 clock polarity - clock idle high (1) or clock idle low (0) + UCHAR FT1248Lsb; // FT1248 data is LSB (1) or MSB (0) + UCHAR FT1248FlowControl; // FT1248 flow control enable + // Hardware options + UCHAR IsFifo; // non-zero if interface is 245 FIFO + UCHAR IsFifoTar; // non-zero if interface is 245 FIFO CPU target + UCHAR IsFastSer; // non-zero if interface is Fast serial + UCHAR IsFT1248; // non-zero if interface is FT1248 + UCHAR PowerSaveEnable; // + // Driver option + UCHAR DriverType; // non-zero if interface is to use VCP drivers + } FT_EEPROM_232H, *PFT_EEPROM_232H; + + + // FT X Series EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_x_series { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + // Drive options + UCHAR ACSlowSlew; // non-zero if AC bus pins have slow slew + UCHAR ACSchmittInput; // non-zero if AC bus pins are Schmitt input + UCHAR ACDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR ADSlowSlew; // non-zero if AD bus pins have slow slew + UCHAR ADSchmittInput; // non-zero if AD bus pins are Schmitt input + UCHAR ADDriveCurrent; // valid values are 4mA, 8mA, 12mA, 16mA + // CBUS options + UCHAR Cbus0; // Cbus Mux control + UCHAR Cbus1; // Cbus Mux control + UCHAR Cbus2; // Cbus Mux control + UCHAR Cbus3; // Cbus Mux control + UCHAR Cbus4; // Cbus Mux control + UCHAR Cbus5; // Cbus Mux control + UCHAR Cbus6; // Cbus Mux control + // UART signal options + UCHAR InvertTXD; // non-zero if invert TXD + UCHAR InvertRXD; // non-zero if invert RXD + UCHAR InvertRTS; // non-zero if invert RTS + UCHAR InvertCTS; // non-zero if invert CTS + UCHAR InvertDTR; // non-zero if invert DTR + UCHAR InvertDSR; // non-zero if invert DSR + UCHAR InvertDCD; // non-zero if invert DCD + UCHAR InvertRI; // non-zero if invert RI + // Battery Charge Detect options + UCHAR BCDEnable; // Enable Battery Charger Detection + UCHAR BCDForceCbusPWREN; // asserts the power enable signal on CBUS when charging port detected + UCHAR BCDDisableSleep; // forces the device never to go into sleep mode + // I2C options + WORD I2CSlaveAddress; // I2C slave device address + DWORD I2CDeviceId; // I2C device ID + UCHAR I2CDisableSchmitt; // Disable I2C Schmitt trigger + // FT1248 options + UCHAR FT1248Cpol; // FT1248 clock polarity - clock idle high (1) or clock idle low (0) + UCHAR FT1248Lsb; // FT1248 data is LSB (1) or MSB (0) + UCHAR FT1248FlowControl; // FT1248 flow control enable + // Hardware options + UCHAR RS485EchoSuppress; // + UCHAR PowerSaveEnable; // + // Driver option + UCHAR DriverType; // non-zero if interface is to use VCP drivers + } FT_EEPROM_X_SERIES, *PFT_EEPROM_X_SERIES; + + + // FT4222H EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + typedef struct ft_eeprom_4222h { + // Common header + FT_EEPROM_HEADER common; // common elements for all device EEPROMs + CHAR Revision; // 'A', 'B', 'C', or 'D'. + UCHAR I2C_Slave_Address; + // Suspend + UCHAR SPISuspend; // 0 for "Disable SPI, tristate pins", 2 for "Keep SPI pin status", 3 for "Enable SPI pin control" + UCHAR SuspendOutPol; // 0 for negative, 1 for positive (not implemented on Rev A) + UCHAR EnableSuspendOut; // non-zero to enable (not implemented on Rev A) + // QSPI + UCHAR Clock_SlowSlew; // non-zero if clock pin has slow slew + UCHAR Clock_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR IO0_SlowSlew; // non-zero if IO0 pin has slow slew + UCHAR IO1_SlowSlew; // non-zero if IO1 pin has slow slew + UCHAR IO2_SlowSlew; // non-zero if IO2 pin has slow slew + UCHAR IO3_SlowSlew; // non-zero if IO3 pin has slow slew + UCHAR IO_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR SlaveSelect_PullUp; // non-zero to enable pull up + UCHAR SlaveSelect_PullDown; // non-zero to enable pull down + UCHAR SlaveSelect_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR SlaveSelect_SlowSlew; // non-zero if slave select pin has slow slew + UCHAR MISO_Suspend; // 2 for push-low, 3 for push high, 0 and 1 reserved + UCHAR SIMO_Suspend; // 2 for push-low, 3 for push high, 0 and 1 reserved + UCHAR IO2_IO3_Suspend; // 2 for push-low, 3 for push high, 0 and 1 reserved + UCHAR SlaveSelect_Suspend; // 0 for no-change (not implemented on Rev A), 2 for push-low, 3 for push high, 1 reserved + // GPIO + UCHAR GPIO0_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR GPIO1_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR GPIO2_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR GPIO3_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + UCHAR GPIO0_SlowSlew; // non-zero if IO0 pin has slow slew + UCHAR GPIO1_SlowSlew; // non-zero if IO0 pin has slow slew + UCHAR GPIO2_SlowSlew; // non-zero if IO0 pin has slow slew + UCHAR GPIO3_SlowSlew; // non-zero if IO0 pin has slow slew + UCHAR GPIO0_PullDown; // non-zero to enable pull down + UCHAR GPIO1_PullDown; // non-zero to enable pull down + UCHAR GPIO2_PullDown; // non-zero to enable pull down + UCHAR GPIO3_PullDown; // non-zero to enable pull down + UCHAR GPIO0_PullUp; // non-zero to enable pull up + UCHAR GPIO1_PullUp; // non-zero to enable pull up + UCHAR GPIO2_PullUp; // non-zero to enable pull up + UCHAR GPIO3_PullUp; // non-zero to enable pull up + UCHAR GPIO0_OpenDrain; // non-zero to enable open drain + UCHAR GPIO1_OpenDrain; // non-zero to enable open drain + UCHAR GPIO2_OpenDrain; // non-zero to enable open drain + UCHAR GPIO3_OpenDrain; // non-zero to enable open drain + UCHAR GPIO0_Suspend; // 0 for no-change, 1 for input (not implemented on Rev A), 2 for push-low, 3 for push high + UCHAR GPIO1_Suspend; // 0 for no-change, 1 for input (not implemented on Rev A), 2 for push-low, 3 for push high + UCHAR GPIO2_Suspend; // 0 for no-change, 1 for input (not implemented on Rev A), 2 for push-low, 3 for push high + UCHAR GPIO3_Suspend; // 0 for no-change, 1 for input (not implemented on Rev A), 2 for push-low, 3 for push high + UCHAR FallingEdge; // non-zero to change GPIO on falling edge + // BCD + UCHAR BCD_Disable; // non-zero to disable BCD + UCHAR BCD_OutputActiveLow; // non-zero to set BCD output active low + UCHAR BCD_Drive; // valid values are 4mA, 8mA, 12mA, 16mA + } FT_EEPROM_4222H, *PFT_EEPROM_4222H; + + + // Power Delivery structures for use with FT_EEPROM_Read and FT_EEPROM_Program + // PDO Configuration structure, mA supported values 0 to 10230mA, mV supported values 0 to 51100mV + // This is part of the FT_EEPROM_PD structure. + typedef struct ft_eeprom_PD_PDO_mv_ma { + USHORT PDO1ma; // PDO1 mA + USHORT PDO1mv; // PDO1 mV + USHORT PDO2ma; // PDO2 mA + USHORT PDO2mv; // PDO2 mV + USHORT PDO3ma; // PDO3 mA + USHORT PDO3mv; // PDO3 mV + USHORT PDO4ma; // PDO4 mA + USHORT PDO4mv; // PDO4 mV + USHORT PDO5ma; // PDO5 mA (FTx233HP only) + USHORT PDO5mv; // PDO5 mV (FTx233HP only) + USHORT PDO6ma; // PDO6 mA (FTx233HP only) + USHORT PDO6mv; // PDO6 mV (FTx233HP only) + USHORT PDO7ma; // PDO7 mA (FTx233HP only) + USHORT PDO7mv; // PDO7 mV (FTx233HP only) + } FT_EEPROM_PD_PDO_mv_ma; + + // PD EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + // This is appended to the end of the base device structure. e_g. + // struct { + // FT_EEPROM_xxx base; + // FT_EEPROM_PD pd; + // }; + // Device GPIO values are: + // FTx233HP - 0 to 7, 15 for N/A + // FTx232HP - 0 to 3, 15 for N/A + typedef struct ft_eeprom_pd { + // Configuration + UCHAR srprs; // non-zero to enable Sink Request Power Role Swap + UCHAR sraprs; // non-zero to enable Sink Accept PR Swap + UCHAR srrprs; // non-zero to enable Source Request PR SWAP + UCHAR saprs; // non-zero to enable Source Accept PR SWAP + UCHAR vconns; // non-zero to enable vConn Swap + UCHAR passthru; // non-zero to enable Pass Through (FTx233HP only) + UCHAR extmcu; // non-zero to enable External MCU + UCHAR pd2en; // non-zero to enable PD2 (FTx233HP only) + UCHAR pd1autoclk; // non-zero to enable PD1 Auto Clock + UCHAR pd2autoclk; // non-zero to enable PD2 Auto Clock (FTx233HP only) + UCHAR useefuse; // non-zero to Use EFUSE + UCHAR extvconn; // non-zero to enable External vConn + + // GPIO Configuration + UCHAR count; // GPIO Count, supported values are 0 to 7 + UCHAR gpio1; // GPIO Number 1, supports device GPIO values + UCHAR gpio2; // GPIO Number 2, supports device GPIO values + UCHAR gpio3; // GPIO Number 3, supports device GPIO values + UCHAR gpio4; // GPIO Number 4, supports device GPIO values + UCHAR gpio5; // GPIO Number 5, supports device GPIO values (FTx233HP only) + UCHAR gpio6; // GPIO Number 6, supports device GPIO values (FTx233HP only) + UCHAR gpio7; // GPIO Number 7, supports device GPIO values (FTx233HP only) + UCHAR pd1lden; // PD1 Load Enable, supports device GPIO values + UCHAR pd2lden; // PD2 Load Enable, supports device GPIO values (FTx233HP only) + UCHAR dispin; // Discharge Pin, supports device GPIO values + UCHAR disenbm; // Discharge Enable BM, 0 for "Drive Hi", 1 for "Drive Low", 2 for "Input Mode", 3 for "Don't Care" + UCHAR disdisbm; // Discharge Disable BM, 0 for "Drive Hi", 1 for "Drive Low", 2 for "Input Mode", 3 for "Don't Care" + UCHAR ccselect; // CC Select Indicator, supports device GPIO values + + // ISET Configuration + UCHAR iset1; // ISET1, supports device GPIO values + UCHAR iset2; // ISET2, supports device GPIO values + UCHAR iset3; // ISET3, supports device GPIO values + UCHAR extiset; // non-zero to enable EXTEND_ISET + UCHAR isetpd2; // non-zero to enable ISET_PD2 + UCHAR iseten; // non-zero to set ISET_ENABLED + + // BM Configuration, 0 for "Drive Hi", 1 for "Drive Low", 2 for "Input Mode", 3 for "Don't Care" + UCHAR PDO1_GPIO[7]; // PDO1 GPIO1 to GPIO7 + UCHAR PDO2_GPIO[7]; // PDO2 GPIO1 to GPIO7 + UCHAR PDO3_GPIO[7]; // PDO3 GPIO1 to GPIO7 + UCHAR PDO4_GPIO[7]; // PDO4 GPIO1 to GPIO7 + UCHAR PDO5_GPIO[7]; // PDO5 GPIO1 to GPIO7 (FTx233HP only) + UCHAR PDO6_GPIO[7]; // PDO6 GPIO1 to GPIO7 (FTx233HP only) + UCHAR PDO7_GPIO[7]; // PDO7 GPIO1 to GPIO7 (FTx233HP only) + UCHAR VSET0V_GPIO[7]; // PDO7 GPIO1 to GPIO7 + UCHAR VSAFE5V_GPIO[7]; // PDO7 GPIO1 to GPIO7 + + FT_EEPROM_PD_PDO_mv_ma BM_PDO_Sink; + FT_EEPROM_PD_PDO_mv_ma BM_PDO_Source; + FT_EEPROM_PD_PDO_mv_ma BM_PDO_Sink_2; // (FTx233HP only) + + // PD Timers + UCHAR srt; // Sender Response Timer + UCHAR hrt; // Hard Reset Timer + UCHAR sct; // Source Capability Timer + UCHAR dit; // Discover Identity Timer + USHORT srcrt; // Source Recover Timer + USHORT trt; // Transition Timer + USHORT sofft; // Source off timer + USHORT nrt; // No Response Timer + USHORT swct; // Sink Wait Capability Timer + USHORT snkrt; // Sink Request Timer + UCHAR dt; // Discharge Timer + UCHAR cnst; // Chunk not supported timer + USHORT it; // Idle Timer + + // PD Control + UCHAR i2caddr; // I2C Address (hex) + UINT prou; // Power Reserved for OWN use + UINT trim1; // TRIM1 + UINT trim2; // TRIM2 + UCHAR extdc; // non-zero to enable ETERNAL_DC_POWER + } FT_EEPROM_PD, *PFT_EEPROM_PD; + + // FT2233HP EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + // FT2232H with power delivery + typedef struct _ft_eeprom_2233hp + { + FT_EEPROM_2232H ft2232h; + FT_EEPROM_PD pd; + } FT_EEPROM_2233HP, *PFT_EEPROM_2233HP; + + // FT4233HP EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + // FT4232H with power delivery + typedef struct _ft_eeprom_4233hp + { + FT_EEPROM_4232H ft4232h; + FT_EEPROM_PD pd; + } FT_EEPROM_4233HP, *PFT_EEPROM_4233HP; + + // FT2232HP EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + // FT2232H with power delivery + typedef struct _ft_eeprom_2232hp + { + FT_EEPROM_2232H ft2232h; + FT_EEPROM_PD pd; + } FT_EEPROM_2232HP, *PFT_EEPROM_2232HP; + + // FT4232HP EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + // FT4232H with power delivery + typedef struct _ft_eeprom_4232hp + { + FT_EEPROM_4232H ft4232h; + FT_EEPROM_PD pd; + } FT_EEPROM_4232HP, *PFT_EEPROM_4232HP; + + // FT233HP EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + // FT233H with power delivery + typedef struct _ft_eeprom_233hp + { + FT_EEPROM_232H ft232h; + FT_EEPROM_PD pd; + } FT_EEPROM_233HP, *PFT_EEPROM_233HP; + + // FT232HP EEPROM structure for use with FT_EEPROM_Read and FT_EEPROM_Program + // FT232H with power delivery + typedef struct _ft_eeprom_232hp + { + FT_EEPROM_232H ft232h; + FT_EEPROM_PD pd; + } FT_EEPROM_232HP, *PFT_EEPROM_232HP; + + FTD2XX_API + FT_STATUS WINAPI FT_EEPROM_Read( + FT_HANDLE ftHandle, + void *eepromData, + DWORD eepromDataSize, + char *Manufacturer, + char *ManufacturerId, + char *Description, + char *SerialNumber + ); + + + FTD2XX_API + FT_STATUS WINAPI FT_EEPROM_Program( + FT_HANDLE ftHandle, + void *eepromData, + DWORD eepromDataSize, + char *Manufacturer, + char *ManufacturerId, + char *Description, + char *SerialNumber + ); + + + FTD2XX_API + FT_STATUS WINAPI FT_SetLatencyTimer( + FT_HANDLE ftHandle, + UCHAR ucLatency + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetLatencyTimer( + FT_HANDLE ftHandle, + PUCHAR pucLatency + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetBitMode( + FT_HANDLE ftHandle, + UCHAR ucMask, + UCHAR ucEnable + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetBitMode( + FT_HANDLE ftHandle, + PUCHAR pucMode + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetUSBParameters( + FT_HANDLE ftHandle, + ULONG ulInTransferSize, + ULONG ulOutTransferSize + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetDeadmanTimeout( + FT_HANDLE ftHandle, + ULONG ulDeadmanTimeout + ); + +#ifndef _WIN32 + // Extra functions for non-Windows platforms to compensate + // for lack of .INF file to specify Vendor and Product IDs. + + FTD2XX_API + FT_STATUS FT_SetVIDPID( + DWORD dwVID, + DWORD dwPID + ); + + FTD2XX_API + FT_STATUS FT_GetVIDPID( + DWORD * pdwVID, + DWORD * pdwPID + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetDeviceLocId( + FT_HANDLE ftHandle, + LPDWORD lpdwLocId + ); +#endif // _WIN32 + + FTD2XX_API + FT_STATUS WINAPI FT_GetDeviceInfo( + FT_HANDLE ftHandle, + FT_DEVICE *lpftDevice, + LPDWORD lpdwID, + PCHAR SerialNumber, + PCHAR Description, + LPVOID Dummy + ); + + FTD2XX_API + FT_STATUS WINAPI FT_StopInTask( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_RestartInTask( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_SetResetPipeRetryCount( + FT_HANDLE ftHandle, + DWORD dwCount + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ResetPort( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_CyclePort( + FT_HANDLE ftHandle + ); + + + // + // Win32-type functions + // + + FTD2XX_API + FT_HANDLE WINAPI FT_W32_CreateFile( + LPCTSTR lpszName, + DWORD dwAccess, + DWORD dwShareMode, + LPSECURITY_ATTRIBUTES lpSecurityAttributes, + DWORD dwCreate, + DWORD dwAttrsAndFlags, + HANDLE hTemplate + ); + + FTD2XX_API + BOOL WINAPI FT_W32_CloseHandle( + FT_HANDLE ftHandle + ); + + FTD2XX_API + BOOL WINAPI FT_W32_ReadFile( + FT_HANDLE ftHandle, + LPVOID lpBuffer, + DWORD nBufferSize, + LPDWORD lpBytesReturned, + LPOVERLAPPED lpOverlapped + ); + + FTD2XX_API + BOOL WINAPI FT_W32_WriteFile( + FT_HANDLE ftHandle, + LPVOID lpBuffer, + DWORD nBufferSize, + LPDWORD lpBytesWritten, + LPOVERLAPPED lpOverlapped + ); + + FTD2XX_API + DWORD WINAPI FT_W32_GetLastError( + FT_HANDLE ftHandle + ); + + FTD2XX_API + BOOL WINAPI FT_W32_GetOverlappedResult( + FT_HANDLE ftHandle, + LPOVERLAPPED lpOverlapped, + LPDWORD lpdwBytesTransferred, + BOOL bWait + ); + + FTD2XX_API + BOOL WINAPI FT_W32_CancelIo( + FT_HANDLE ftHandle + ); + + + // + // Win32 COMM API type functions + // + typedef struct _FTCOMSTAT { + DWORD fCtsHold : 1; + DWORD fDsrHold : 1; + DWORD fRlsdHold : 1; + DWORD fXoffHold : 1; + DWORD fXoffSent : 1; + DWORD fEof : 1; + DWORD fTxim : 1; + DWORD fReserved : 25; + DWORD cbInQue; + DWORD cbOutQue; + } FTCOMSTAT, *LPFTCOMSTAT; + + typedef struct _FTDCB { + DWORD DCBlength; /* sizeof(FTDCB) */ + DWORD BaudRate; /* Baudrate at which running */ + DWORD fBinary : 1; /* Binary Mode (skip EOF check) */ + DWORD fParity : 1; /* Enable parity checking */ + DWORD fOutxCtsFlow : 1; /* CTS handshaking on output */ + DWORD fOutxDsrFlow : 1; /* DSR handshaking on output */ + DWORD fDtrControl : 2; /* DTR Flow control */ + DWORD fDsrSensitivity : 1; /* DSR Sensitivity */ + DWORD fTXContinueOnXoff : 1; /* Continue TX when Xoff sent */ + DWORD fOutX : 1; /* Enable output X-ON/X-OFF */ + DWORD fInX : 1; /* Enable input X-ON/X-OFF */ + DWORD fErrorChar : 1; /* Enable Err Replacement */ + DWORD fNull : 1; /* Enable Null stripping */ + DWORD fRtsControl : 2; /* Rts Flow control */ + DWORD fAbortOnError : 1; /* Abort all reads and writes on Error */ + DWORD fDummy2 : 17; /* Reserved */ + WORD wReserved; /* Not currently used */ + WORD XonLim; /* Transmit X-ON threshold */ + WORD XoffLim; /* Transmit X-OFF threshold */ + BYTE ByteSize; /* Number of bits/byte, 4-8 */ + BYTE Parity; /* 0-4=None,Odd,Even,Mark,Space */ + BYTE StopBits; /* FT_STOP_BITS_1 or FT_STOP_BITS_2 */ + char XonChar; /* Tx and Rx X-ON character */ + char XoffChar; /* Tx and Rx X-OFF character */ + char ErrorChar; /* Error replacement char */ + char EofChar; /* End of Input character */ + char EvtChar; /* Received Event character */ + WORD wReserved1; /* Fill for now. */ + } FTDCB, *LPFTDCB; + + typedef struct _FTTIMEOUTS { + DWORD ReadIntervalTimeout; /* Maximum time between read chars. */ + DWORD ReadTotalTimeoutMultiplier; /* Multiplier of characters. */ + DWORD ReadTotalTimeoutConstant; /* Constant in milliseconds. */ + DWORD WriteTotalTimeoutMultiplier; /* Multiplier of characters. */ + DWORD WriteTotalTimeoutConstant; /* Constant in milliseconds. */ + } FTTIMEOUTS, *LPFTTIMEOUTS; + + + FTD2XX_API + BOOL WINAPI FT_W32_ClearCommBreak( + FT_HANDLE ftHandle + ); + + FTD2XX_API + BOOL WINAPI FT_W32_ClearCommError( + FT_HANDLE ftHandle, + LPDWORD lpdwErrors, + LPFTCOMSTAT lpftComstat + ); + + FTD2XX_API + BOOL WINAPI FT_W32_EscapeCommFunction( + FT_HANDLE ftHandle, + DWORD dwFunc + ); + + FTD2XX_API + BOOL WINAPI FT_W32_GetCommModemStatus( + FT_HANDLE ftHandle, + LPDWORD lpdwModemStatus + ); + + FTD2XX_API + BOOL WINAPI FT_W32_GetCommState( + FT_HANDLE ftHandle, + LPFTDCB lpftDcb + ); + + FTD2XX_API + BOOL WINAPI FT_W32_GetCommTimeouts( + FT_HANDLE ftHandle, + FTTIMEOUTS *pTimeouts + ); + + FTD2XX_API + BOOL WINAPI FT_W32_PurgeComm( + FT_HANDLE ftHandle, + DWORD dwMask + ); + + FTD2XX_API + BOOL WINAPI FT_W32_SetCommBreak( + FT_HANDLE ftHandle + ); + + FTD2XX_API + BOOL WINAPI FT_W32_SetCommMask( + FT_HANDLE ftHandle, + ULONG ulEventMask + ); + + FTD2XX_API + BOOL WINAPI FT_W32_GetCommMask( + FT_HANDLE ftHandle, + LPDWORD lpdwEventMask + ); + + FTD2XX_API + BOOL WINAPI FT_W32_SetCommState( + FT_HANDLE ftHandle, + LPFTDCB lpftDcb + ); + + FTD2XX_API + BOOL WINAPI FT_W32_SetCommTimeouts( + FT_HANDLE ftHandle, + FTTIMEOUTS *pTimeouts + ); + + FTD2XX_API + BOOL WINAPI FT_W32_SetupComm( + FT_HANDLE ftHandle, + DWORD dwReadBufferSize, + DWORD dwWriteBufferSize + ); + + FTD2XX_API + BOOL WINAPI FT_W32_WaitCommEvent( + FT_HANDLE ftHandle, + PULONG pulEvent, + LPOVERLAPPED lpOverlapped + ); + + + // + // Device information + // + + typedef struct _ft_device_list_info_node { + ULONG Flags; + ULONG Type; + ULONG ID; + DWORD LocId; + char SerialNumber[16]; + char Description[64]; + FT_HANDLE ftHandle; + } FT_DEVICE_LIST_INFO_NODE; + + // Device information flags + enum { + FT_FLAGS_OPENED = 1, + FT_FLAGS_HISPEED = 2 + }; + + + FTD2XX_API + FT_STATUS WINAPI FT_CreateDeviceInfoList( + LPDWORD lpdwNumDevs + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetDeviceInfoList( + FT_DEVICE_LIST_INFO_NODE *pDest, + LPDWORD lpdwNumDevs + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetDeviceInfoDetail( + DWORD dwIndex, + LPDWORD lpdwFlags, + LPDWORD lpdwType, + LPDWORD lpdwID, + LPDWORD lpdwLocId, + LPVOID lpSerialNumber, + LPVOID lpDescription, + FT_HANDLE *pftHandle + ); + + + // + // Version information + // + + FTD2XX_API + FT_STATUS WINAPI FT_GetDriverVersion( + FT_HANDLE ftHandle, + LPDWORD lpdwVersion + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetLibraryVersion( + LPDWORD lpdwVersion + ); + + + FTD2XX_API + FT_STATUS WINAPI FT_Rescan( + void + ); + + FTD2XX_API + FT_STATUS WINAPI FT_Reload( + WORD wVid, + WORD wPid + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetComPortNumber( + FT_HANDLE ftHandle, + LPLONG lpdwComPortNumber + ); + + + // + // FT232H additional EEPROM functions + // + + FTD2XX_API + FT_STATUS WINAPI FT_EE_ReadConfig( + FT_HANDLE ftHandle, + UCHAR ucAddress, + PUCHAR pucValue + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_WriteConfig( + FT_HANDLE ftHandle, + UCHAR ucAddress, + UCHAR ucValue + ); + + FTD2XX_API + FT_STATUS WINAPI FT_EE_ReadECC( + FT_HANDLE ftHandle, + UCHAR ucOption, + LPWORD lpwValue + ); + + FTD2XX_API + FT_STATUS WINAPI FT_GetQueueStatusEx( + FT_HANDLE ftHandle, + DWORD *dwRxBytes + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ComPortIdle( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_ComPortCancelIdle( + FT_HANDLE ftHandle + ); + + FTD2XX_API + FT_STATUS WINAPI FT_VendorCmdGet( + FT_HANDLE ftHandle, + UCHAR Request, + UCHAR *Buf, + USHORT Len + ); + + FTD2XX_API + FT_STATUS WINAPI FT_VendorCmdSet( + FT_HANDLE ftHandle, + UCHAR Request, + UCHAR *Buf, + USHORT Len + ); + + FTD2XX_API + FT_STATUS WINAPI FT_VendorCmdGetEx( + FT_HANDLE ftHandle, + USHORT wValue, + UCHAR *Buf, + USHORT Len + ); + + FTD2XX_API + FT_STATUS WINAPI FT_VendorCmdSetEx( + FT_HANDLE ftHandle, + USHORT wValue, + UCHAR *Buf, + USHORT Len + ); + +#ifdef __cplusplus +} +#endif + + +#endif /* FTD2XX_H */ diff --git a/drivers/FTDI USB Drivers/ftdibus.cat b/drivers/FTDI USB Drivers/ftdibus.cat new file mode 100644 index 000000000..dcc67efe8 Binary files /dev/null and b/drivers/FTDI USB Drivers/ftdibus.cat differ diff --git a/drivers/FTDI USB Drivers/ftdibus.inf b/drivers/FTDI USB Drivers/ftdibus.inf new file mode 100644 index 000000000..b4f7f8c0e --- /dev/null +++ b/drivers/FTDI USB Drivers/ftdibus.inf @@ -0,0 +1,565 @@ +; FTDIBUS.INF +; +; Copyright © 2000-2021 Future Technology Devices International Limited +; +; USB serial converter driver installation file for Windows 7, Windows 8, Windows 8.1, Windows 10, +; Server 2008 R2, Server 2012 R2 and Server 2016. +; +; +; IMPORTANT NOTICE: PLEASE READ CAREFULLY BEFORE INSTALLING THE RELEVANT +; SOFTWARE: This licence agreement (Licence) is a legal agreement between you (Licensee or +; you) and Future Technology Devices International Limited of 2 Seaward Place, Centurion Business +; Park, Glasgow G41 1HH, Scotland (UK Company Number SC136640) (Licensor or we) for use of +; driver software provided by the Licensor(Software). +; +; BY INSTALLING OR USING THIS SOFTWARE YOU AGREE TO THE TERMS OF THIS LICENCE +; WHICH WILL BIND YOU. IF YOU DO NOT AGREE TO THE TERMS OF THIS LICENCE, WE ARE +; UNWILLING TO LICENSE THE SOFTWARE TO YOU AND YOU MUST DISCONTINUE +; INSTALLATION OF THE SOFTWARE NOW. +; +; 1. GRANT AND SCOPE OF LICENCE +; +; 1.1 In consideration of you agreeing to abide by the terms of this Licence, the Licensor hereby +; grants to you a non-exclusive, non-transferable, royalty free licence to use the Software on +; the terms of this Licence. +; +; 1.2 In this Licence a "Genuine FTDI Component" means an item of hardware that was +; manufactured for, and sold by, the Licensor or a member of the Licensor's group of +; companies. It does not include any counterfeit or fake products. +; +; 1.3 If you are a manufacturer of a device that includes a Genuine FTDI Component (each a +; "Device") then you may install the Software onto that device. If you are a seller or distributor +; of a Device then you may distribute the Software with the Device. If you are a user of a +; Device then you may install the Software on the Device, or onto a computer system in order +; to use the Device. +; +; 1.4 In each of those cases you may: +; +; 1.4.1 install and use the Software for your purposes only; and +; +; 1.4.2 only use the Software in conjunction with products based on and/or incorporating a +; Genuine FTDI Component. +; +; 1.5 The Software will not function properly on or with a component that is not a Genuine FTDI +; Component. Use of the Software as a driver for, or installation of the Software onto, a +; component that is not a Genuine FTDI Component, including without limitation counterfeit +; components, MAY IRRETRIEVABLY DAMAGE THAT COMPONENT. It is the Licensee's +; responsibility to make sure that all chips it installs the Software on, or uses the Software as a +; driver for, are Genuine FTDI Components. If in doubt then contact the Licensor. +; +; 2. If a custom vendor ID and/or product ID or description string are used, it is the responsibility of +; the product manufacturer to maintain any changes and subsequent WHQL re-certification as +; a result of making these changes. +; +; 3. LICENSEE'S UNDERTAKINGS +; +; 3.1 Except as expressly set out in this Licence or as permitted by any local law, you undertake: +; +; 3.1.1 not to copy the Software, except where such copying is incidental to normal use of +; the Software or where it is necessary for the purpose of back-up or operational +; security; +; +; 3.1.2 not to rent, lease, sub-license, loan, translate, merge, adapt, vary or modify the +; Software or any part of it; +; +; 3.1.3 not to make alterations to, or modifications of, the whole or any part of the Software +; nor permit the Software or any part of it to be combined with, or become +; incorporated in, any other programs; +; +; 3.1.4 not to disassemble, de-compile, reverse engineer or create derivative works based +; on the whole or any part of the Software; +; +; 3.1.5 to keep all copies of the Software secure; +; +; 3.1.6 to include the copyright notice of the Licensor on all entire and partial copies of the +; Software in any form; and +; +; 3.1.7 not to provide, or otherwise make available, the Software in any form, in whole or in +; part (including, but not limited to, program listings, object and source program +; listings, object code and source code) to any person. +; +; 4. INTELLECTUAL PROPERTY RIGHTS +; +; 4.1 You acknowledge that all intellectual property rights in the Software throughout the world +; belong to the Licensor, that rights in the Software are licensed (not sold) to you, and that you +; have no rights in, or to, the Software other than the right to use them in accordance with the +; terms of this Licence. +; +; 5. WARRANTY +; +; 5.1 To the maximum extent permitted by applicable law, the software is provided "as is". +; +; 5.2 All implied warranties, implied conditions and/or implied licences are excluded from this +; Licence, including but not limited to implied warranties of quality and/or fitness for purpose (in +; all cases) to the fullest extent permitted by law. +; +; 5.3 You acknowledge that the Software has not been developed to meet your individual +; requirements and that the Software may not be uninterrupted or free of bugs or errors. +; +; 6. LICENSOR'S LIABILITY +; +; 6.1 To the maximum extent permitted by applicable law, in no event shall the Licensor be liable +; for any: +; +; 6.1.1 special loss or damage; +; +; 6.1.2 incidental loss or damage; +; +; 6.1.3 indirect or consequential loss or damage: +; +; 6.1.4 loss of income; +; +; 6.1.5 loss of business; +; +; 6.1.6 loss of profits; +; +; 6.1.7 loss of revenue; +; +; 6.1.8 loss of contracts; +; +; 6.1.9 business interruption; +; +; 6.1.10 loss of the use of money or anticipated savings; +; +; 6.1.11 loss of information; +; +; 6.1.12 loss of opportunity; +; +; 6.1.13 loss of goodwill or reputation; and/or +; +; 6.1.14 loss of, damage to or corruption of data; +; +; (in each case) of any kind howsoever arising and whether caused by delict (including +; negligence), breach of contract or otherwise. +; +; 6.2 FTDI's total liability to you in relation to the Software shall not exceed 500 US Dollars. +; +; 6.3 Nothing in this Licence limits or excludes liability for death or personal injury or for fraud. +; +; 7. TERMINATION +; +; 7.1 The Licensor may terminate this Licence immediately if: +; +; 7.1.1 you fail to comply with any of the terms and conditions of the Licence; or +; +; 7.1.2 you commence or participate in any legal proceedings against the Licensor. +; +; 7.2 Upon termination: +; +; 7.2.1 all rights granted to you under this Licence shall cease; +; +; 7.2.2 you must cease all activities authorised by this Licence; and +; +; 7.2.3 you must immediately delete or remove the Software from all computer equipment +; in your possession and immediately destroy all copies of the Software then in your +; possession, custody or control. +; +; 8. TRANSFER OF RIGHTS AND OBLIGATIONS +; +; 8.1 You may not transfer, assign, charge or otherwise dispose of this Licence, or any of your +; rights or obligations arising under it. +; +; 8.2 The Licensor may transfer, assign, charge, sub-contract or otherwise dispose of this Licence, +; or any of his rights or obligations arising under it, at any time during the term of the Licence. +; +; 9. WAIVER +; +; 9.1 If the Licensor fails, at any time during the term of this Licence, to insist on strict performance +; of any of your obligations under this Licence, or if the Licensor fails to exercise any of the +; rights or remedies to which he is entitled under this Licence, this shall not constitute a waiver +; of such rights or remedies and shall not relieve you from compliance with such obligations. +; +; 9.2 A waiver by the Licensor of any default shall not constitute a waiver of any subsequent +; default. +; +; 9.3 No waiver by the Licensor of any of these terms and conditions shall be effective unless it is +; expressly stated to be a waiver and is communicated to you in writing. +; +; 10. SEVERABILITY +; +; If any of the terms of this Licence are determined by any competent authority to be invalid, +; unlawful or unenforceable to any extent, such term, condition or provision will to that extent be +; severed from the remaining terms, conditions and provisions which will continue to be valid to +; the fullest extent permitted by law. +; +; 11. ENTIRE AGREEMENT +; +; 11.1 This Licence constitutes the whole agreement between us and supersedes any previous +; arrangement, understanding or agreement between us, relating to the licensing of the +; Software. +; +; 11.2 Each party acknowledges that in entering into this Licence it does not rely on any statement, +; representation, warranty or understanding other than those expressly set out in this Licence. +; Each party agrees that it will have no remedy in respect of any statement, representation, +; warranty or understanding that is not expressly set out in this Licence. Each party agrees that +; its only remedy in respect of those representations, statements, assurances and warranties +; that are set out in this Licence will be for breach of contract in accordance with the terms of +; this Licence. +; +; 11.3 The parties agree that nothing in this Licence will limit or exclude any liability they may have +; for fraud. +; +; 12. MISCELLANEOUS +; +; 12.1 This Licence does not create a partnership or joint venture between the parties to it, nor +; authorise a party to act as agent for the other. +; +; 12.2 This Licence does not create any legal rights enforceable by any third party. +; +; 12.3 This Licence may only be varied by express written legal agreement between the parties. +; +; 13. LAW AND JURISDICTION +; +; This Licence, its subject matter or its formation (including non-contractual disputes or claims) +; shall be governed by and construed in accordance with Scots law and submitted to the non- +; exclusive jurisdiction of the Scottish courts. +; + +[Version] +Signature="$Windows NT$" +DriverPackageType=PlugAndPlay +DriverPackageDisplayName=%DESC% +Class=USB +ClassGUID={36fc9e60-c465-11cf-8056-444553540000} +Provider=%FTDI% +CatalogFile=ftdibus.cat +DriverVer=07/05/2021,2.12.36.4 + +[SourceDisksNames] +1=%DriversDisk%,,, + +[SourceDisksFiles] +ftdibus.sys = 1,i386 +ftbusui.dll = 1,i386 +ftd2xx.dll = 1,i386 +FTLang.Dll = 1,i386 + +[SourceDisksFiles.amd64] +ftdibus.sys = 1,amd64 +ftbusui.dll = 1,amd64 +ftd2xx64.dll = 1,amd64 +ftd2xx.dll = 1,i386 +FTLang.Dll = 1,amd64 + +[DestinationDirs] +FtdiBus.NT.Copy = 10,system32\drivers +FtdiBus.NT.Copy2 = 10,system32 +FtdiBus.NTamd64.Copy = 10,system32\drivers +FtdiBus.NTamd64.Copy2 = 10,system32 +FtdiBus.NTamd64.Copy3 = 10,syswow64 + +[Manufacturer] +%Ftdi%=FtdiHw,NTamd64 + +[FtdiHw] +%USB\VID_0403&PID_6001.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6001 +%USB\VID_0403&PID_6010&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6010&MI_00 +%USB\VID_0403&PID_6010&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6010&MI_01 +%USB\VID_0403&PID_6011&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6011&MI_00 +%USB\VID_0403&PID_6011&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6011&MI_01 +%USB\VID_0403&PID_6011&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6011&MI_02 +%USB\VID_0403&PID_6011&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6011&MI_03 +%USB\VID_0403&PID_6014.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6014 +%USB\VID_0403&PID_6015.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6015 +%USB\VID_0403&PID_601B&REV_1400.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601B&REV_1400 +%USB\VID_0403&PID_601B&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601B&MI_00 +%USB\VID_0403&PID_601B&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601B&MI_01 +%USB\VID_0403&PID_601B&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601B&MI_02 +%USB\VID_0403&PID_601B&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601B&MI_03 +%USB\VID_0403&PID_601C&REV_1700.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601C&REV_1700 +%USB\VID_0403&PID_601C&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601C&MI_00 +%USB\VID_0403&PID_601C&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601C&MI_01 +%USB\VID_0403&PID_601C&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601C&MI_02 +%USB\VID_0403&PID_601C&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_601C&MI_03 +%USB\VID_0403&PID_0FEC.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_0FEC +%USB\VID_0403&PID_6031&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6031&MI_00 +%USB\VID_0403&PID_6031&REV_2400.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6031&REV_2400 +%USB\VID_0403&PID_6032&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6032&MI_00 +%USB\VID_0403&PID_6032&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6032&MI_01 +%USB\VID_0403&PID_6033&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6033&MI_00 +%USB\VID_0403&PID_6033&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6033&MI_01 +%USB\VID_0403&PID_6033&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6033&MI_02 +%USB\VID_0403&PID_6034&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6034&MI_00 +%USB\VID_0403&PID_6034&REV_2500.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6034&REV_2500 +%USB\VID_0403&PID_6035&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6035&MI_00 +%USB\VID_0403&PID_6035&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6035&MI_01 +%USB\VID_0403&PID_6036&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6036&MI_00 +%USB\VID_0403&PID_6036&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6036&MI_01 +%USB\VID_0403&PID_6036&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6036&MI_02 +%USB\VID_0403&PID_6037&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6037&MI_00 +%USB\VID_0403&PID_6037&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6037&MI_01 +%USB\VID_0403&PID_6037&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6037&MI_02 +%USB\VID_0403&PID_6037&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6037&MI_03 +%USB\VID_0403&PID_6038&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6038&MI_00 +%USB\VID_0403&PID_6038&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6038&MI_01 +%USB\VID_0403&PID_6038&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6038&MI_02 +%USB\VID_0403&PID_6038&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6038&MI_03 +%USB\VID_0403&PID_6038&MI_04.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6038&MI_04 +%USB\VID_0403&PID_6039&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6039&MI_00 +%USB\VID_0403&PID_6039&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6039&MI_01 +%USB\VID_0403&PID_6039&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6039&MI_02 +%USB\VID_0403&PID_6039&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6039&MI_03 +%USB\VID_0403&PID_6039&MI_04.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6039&MI_04 +%USB\VID_0403&PID_6039&MI_05.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6039&MI_05 +%USB\VID_0403&PID_603A&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603A&MI_00 +%USB\VID_0403&PID_603A&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603A&MI_01 +%USB\VID_0403&PID_603A&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603A&MI_02 +%USB\VID_0403&PID_603A&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603A&MI_03 +%USB\VID_0403&PID_603A&MI_04.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603A&MI_04 +%USB\VID_0403&PID_603A&MI_05.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603A&MI_05 +%USB\VID_0403&PID_603A&MI_06.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603A&MI_06 +%USB\VID_0403&PID_603E.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_603E +%USB\VID_0403&PID_6040&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6040&MI_00 +%USB\VID_0403&PID_6040&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6040&MI_01 +%USB\VID_0403&PID_6041&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6041&MI_00 +%USB\VID_0403&PID_6041&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6041&MI_01 +%USB\VID_0403&PID_6041&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6041&MI_02 +%USB\VID_0403&PID_6041&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6041&MI_03 +%USB\VID_0403&PID_6042&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6042&MI_00 +%USB\VID_0403&PID_6042&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6042&MI_01 +%USB\VID_0403&PID_6043&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6043&MI_00 +%USB\VID_0403&PID_6043&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6043&MI_01 +%USB\VID_0403&PID_6043&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6043&MI_02 +%USB\VID_0403&PID_6043&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6043&MI_03 +%USB\VID_0403&PID_6044.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6044 +%USB\VID_0403&PID_6045.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6045 +%USB\VID_0403&PID_6047&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6047&MI_00 +%USB\VID_0403&PID_6047&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6047&MI_01 +%USB\VID_0403&PID_6048&MI_00.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6048&MI_00 +%USB\VID_0403&PID_6048&MI_01.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6048&MI_01 +%USB\VID_0403&PID_6048&MI_02.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6048&MI_02 +%USB\VID_0403&PID_6048&MI_03.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6048&MI_03 +%USB\VID_0403&PID_6049.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_6049 +%USB\VID_0403&PID_0000.DeviceDesc%=FtdiBus.NT,USB\VID_0403&PID_0000 + +[FtdiHw.NTamd64] +%USB\VID_0403&PID_6001.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6001 +%USB\VID_0403&PID_6010&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6010&MI_00 +%USB\VID_0403&PID_6010&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6010&MI_01 +%USB\VID_0403&PID_6011&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6011&MI_00 +%USB\VID_0403&PID_6011&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6011&MI_01 +%USB\VID_0403&PID_6011&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6011&MI_02 +%USB\VID_0403&PID_6011&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6011&MI_03 +%USB\VID_0403&PID_6014.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6014 +%USB\VID_0403&PID_6015.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6015 +%USB\VID_0403&PID_601B&REV_1400.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601B&REV_1400 +%USB\VID_0403&PID_601B&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601B&MI_00 +%USB\VID_0403&PID_601B&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601B&MI_01 +%USB\VID_0403&PID_601B&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601B&MI_02 +%USB\VID_0403&PID_601B&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601B&MI_03 +%USB\VID_0403&PID_601C&REV_1700.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601C&REV_1700 +%USB\VID_0403&PID_601C&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601C&MI_00 +%USB\VID_0403&PID_601C&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601C&MI_01 +%USB\VID_0403&PID_601C&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601C&MI_02 +%USB\VID_0403&PID_601C&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_601C&MI_03 +%USB\VID_0403&PID_0FEC.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_0FEC +%USB\VID_0403&PID_6031&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6031&MI_00 +%USB\VID_0403&PID_6031&REV_2400.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6031&REV_2400 +%USB\VID_0403&PID_6032&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6032&MI_00 +%USB\VID_0403&PID_6032&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6032&MI_01 +%USB\VID_0403&PID_6033&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6033&MI_00 +%USB\VID_0403&PID_6033&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6033&MI_01 +%USB\VID_0403&PID_6033&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6033&MI_02 +%USB\VID_0403&PID_6034&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6034&MI_00 +%USB\VID_0403&PID_6034&REV_2500.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6035&REV_2500 +%USB\VID_0403&PID_6035&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6035&MI_00 +%USB\VID_0403&PID_6035&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6035&MI_01 +%USB\VID_0403&PID_6036&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6036&MI_00 +%USB\VID_0403&PID_6036&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6036&MI_01 +%USB\VID_0403&PID_6036&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6036&MI_02 +%USB\VID_0403&PID_6037&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6037&MI_00 +%USB\VID_0403&PID_6037&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6037&MI_01 +%USB\VID_0403&PID_6037&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6037&MI_02 +%USB\VID_0403&PID_6037&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6037&MI_03 +%USB\VID_0403&PID_6038&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6038&MI_00 +%USB\VID_0403&PID_6038&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6038&MI_01 +%USB\VID_0403&PID_6038&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6038&MI_02 +%USB\VID_0403&PID_6038&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6038&MI_03 +%USB\VID_0403&PID_6038&MI_04.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6038&MI_04 +%USB\VID_0403&PID_6039&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6039&MI_00 +%USB\VID_0403&PID_6039&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6039&MI_01 +%USB\VID_0403&PID_6039&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6039&MI_02 +%USB\VID_0403&PID_6039&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6039&MI_03 +%USB\VID_0403&PID_6039&MI_04.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6039&MI_04 +%USB\VID_0403&PID_6039&MI_05.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6039&MI_05 +%USB\VID_0403&PID_603A&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603A&MI_00 +%USB\VID_0403&PID_603A&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603A&MI_01 +%USB\VID_0403&PID_603A&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603A&MI_02 +%USB\VID_0403&PID_603A&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603A&MI_03 +%USB\VID_0403&PID_603A&MI_04.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603A&MI_04 +%USB\VID_0403&PID_603A&MI_05.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603A&MI_05 +%USB\VID_0403&PID_603A&MI_06.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603A&MI_06 +%USB\VID_0403&PID_603E.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_603E +%USB\VID_0403&PID_6040&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6040&MI_00 +%USB\VID_0403&PID_6040&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6040&MI_01 +%USB\VID_0403&PID_6041&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6041&MI_00 +%USB\VID_0403&PID_6041&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6041&MI_01 +%USB\VID_0403&PID_6041&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6041&MI_02 +%USB\VID_0403&PID_6041&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6041&MI_03 +%USB\VID_0403&PID_6042&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6042&MI_00 +%USB\VID_0403&PID_6042&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6042&MI_01 +%USB\VID_0403&PID_6043&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6043&MI_00 +%USB\VID_0403&PID_6043&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6043&MI_01 +%USB\VID_0403&PID_6043&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6043&MI_02 +%USB\VID_0403&PID_6043&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6043&MI_03 +%USB\VID_0403&PID_6044.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6044 +%USB\VID_0403&PID_6045.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6045 +%USB\VID_0403&PID_6047&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6047&MI_00 +%USB\VID_0403&PID_6047&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6047&MI_01 +%USB\VID_0403&PID_6048&MI_00.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6048&MI_00 +%USB\VID_0403&PID_6048&MI_01.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6048&MI_01 +%USB\VID_0403&PID_6048&MI_02.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6048&MI_02 +%USB\VID_0403&PID_6048&MI_03.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6048&MI_03 +%USB\VID_0403&PID_6049.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_6049 +%USB\VID_0403&PID_0000.DeviceDesc%=FtdiBus.NTamd64,USB\VID_0403&PID_0000 + +[ControlFlags] +ExcludeFromSelect=* + +[FtdiBus.NT] +CopyFiles=FtdiBus.NT.Copy,FtdiBus.NT.Copy2 +AddReg=FtdiBus.NT.AddReg + +[FtdiBus.NTamd64] +CopyFiles=FtdiBus.NTamd64.Copy,FtdiBus.NTamd64.Copy2,FtdiBus.NTamd64.Copy3 +AddReg=FtdiBus.NT.AddReg + +[FtdiBus.NT.Services] +AddService = FTDIBUS, 0x00000002, FtdiBus.NT.AddService, FtdiBus.NT.EventLog_Inst + +[FtdiBus.NTamd64.Services] +AddService = FTDIBUS, 0x00000002, FtdiBus.NT.AddService, FtdiBus.NT.EventLog_Inst + +[FtdiBus.NT.AddService] +DisplayName = %SvcDesc% +ServiceType = 1 ; SERVICE_KERNEL_DRIVER +StartType = 3 ; SERVICE_DEMAND_START +ErrorControl = 1 ; SERVICE_ERROR_NORMAL +ServiceBinary = %10%\system32\drivers\ftdibus.sys +LoadOrderGroup = Base + +[FtdiBus.NT.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,ftdibus.sys +HKR,,EnumPropPages32,,"ftbusui.dll,FTBUSUIPropPageProvider" + +[FtdiBus.NT.EventLog_Inst] +AddReg = FtdiBus.NT.EventLog_Inst.AddReg + +[FtdiBus.NT.EventLog_Inst.AddReg] +HKR,,EventMessageFile,0x00020000,"%%SystemRoot%%\System32\IoLogMsg.dll;%%SystemRoot%%\System32\drivers\ftdibus.sys" +HKR,,TypesSupported,0x00010001,7 + +[FtdiBus.NT.HW] +AddReg=FtdiBus.NT.HW.AddReg + +[FtdiBus.NTamd64.HW] +AddReg=FtdiBus.NT.HW.AddReg + +[FtdiBus.NT.HW.AddReg] +;HKR,,"ConfigData",0x00010001,0x00000012 + +[FtdiBus.NT.Copy] +ftdibus.sys + +[FtdiBus.NT.Copy2] +ftbusui.dll +ftd2xx.dll +FTLang.dll + +[FtdiBus.NTamd64.Copy] +ftdibus.sys + +[FtdiBus.NTamd64.Copy2] +ftbusui.dll +ftd2xx.dll,ftd2xx64.dll +FTLang.dll + +[FtdiBus.NTamd64.Copy3] +ftd2xx.dll + +[Strings] +Ftdi="FTDI" +DESC="CDM Driver Package - Bus/D2XX Driver" +DriversDisk="FTDI USB Drivers Disk" +USB\VID_0403&PID_6001.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6010&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6010&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6011&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6011&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6011&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6011&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_6014.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6015.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_601B&REV_1400.DeviceDesc="FT4222 Mode 3 Device" +USB\VID_0403&PID_601B&MI_00.DeviceDesc="FT4222 Interface A" +USB\VID_0403&PID_601B&MI_01.DeviceDesc="FT4222 Interface B" +USB\VID_0403&PID_601B&MI_02.DeviceDesc="FT4222 Interface C" +USB\VID_0403&PID_601B&MI_03.DeviceDesc="FT4222 Interface D" +USB\VID_0403&PID_601C&REV_1700.DeviceDesc="FT4222H Mode 3 Device" +USB\VID_0403&PID_601C&MI_00.DeviceDesc="FT4222H Interface A" +USB\VID_0403&PID_601C&MI_01.DeviceDesc="FT4222H Interface B" +USB\VID_0403&PID_601C&MI_02.DeviceDesc="FT4222H Interface C" +USB\VID_0403&PID_601C&MI_03.DeviceDesc="FT4222H Interface D" +USB\VID_0403&PID_0FEC.DeviceDesc="UMFT4222PROG" +USB\VID_0403&PID_6031&MI_00.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6031&REV_2400.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6032&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6032&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6033&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6033&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6033&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6034&MI_00.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6034&REV_2500.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6035&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6035&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6036&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6036&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6036&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6037&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6037&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6037&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6037&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_6038&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6038&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6038&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6038&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_6038&MI_04.DeviceDesc="USB Serial Converter E" +USB\VID_0403&PID_6039&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6039&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6039&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6039&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_6039&MI_04.DeviceDesc="USB Serial Converter E" +USB\VID_0403&PID_6039&MI_05.DeviceDesc="USB Serial Converter F" +USB\VID_0403&PID_603A&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_603A&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_603A&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_603A&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_603A&MI_04.DeviceDesc="USB Serial Converter E" +USB\VID_0403&PID_603A&MI_05.DeviceDesc="USB Serial Converter F" +USB\VID_0403&PID_603A&MI_06.DeviceDesc="USB Serial Converter G" +USB\VID_0403&PID_603E.DeviceDesc="UMFTPD3A Programming Board" +USB\VID_0403&PID_6040&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6040&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6041&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6041&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6041&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6041&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_6042&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6042&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6043&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6043&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6043&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6043&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_6044.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6045.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_6047&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6047&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6048&MI_00.DeviceDesc="USB Serial Converter A" +USB\VID_0403&PID_6048&MI_01.DeviceDesc="USB Serial Converter B" +USB\VID_0403&PID_6048&MI_02.DeviceDesc="USB Serial Converter C" +USB\VID_0403&PID_6048&MI_03.DeviceDesc="USB Serial Converter D" +USB\VID_0403&PID_6049.DeviceDesc="USB Serial Converter" +USB\VID_0403&PID_0000.DeviceDesc="USB Serial Converter" +SvcDesc="USB Serial Converter Driver" +ClassName="USB" diff --git a/drivers/FTDI USB Drivers/ftdiport.cat b/drivers/FTDI USB Drivers/ftdiport.cat new file mode 100644 index 000000000..317d0a1a4 Binary files /dev/null and b/drivers/FTDI USB Drivers/ftdiport.cat differ diff --git a/drivers/FTDI USB Drivers/ftdiport.inf b/drivers/FTDI USB Drivers/ftdiport.inf new file mode 100644 index 000000000..935b05766 --- /dev/null +++ b/drivers/FTDI USB Drivers/ftdiport.inf @@ -0,0 +1,419 @@ +; FTDIPORT.INF +; +; Copyright © 2000-2021 Future Technology Devices International Limited +; +; USB serial port driver installation file for Windows 7, Windows 8, Windows 8.1, Windows 10, +; Server 2008 R2, Server 2012 R2 and Server 2016. + +; +; +; IMPORTANT NOTICE: PLEASE READ CAREFULLY BEFORE INSTALLING THE RELEVANT +; SOFTWARE: This licence agreement (Licence) is a legal agreement between you (Licensee or +; you) and Future Technology Devices International Limited of 2 Seaward Place, Centurion Business +; Park, Glasgow G41 1HH, Scotland (UK Company Number SC136640) (Licensor or we) for use of +; driver software provided by the Licensor(Software). +; +; BY INSTALLING OR USING THIS SOFTWARE YOU AGREE TO THE TERMS OF THIS LICENCE +; WHICH WILL BIND YOU. IF YOU DO NOT AGREE TO THE TERMS OF THIS LICENCE, WE ARE +; UNWILLING TO LICENSE THE SOFTWARE TO YOU AND YOU MUST DISCONTINUE +; INSTALLATION OF THE SOFTWARE NOW. +; +; 1. GRANT AND SCOPE OF LICENCE +; +; 1.1 In consideration of you agreeing to abide by the terms of this Licence, the Licensor hereby +; grants to you a non-exclusive, non-transferable, royalty free licence to use the Software on +; the terms of this Licence. +; +; 1.2 In this Licence a "Genuine FTDI Component" means an item of hardware that was +; manufactured for, and sold by, the Licensor or a member of the Licensor's group of +; companies. It does not include any counterfeit or fake products. +; +; 1.3 If you are a manufacturer of a device that includes a Genuine FTDI Component (each a +; "Device") then you may install the Software onto that device. If you are a seller or distributor +; of a Device then you may distribute the Software with the Device. If you are a user of a +; Device then you may install the Software on the Device, or onto a computer system in order +; to use the Device. +; +; 1.4 In each of those cases you may: +; +; 1.4.1 install and use the Software for your purposes only; and +; +; 1.4.2 only use the Software in conjunction with products based on and/or incorporating a +; Genuine FTDI Component. +; +; 1.5 The Software will not function properly on or with a component that is not a Genuine FTDI +; Component. Use of the Software as a driver for, or installation of the Software onto, a +; component that is not a Genuine FTDI Component, including without limitation counterfeit +; components, MAY IRRETRIEVABLY DAMAGE THAT COMPONENT. It is the Licensee's +; responsibility to make sure that all chips it installs the Software on, or uses the Software as a +; driver for, are Genuine FTDI Components. If in doubt then contact the Licensor. +; +; 2. If a custom vendor ID and/or product ID or description string are used, it is the responsibility of +; the product manufacturer to maintain any changes and subsequent WHQL re-certification as +; a result of making these changes. +; +; 3. LICENSEE'S UNDERTAKINGS +; +; 3.1 Except as expressly set out in this Licence or as permitted by any local law, you undertake: +; +; 3.1.1 not to copy the Software, except where such copying is incidental to normal use of +; the Software or where it is necessary for the purpose of back-up or operational +; security; +; +; 3.1.2 not to rent, lease, sub-license, loan, translate, merge, adapt, vary or modify the +; Software or any part of it; +; +; 3.1.3 not to make alterations to, or modifications of, the whole or any part of the Software +; nor permit the Software or any part of it to be combined with, or become +; incorporated in, any other programs; +; +; 3.1.4 not to disassemble, de-compile, reverse engineer or create derivative works based +; on the whole or any part of the Software; +; +; 3.1.5 to keep all copies of the Software secure; +; +; 3.1.6 to include the copyright notice of the Licensor on all entire and partial copies of the +; Software in any form; and +; +; 3.1.7 not to provide, or otherwise make available, the Software in any form, in whole or in +; part (including, but not limited to, program listings, object and source program +; listings, object code and source code) to any person. +; +; 4. INTELLECTUAL PROPERTY RIGHTS +; +; 4.1 You acknowledge that all intellectual property rights in the Software throughout the world +; belong to the Licensor, that rights in the Software are licensed (not sold) to you, and that you +; have no rights in, or to, the Software other than the right to use them in accordance with the +; terms of this Licence. +; +; 5. WARRANTY +; +; 5.1 To the maximum extent permitted by applicable law, the software is provided "as is". +; +; 5.2 All implied warranties, implied conditions and/or implied licences are excluded from this +; Licence, including but not limited to implied warranties of quality and/or fitness for purpose (in +; all cases) to the fullest extent permitted by law. +; +; 5.3 You acknowledge that the Software has not been developed to meet your individual +; requirements and that the Software may not be uninterrupted or free of bugs or errors. +; +; 6. LICENSOR'S LIABILITY +; +; 6.1 To the maximum extent permitted by applicable law, in no event shall the Licensor be liable +; for any: +; +; 6.1.1 special loss or damage; +; +; 6.1.2 incidental loss or damage; +; +; 6.1.3 indirect or consequential loss or damage: +; +; 6.1.4 loss of income; +; +; 6.1.5 loss of business; +; +; 6.1.6 loss of profits; +; +; 6.1.7 loss of revenue; +; +; 6.1.8 loss of contracts; +; +; 6.1.9 business interruption; +; +; 6.1.10 loss of the use of money or anticipated savings; +; +; 6.1.11 loss of information; +; +; 6.1.12 loss of opportunity; +; +; 6.1.13 loss of goodwill or reputation; and/or +; +; 6.1.14 loss of, damage to or corruption of data; +; +; (in each case) of any kind howsoever arising and whether caused by delict (including +; negligence), breach of contract or otherwise. +; +; 6.2 FTDI's total liability to you in relation to the Software shall not exceed 500 US Dollars. +; +; 6.3 Nothing in this Licence limits or excludes liability for death or personal injury or for fraud. +; +; 7. TERMINATION +; +; 7.1 The Licensor may terminate this Licence immediately if: +; +; 7.1.1 you fail to comply with any of the terms and conditions of the Licence; or +; +; 7.1.2 you commence or participate in any legal proceedings against the Licensor. +; +; 7.2 Upon termination: +; +; 7.2.1 all rights granted to you under this Licence shall cease; +; +; 7.2.2 you must cease all activities authorised by this Licence; and +; +; 7.2.3 you must immediately delete or remove the Software from all computer equipment +; in your possession and immediately destroy all copies of the Software then in your +; possession, custody or control. +; +; 8. TRANSFER OF RIGHTS AND OBLIGATIONS +; +; 8.1 You may not transfer, assign, charge or otherwise dispose of this Licence, or any of your +; rights or obligations arising under it. +; +; 8.2 The Licensor may transfer, assign, charge, sub-contract or otherwise dispose of this Licence, +; or any of his rights or obligations arising under it, at any time during the term of the Licence. +; +; 9. WAIVER +; +; 9.1 If the Licensor fails, at any time during the term of this Licence, to insist on strict performance +; of any of your obligations under this Licence, or if the Licensor fails to exercise any of the +; rights or remedies to which he is entitled under this Licence, this shall not constitute a waiver +; of such rights or remedies and shall not relieve you from compliance with such obligations. +; +; 9.2 A waiver by the Licensor of any default shall not constitute a waiver of any subsequent +; default. +; +; 9.3 No waiver by the Licensor of any of these terms and conditions shall be effective unless it is +; expressly stated to be a waiver and is communicated to you in writing. +; +; 10. SEVERABILITY +; +; If any of the terms of this Licence are determined by any competent authority to be invalid, +; unlawful or unenforceable to any extent, such term, condition or provision will to that extent be +; severed from the remaining terms, conditions and provisions which will continue to be valid to +; the fullest extent permitted by law. +; +; 11. ENTIRE AGREEMENT +; +; 11.1 This Licence constitutes the whole agreement between us and supersedes any previous +; arrangement, understanding or agreement between us, relating to the licensing of the +; Software. +; +; 11.2 Each party acknowledges that in entering into this Licence it does not rely on any statement, +; representation, warranty or understanding other than those expressly set out in this Licence. +; Each party agrees that it will have no remedy in respect of any statement, representation, +; warranty or understanding that is not expressly set out in this Licence. Each party agrees that +; its only remedy in respect of those representations, statements, assurances and warranties +; that are set out in this Licence will be for breach of contract in accordance with the terms of +; this Licence. +; +; 11.3 The parties agree that nothing in this Licence will limit or exclude any liability they may have +; for fraud. +; +; 12. MISCELLANEOUS +; +; 12.1 This Licence does not create a partnership or joint venture between the parties to it, nor +; authorise a party to act as agent for the other. +; +; 12.2 This Licence does not create any legal rights enforceable by any third party. +; +; 12.3 This Licence may only be varied by express written legal agreement between the parties. +; +; 13. LAW AND JURISDICTION +; +; This Licence, its subject matter or its formation (including non-contractual disputes or claims) +; shall be governed by and construed in accordance with Scots law and submitted to the non- +; exclusive jurisdiction of the Scottish courts. +; + + +[Version] +Signature="$Windows NT$" +DriverPackageType=PlugAndPlay +DriverPackageDisplayName=%DESC% +Class=Ports +ClassGUID={4d36e978-e325-11ce-bfc1-08002be10318} +Provider=%FTDI% +CatalogFile=ftdiport.cat +DriverVer=07/05/2021,2.12.36.4 + +[SourceDisksNames] +1=%DriversDisk%,,, + +[SourceDisksFiles] +ftser2k.sys=1,i386 +ftserui2.dll=1,i386 +ftcserco.dll = 1,i386 + +[SourceDisksFiles.amd64] +ftser2k.sys=1,amd64 +ftserui2.dll=1,amd64 +ftcserco.dll = 1,amd64 + +[DestinationDirs] +FtdiPort.NT.Copy=10,system32\drivers +FtdiPort.NT.CopyUI=10,system32 +FtdiPort.NT.CopyCoInst=10,system32 + +[ControlFlags] +ExcludeFromSelect=* + +[Manufacturer] +%FTDI%=FtdiHw,NTamd64 + +[FtdiHw] +%VID_0403&PID_6001.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6001 +%VID_0403&PID_6010.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6010 +%VID_0403&PID_6011.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6011 +%VID_0403&PID_6014.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6014 +%VID_0403&PID_6015.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6015 +%VID_0403&PID_6031.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6031 +%VID_0403&PID_6032.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6032 +%VID_0403&PID_6033.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6033 +%VID_0403&PID_6034.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6034 +%VID_0403&PID_6035.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6035 +%VID_0403&PID_6036.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6036 +%VID_0403&PID_6037.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6037 +%VID_0403&PID_6038.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6038 +%VID_0403&PID_6039.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6039 +%VID_0403&PID_603A.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_603A +%VID_0403&PID_6040.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6040 +%VID_0403&PID_6041.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6041 +%VID_0403&PID_6042.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6042 +%VID_0403&PID_6043.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6043 +%VID_0403&PID_6044.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6044 +%VID_0403&PID_6045.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6045 +%VID_0403&PID_6047.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6047 +%VID_0403&PID_6048.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6048 +%VID_0403&PID_6049.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_6049 +%VID_0403&PID_0000.DeviceDesc%=FtdiPort.NT,FTDIBUS\COMPORT&VID_0403&PID_0000 + +[FtdiHw.NTamd64] +%VID_0403&PID_6001.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6001 +%VID_0403&PID_6010.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6010 +%VID_0403&PID_6011.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6011 +%VID_0403&PID_6014.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6014 +%VID_0403&PID_6015.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6015 +%VID_0403&PID_6031.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6031 +%VID_0403&PID_6032.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6032 +%VID_0403&PID_6033.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6033 +%VID_0403&PID_6034.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6034 +%VID_0403&PID_6035.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6035 +%VID_0403&PID_6036.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6036 +%VID_0403&PID_6037.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6037 +%VID_0403&PID_6038.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6038 +%VID_0403&PID_6039.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6039 +%VID_0403&PID_603A.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_603A +%VID_0403&PID_6040.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6040 +%VID_0403&PID_6041.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6041 +%VID_0403&PID_6042.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6042 +%VID_0403&PID_6043.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6043 +%VID_0403&PID_6044.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6044 +%VID_0403&PID_6045.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6045 +%VID_0403&PID_6047.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6047 +%VID_0403&PID_6048.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6048 +%VID_0403&PID_6049.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_6049 +%VID_0403&PID_0000.DeviceDesc%=FtdiPort.NTamd64,FTDIBUS\COMPORT&VID_0403&PID_0000 + +[FtdiPort.NT.AddService] +DisplayName = %SvcDesc% +ServiceType = 1 ; SERVICE_KERNEL_DRIVER +StartType = 3 ; SERVICE_DEMAND_START +ErrorControl = 1 ; SERVICE_ERROR_NORMAL +ServiceBinary = %10%\system32\drivers\ftser2k.sys +LoadOrderGroup = Base + + +; -------------- Serenum Driver install section +[SerEnum_AddService] +DisplayName = %SerEnum.SvcDesc% +ServiceType = 1 ; SERVICE_KERNEL_DRIVER +StartType = 3 ; SERVICE_DEMAND_START +ErrorControl = 1 ; SERVICE_ERROR_NORMAL +ServiceBinary = %12%\serenum.sys +LoadOrderGroup = PNP Filter + +[FtdiPort.NT.AddReg] +HKR,,EnumPropPages32,,"ftserui2.dll,SerialPortPropPageProvider" + +[FtdiPort.NT.Copy] +ftser2k.sys + +[FtdiPort.NT.CopyUI] +ftserui2.dll + +[FtdiPort.NT.CopyCoInst] +ftcserco.dll + +[FtdiPort.NT] +CopyFiles=FtdiPort.NT.Copy,FtdiPort.NT.CopyUI +AddReg=FtdiPort.NT.AddReg + +[FtdiPort.NTamd64] +CopyFiles=FtdiPort.NT.Copy,FtdiPort.NT.CopyUI +AddReg=FtdiPort.NT.AddReg + +[FtdiPort.NT.HW] +AddReg=FtdiPort.NT.HW.AddReg + +[FtdiPort.NTamd64.HW] +AddReg=FtdiPort.NT.HW.AddReg + + +[FtdiPort.NT.Services] +AddService = FTSER2K, 0x00000002, FtdiPort.NT.AddService +AddService = Serenum,,SerEnum_AddService +DelService = FTSERIAL + +[FtdiPort.NTamd64.Services] +AddService = FTSER2K, 0x00000002, FtdiPort.NT.AddService +AddService = Serenum,,SerEnum_AddService +DelService = FTSERIAL + + +[FtdiPort.NT.HW.AddReg] +HKR,,"UpperFilters",0x00010000,"serenum" +HKR,,"ConfigData",1,11,00,3F,3F,10,27,00,00,88,13,00,00,C4,09,00,00,E2,04,00,00,71,02,00,00,38,41,00,00,9C,80,00,00,4E,C0,00,00,34,00,00,00,1A,00,00,00,0D,00,00,00,06,40,00,00,03,80,00,00,00,00,00,00,D0,80,00,00 +HKR,,"MinReadTimeout",0x00010001,0 +HKR,,"MinWriteTimeout",0x00010001,0 +HKR,,"LatencyTimer",0x00010001,16 + + +[FtdiPort.NT.CoInstallers] +AddReg=FtdiPort.NT.CoInstallers.AddReg +CopyFiles=FtdiPort.NT.CopyCoInst + +[FtdiPort.NTamd64.CoInstallers] +AddReg=FtdiPort.NT.CoInstallers.AddReg +CopyFiles=FtdiPort.NT.CopyCoInst + +[FtdiPort.NT.CoInstallers.AddReg] +HKR,,CoInstallers32,0x00010000,"ftcserco.Dll,FTCSERCoInstaller" + + +;---------------------------------------------------------------; + +[Strings] +FTDI="FTDI" +DESC="CDM Driver Package - VCP Driver" +DriversDisk="FTDI USB Drivers Disk" +PortsClassName = "Ports (COM & LPT)" +VID_0403&PID_6001.DeviceDesc="USB Serial Port" +VID_0403&PID_6010.DeviceDesc="USB Serial Port" +VID_0403&PID_6011.DeviceDesc="USB Serial Port" +VID_0403&PID_6014.DeviceDesc="USB Serial Port" +VID_0403&PID_6015.DeviceDesc="USB Serial Port" +VID_0403&PID_6031.DeviceDesc="USB Serial Port" +VID_0403&PID_6032.DeviceDesc="USB Serial Port" +VID_0403&PID_6033.DeviceDesc="USB Serial Port" +VID_0403&PID_6034.DeviceDesc="USB Serial Port" +VID_0403&PID_6035.DeviceDesc="USB Serial Port" +VID_0403&PID_6036.DeviceDesc="USB Serial Port" +VID_0403&PID_6037.DeviceDesc="USB Serial Port" +VID_0403&PID_6038.DeviceDesc="USB Serial Port" +VID_0403&PID_6039.DeviceDesc="USB Serial Port" +VID_0403&PID_603A.DeviceDesc="USB Serial Port" +VID_0403&PID_6040.DeviceDesc="USB Serial Port" +VID_0403&PID_6041.DeviceDesc="USB Serial Port" +VID_0403&PID_6042.DeviceDesc="USB Serial Port" +VID_0403&PID_6043.DeviceDesc="USB Serial Port" +VID_0403&PID_6044.DeviceDesc="USB Serial Port" +VID_0403&PID_6045.DeviceDesc="USB Serial Port" +VID_0403&PID_6047.DeviceDesc="USB Serial Port" +VID_0403&PID_6048.DeviceDesc="USB Serial Port" +VID_0403&PID_6049.DeviceDesc="USB Serial Port" +VID_0403&PID_0000.DeviceDesc="USB Serial Port" +SvcDesc="USB Serial Port Driver" +SerEnum.SvcDesc="Serenum Filter Driver" + + diff --git a/drivers/FTDI USB Drivers/i386/ftbusui.dll b/drivers/FTDI USB Drivers/i386/ftbusui.dll new file mode 100644 index 000000000..0ce241ea2 Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftbusui.dll differ diff --git a/drivers/FTDI USB Drivers/i386/ftcserco.dll b/drivers/FTDI USB Drivers/i386/ftcserco.dll new file mode 100644 index 000000000..db592a250 Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftcserco.dll differ diff --git a/drivers/FTDI USB Drivers/i386/ftd2xx.dll b/drivers/FTDI USB Drivers/i386/ftd2xx.dll new file mode 100644 index 000000000..1ae4df40f Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftd2xx.dll differ diff --git a/drivers/FTDI USB Drivers/i386/ftd2xx.lib b/drivers/FTDI USB Drivers/i386/ftd2xx.lib new file mode 100644 index 000000000..5dc71ee5b Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftd2xx.lib differ diff --git a/drivers/FTDI USB Drivers/i386/ftdibus.sys b/drivers/FTDI USB Drivers/i386/ftdibus.sys new file mode 100644 index 000000000..ccc4d9c0e Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftdibus.sys differ diff --git a/drivers/FTDI USB Drivers/i386/ftlang.dll b/drivers/FTDI USB Drivers/i386/ftlang.dll new file mode 100644 index 000000000..9499e3844 Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftlang.dll differ diff --git a/drivers/FTDI USB Drivers/i386/ftser2k.sys b/drivers/FTDI USB Drivers/i386/ftser2k.sys new file mode 100644 index 000000000..872bd52c0 Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftser2k.sys differ diff --git a/drivers/FTDI USB Drivers/i386/ftserui2.dll b/drivers/FTDI USB Drivers/i386/ftserui2.dll new file mode 100644 index 000000000..d627ccf52 Binary files /dev/null and b/drivers/FTDI USB Drivers/i386/ftserui2.dll differ diff --git a/drivers/arduino-org.cat b/drivers/arduino-org.cat new file mode 100644 index 000000000..ade6926c5 Binary files /dev/null and b/drivers/arduino-org.cat differ diff --git a/drivers/arduino-org.inf b/drivers/arduino-org.inf new file mode 100644 index 000000000..522cbbdee --- /dev/null +++ b/drivers/arduino-org.inf @@ -0,0 +1,224 @@ +; Copyright 2012 Blacklabel Development, Inc. + +[Strings] +DriverPackageDisplayName="Arduino USB Driver" +ManufacturerName="Arduino Srl (www.arduino.org)" +ServiceName="USB RS-232 Emulation Driver" + +due.bossa.name="Bossa Program Port" +due.programming_port.name="Arduino Due Programming Port" +due.sketch.name="Arduino Due" +esplora.bootloader.name="Arduino Esplora bootloader" +esplora.sketch.name="Arduino Esplora" +leonardo.bootloader.name="Arduino Leonardo bootloader" +leonardo.sketch.name="Arduino Leonardo" +leonardoeth.bootloader.name="Arduino Leonardo ETH bootloader" +leonardoeth.sketch.name="Arduino Leonardo ETH" +lilypadUSB.bootloader.name="Arduino LilyPad USB bootloader" +lilypadUSB.sketch.name="Arduino LilyPad USB" +mega2560.name="Arduino Mega 2560" +mega2560rev3.name="Arduino Mega 2560" +megaADK.name="Arduino Mega ADK" +megaADKrev3.name="Arduino Mega ADK" +micro.bootloader.name="Arduino Micro bootloader" +micro.sketch.name="Arduino Micro" +unoR3.name="Arduino Uno" +unowifi.name="Arduino Uno WiFi" +usbserial.name="Arduino USB Serial Light Adapter" +robotControl.bootloader.name="Arduino Robot Control bootloader" +robotControl.sketch.name="Arduino Robot" +robotMotor.bootloader.name="Arduino Robot Motor bootloader" +robotMotor.sketch.name="Arduino Robot" +yun.bootloader.name="Arduino Yun bootloader" +yun.sketch.name="Arduino Yun" +yunmini.bootloader.name="Arduino Yun Mini bootloader" +yunmini.sketch.name="Arduino Yun Mini" +industrial101.bootloader.name="Arduino Industrial 101 bootloader" +industrial101.sketch.name="Arduino Industrial 101" + +zero_pro.edbg.name="Atmel Corp. EDBG USB Port" +zero_pro.usbport.name="Arduino Zero PRO Native Port" +zero_pro_boot.usbport.name="Arduino Zero PRO (Bootloader Mode) Native Port" +m0_pro.edbg.name="Atmel Corp. EDBG USB Port" +m0_pro.usbport.name="Arduino M0 PRO Native Port" +m0_pro_boot.usbport.name="Arduino M0 PRO (Bootloader Mode) Native Port" + +m0.usbport.name="Arduino M0 Native Port" +m0_boot.usbport.name="Arduino M0 (Bootloader Mode) Native Port" + +microADK.bootloader.name="Arduino Micro ADK bootloader" +microADK.sketch.name="Arduino Micro ADK" + +[DefaultInstall] +CopyINF=arduino-org.inf + +[Version] +Class=Ports +ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} +Signature="$Windows NT$" +Provider=%ManufacturerName% +DriverPackageDisplayName=%DriverPackageDisplayName% +CatalogFile=arduino-org.cat +DriverVer=03/19/2015,1.1.1.0 + +[Manufacturer] +%ManufacturerName%=DeviceList, NTamd64, NTia64 + +[DestinationDirs] +FakeModemCopyFileSection=12 +DefaultDestDir=12 + +[DeviceList] +%due.bossa.name%=DriverInstall, USB\VID_03EB&PID_6124 +%due.programming_port.name%=DriverInstall, USB\VID_2A03&PID_003D +%due.sketch.name%=DriverInstall, USB\VID_2A03&PID_003E&MI_00 +%esplora.bootloader.name%=DriverInstall, USB\VID_2A03&PID_003C +%esplora.sketch.name%=DriverInstall, USB\VID_2A03&PID_803C&MI_00 +%leonardo.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0036 +%leonardo.sketch.name%=DriverInstall, USB\VID_2A03&PID_8036&MI_00 +%leonardoeth.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0040 +%leonardoeth.sketch.name%=DriverInstall, USB\VID_2A03&PID_8040&MI_00 +%lilypadUSB.bootloader.name%=DriverInstall, USB\VID_1B4F&PID_9207 +%lilypadUSB.sketch.name%=DriverInstall, USB\VID_1B4F&PID_9208&MI_00 +%mega2560rev3.name%=DriverInstall, USB\VID_2A03&PID_0042 +%mega2560.name%=DriverInstall, USB\VID_2A03&PID_0010 +%megaADK.name%=DriverInstall, USB\VID_2A03&PID_002F +%megaADKrev3.name%=DriverInstall, USB\VID_2A03&PID_0044 +%micro.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0037 +%micro.sketch.name%=DriverInstall, USB\VID_2A03&PID_8037&MI_00 +%unoR3.name%=DriverInstall, USB\VID_2A03&PID_0043 +%unowifi.name%=DriverInstall, USB\VID_2A03&PID_0057 +%usbserial.name%=DriverInstall, USB\VID_2A03&PID_003B +%robotControl.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0038 +%robotControl.sketch.name%=DriverInstall, USB\VID_2A03&PID_8038&MI_00 +%robotMotor.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0039 +%robotMotor.sketch.name%=DriverInstall, USB\VID_2A03&PID_8039&MI_00 +%yun.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0041 +%yun.sketch.name%=DriverInstall, USB\VID_2A03&PID_8041&MI_00 +%yunmini.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0050 +%yunmini.sketch.name%=DriverInstall, USB\VID_2A03&PID_8050&MI_00 +%industrial101.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0056 +%industrial101.sketch.name%=DriverInstall, USB\VID_2A03&PID_8056&MI_00 + +%zero_pro.edbg.name%=DriverInstall, USB\VID_03EB&PID_2111&MI_01 +%zero_pro.usbport.name%=DriverInstall, USB\VID_2A03&PID_804D +%zero_pro_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004D +%m0_pro.edbg.name%=DriverInstall, USB\VID_03EB&PID_2111&MI_01 +%m0_pro.usbport.name%=DriverInstall, USB\VID_2A03&PID_804F +%m0_pro_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004F + +%m0.usbport.name%=DriverInstall, USB\VID_2A03&PID_804E +%m0_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004E + +%microADK.bootloader.name%=DriverInstall, USB\VID_2A03&PID_003A +%microADK.sketch.name%=DriverInstall, USB\VID_2A03&PID_803A&MI_00 + +[DeviceList.NTamd64] +%due.bossa.name%=DriverInstall, USB\VID_03EB&PID_6124 +%due.programming_port.name%=DriverInstall, USB\VID_2A03&PID_003D +%due.sketch.name%=DriverInstall, USB\VID_2A03&PID_003E&MI_00 +%esplora.bootloader.name%=DriverInstall, USB\VID_2A03&PID_003C +%esplora.sketch.name%=DriverInstall, USB\VID_2A03&PID_803C&MI_00 +%leonardo.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0036 +%leonardo.sketch.name%=DriverInstall, USB\VID_2A03&PID_8036&MI_00 +%leonardoeth.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0040 +%leonardoeth.sketch.name%=DriverInstall, USB\VID_2A03&PID_8040&MI_00 +%lilypadUSB.bootloader.name%=DriverInstall, USB\VID_1B4F&PID_9207 +%lilypadUSB.sketch.name%=DriverInstall, USB\VID_1B4F&PID_9208&MI_00 +%mega2560rev3.name%=DriverInstall, USB\VID_2A03&PID_0042 +%mega2560.name%=DriverInstall, USB\VID_2A03&PID_0010 +%megaADK.name%=DriverInstall, USB\VID_2A03&PID_002F +%megaADKrev3.name%=DriverInstall, USB\VID_2A03&PID_0044 +%micro.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0037 +%micro.sketch.name%=DriverInstall, USB\VID_2A03&PID_8037&MI_00 +%unoR3.name%=DriverInstall, USB\VID_2A03&PID_0043 +%unowifi.name%=DriverInstall, USB\VID_2A03&PID_0057 +%usbserial.name%=DriverInstall, USB\VID_2A03&PID_003B +%robotControl.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0038 +%robotControl.sketch.name%=DriverInstall, USB\VID_2A03&PID_8038&MI_00 +%robotMotor.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0039 +%robotMotor.sketch.name%=DriverInstall, USB\VID_2A03&PID_8039&MI_00 +%yun.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0041 +%yun.sketch.name%=DriverInstall, USB\VID_2A03&PID_8041&MI_00 +%yunmini.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0050 +%yunmini.sketch.name%=DriverInstall, USB\VID_2A03&PID_8050&MI_00 +%industrial101.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0056 +%industrial101.sketch.name%=DriverInstall, USB\VID_2A03&PID_8056&MI_00 + +%zero_pro.edbg.name%=DriverInstall, USB\VID_03EB&PID_2111&MI_01 +%zero_pro_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004D +%zero_pro.usbport.name%=DriverInstall, USB\VID_2A03&PID_804D +%m0_pro.edbg.name%=DriverInstall, USB\VID_03EB&PID_2111&MI_01 +%m0_pro.usbport.name%=DriverInstall, USB\VID_2A03&PID_804F +%m0_pro_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004F + +%m0.usbport.name%=DriverInstall, USB\VID_2A03&PID_804E +%m0_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004E + +%microADK.bootloader.name%=DriverInstall, USB\VID_2A03&PID_003A +%microADK.sketch.name%=DriverInstall, USB\VID_2A03&PID_803A&MI_00 + +[DeviceList.NTia64] +%esplora.bootloader.name%=DriverInstall, USB\VID_2A03&PID_003C +%esplora.sketch.name%=DriverInstall, USB\VID_2A03&PID_803C&MI_00 +%leonardo.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0036 +%leonardo.sketch.name%=DriverInstall, USB\VID_2A03&PID_8036&MI_00 +%leonardoeth.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0040 +%leonardoeth.sketch.name%=DriverInstall, USB\VID_2A03&PID_8040&MI_00 +%lilypadUSB.bootloader.name%=DriverInstall, USB\VID_1B4F&PID_9207 +%lilypadUSB.sketch.name%=DriverInstall, USB\VID_1B4F&PID_9208&MI_00 +%mega2560rev3.name%=DriverInstall, USB\VID_2A03&PID_0042 +%mega2560.name%=DriverInstall, USB\VID_2A03&PID_0010 +%megaADK.name%=DriverInstall, USB\VID_2A03&PID_002F +%megaADKrev3.name%=DriverInstall, USB\VID_2A03&PID_0044 +%micro.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0037 +%micro.sketch.name%=DriverInstall, USB\VID_2A03&PID_8037&MI_00 +%unoR3.name%=DriverInstall, USB\VID_2A03&PID_0043 +%unowifi.name%=DriverInstall, USB\VID_2A03&PID_0057 +%usbserial.name%=DriverInstall, USB\VID_2A03&PID_003B +%robotControl.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0038 +%robotControl.sketch.name%=DriverInstall, USB\VID_2A03&PID_8038&MI_00 +%robotMotor.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0039 +%robotMotor.sketch.name%=DriverInstall, USB\VID_2A03&PID_8039&MI_00 +%yun.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0041 +%yun.sketch.name%=DriverInstall, USB\VID_2A03&PID_8041&MI_00 +%yunmini.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0050 +%yunmini.sketch.name%=DriverInstall, USB\VID_2A03&PID_8050&MI_00 +%industrial101.bootloader.name%=DriverInstall, USB\VID_2A03&PID_0056 +%industrial101.sketch.name%=DriverInstall, USB\VID_2A03&PID_8056&MI_00 + +%zero_pro.edbg.name%=DriverInstall, USB\VID_03EB&PID_2111&MI_01 +%zero_pro_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004D +%zero_pro.usbport.name%=DriverInstall, USB\VID_2A03&PID_804D + +%m0_pro.edbg.name%=DriverInstall, USB\VID_03EB&PID_2111&MI_01 +%m0_pro.usbport.name%=DriverInstall, USB\VID_2A03&PID_804F +%m0_pro_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004F + +%m0.usbport.name%=DriverInstall, USB\VID_2A03&PID_804E +%m0_boot.usbport.name%=DriverInstall, USB\VID_2A03&PID_004E + +%microADK.bootloader.name%=DriverInstall, USB\VID_2A03&PID_003A +%microADK.sketch.name%=DriverInstall, USB\VID_2A03&PID_803A&MI_00 + +[DriverInstall] +include=mdmcpq.inf,usb.inf +CopyFiles = FakeModemCopyFileSection +AddReg=DriverAddReg + +[DriverAddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,usbser.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.Services] +include=mdmcpq.inf +AddService=usbser, 0x00000002, DriverService + +[DriverService] +DisplayName=%ServiceName% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\usbser.sys +LoadOrderGroup=Base \ No newline at end of file diff --git a/drivers/arduino.cat b/drivers/arduino.cat new file mode 100644 index 000000000..bd7fe2b80 Binary files /dev/null and b/drivers/arduino.cat differ diff --git a/drivers/arduino.inf b/drivers/arduino.inf new file mode 100644 index 000000000..c0284efcf --- /dev/null +++ b/drivers/arduino.inf @@ -0,0 +1,213 @@ +; +; Copyright 2015 Arduino LLC (http://www.arduino.cc/) +; +; Developed by Zach Eveland, Blacklabel Development, Inc. +; +; Arduino is free software; you can redistribute it and/or modify +; it under the terms of the GNU General Public License as published by +; the Free Software Foundation; either version 2 of the License, or +; (at your option) any later version. +; +; This program is distributed in the hope that it will be useful, +; but WITHOUT ANY WARRANTY; without even the implied warranty of +; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +; GNU General Public License for more details. +; +; You should have received a copy of the GNU General Public License +; along with this program; if not, write to the Free Software +; Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +; +; As a special exception, you may use this file as part of a free software +; library without restriction. Specifically, if other files instantiate +; templates or use macros or inline functions from this file, or you compile +; this file and link it with other files to produce an executable, this +; file does not by itself cause the resulting executable to be covered by +; the GNU General Public License. This exception does not however +; invalidate any other reasons why the executable file might be covered by +; the GNU General Public License. +; + +[Strings] +DriverPackageDisplayName="Arduino USB Driver" +ManufacturerName="Arduino LLC (www.arduino.cc)" +ServiceName="USB RS-232 Emulation Driver" +bossa.name="Bossa Program Port" +due.programming_port.name="Arduino Due Programming Port" +due.sketch.name="Arduino Due" +esplora.bootloader.name="Arduino Esplora bootloader" +esplora.sketch.name="Arduino Esplora" +leonardo.bootloader.name="Arduino Leonardo bootloader" +leonardo.sketch.name="Arduino Leonardo" +lilypadUSB.bootloader.name="Arduino LilyPad USB bootloader" +lilypadUSB.sketch.name="Arduino LilyPad USB" +mega2560.name="Arduino Mega 2560" +mega2560rev3.name="Arduino Mega 2560" +megaADK.name="Arduino Mega ADK" +megaADKrev3.name="Arduino Mega ADK" +micro.bootloader.name="Arduino Micro bootloader" +micro.sketch.name="Arduino Micro" +mkr1000.sketch.name="Arduino MKR1000" +mkr1000.bootloader.name="Arduino MKR1000 bootloader" +robotControl.bootloader.name="Arduino Robot Control bootloader" +robotControl.sketch.name="Arduino Robot" +robotMotor.bootloader.name="Arduino Robot Motor bootloader" +robotMotor.sketch.name="Arduino Robot" +uno.name="Arduino Uno" +unoR3.name="Arduino Uno" +unomini.name="Arduino Uno Mini" +makeyourunokit.name="Arduino Make Your Uno Kit" +usbserial.name="Arduino USB Serial Light Adapter" +yun.bootloader.name="Arduino Yun bootloader" +yun.sketch.name="Arduino Yun" +zero.edbg.name="Atmel Corp. EDBG CMSIS-DAP" +zero.sketch.name="Arduino Zero" +zero.bootloader.name="Arduino Zero bootloader" +sme_fox.sketch.name="SmartEverything Fox" +sme_fox.bootloader.name="SmartEverything Fox bootloader" + +[DefaultInstall] +CopyINF=arduino.inf + +[Version] +Class=Ports +ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} +Signature="$Windows NT$" +Provider=%ManufacturerName% +DriverPackageDisplayName=%DriverPackageDisplayName% +CatalogFile=arduino.cat +DriverVer=11/24/2015,1.2.3.0 + +[Manufacturer] +%ManufacturerName%=DeviceList, NTamd64, NTia64 + +[DestinationDirs] +FakeModemCopyFileSection=12 +DefaultDestDir=12 + +[DeviceList] +%bossa.name%=DriverInstall, USB\VID_03EB&PID_6124 +%due.programming_port.name%=DriverInstall, USB\VID_2341&PID_003D +%due.sketch.name%=DriverInstall, USB\VID_2341&PID_003E&MI_00 +%esplora.bootloader.name%=DriverInstall, USB\VID_2341&PID_003C +%esplora.sketch.name%=DriverInstall, USB\VID_2341&PID_803C&MI_00 +%leonardo.bootloader.name%=DriverInstall, USB\VID_2341&PID_0036 +%leonardo.sketch.name%=DriverInstall, USB\VID_2341&PID_8036&MI_00 +%lilypadUSB.bootloader.name%=DriverInstall, USB\VID_1B4F&PID_9207 +%lilypadUSB.sketch.name%=DriverInstall, USB\VID_1B4F&PID_9208&MI_00 +%mega2560rev3.name%=DriverInstall, USB\VID_2341&PID_0042 +%mega2560.name%=DriverInstall, USB\VID_2341&PID_0010 +%megaADK.name%=DriverInstall, USB\VID_2341&PID_003F +%megaADKrev3.name%=DriverInstall, USB\VID_2341&PID_0044 +%micro.bootloader.name%=DriverInstall, USB\VID_2341&PID_0037 +%micro.sketch.name%=DriverInstall, USB\VID_2341&PID_8037&MI_00 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_804E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_004E +%robotControl.bootloader.name%=DriverInstall, USB\VID_2341&PID_0038 +%robotControl.sketch.name%=DriverInstall, USB\VID_2341&PID_8038&MI_00 +%robotMotor.bootloader.name%=DriverInstall, USB\VID_2341&PID_0039 +%robotMotor.sketch.name%=DriverInstall, USB\VID_2341&PID_8039&MI_00 +%uno.name%=DriverInstall, USB\VID_2341&PID_0001 +%unoR3.name%=DriverInstall, USB\VID_2341&PID_0043 +%unomini.name%=DriverInstall, USB\VID_2341&PID_0062 +%makeyourunokit.name%=DriverInstall, USB\VID_2341&PID_006A +%usbserial.name%=DriverInstall, USB\VID_2341&PID_003B +%yun.bootloader.name%=DriverInstall, USB\VID_2341&PID_0041 +%yun.sketch.name%=DriverInstall, USB\VID_2341&PID_8041&MI_00 +%zero.edbg.name%=DriverInstall, USB\VID_03EB&PID_2157&MI_01 +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_804D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_004D +%sme_fox.sketch.name%=DriverInstall, USB\VID_2341&PID_E002&MI_00 +%sme_fox.bootloader.name%=DriverInstall, USB\VID_2341&PID_E001 + +[DeviceList.NTamd64] +%bossa.name%=DriverInstall, USB\VID_03EB&PID_6124 +%due.programming_port.name%=DriverInstall, USB\VID_2341&PID_003D +%due.sketch.name%=DriverInstall, USB\VID_2341&PID_003E&MI_00 +%esplora.bootloader.name%=DriverInstall, USB\VID_2341&PID_003C +%esplora.sketch.name%=DriverInstall, USB\VID_2341&PID_803C&MI_00 +%leonardo.bootloader.name%=DriverInstall, USB\VID_2341&PID_0036 +%leonardo.sketch.name%=DriverInstall, USB\VID_2341&PID_8036&MI_00 +%lilypadUSB.bootloader.name%=DriverInstall, USB\VID_1B4F&PID_9207 +%lilypadUSB.sketch.name%=DriverInstall, USB\VID_1B4F&PID_9208&MI_00 +%mega2560rev3.name%=DriverInstall, USB\VID_2341&PID_0042 +%mega2560.name%=DriverInstall, USB\VID_2341&PID_0010 +%megaADK.name%=DriverInstall, USB\VID_2341&PID_003F +%megaADKrev3.name%=DriverInstall, USB\VID_2341&PID_0044 +%micro.bootloader.name%=DriverInstall, USB\VID_2341&PID_0037 +%micro.sketch.name%=DriverInstall, USB\VID_2341&PID_8037&MI_00 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_804E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_004E +%uno.name%=DriverInstall, USB\VID_2341&PID_0001 +%unoR3.name%=DriverInstall, USB\VID_2341&PID_0043 +%unomini.name%=DriverInstall, USB\VID_2341&PID_0062 +%makeyourunokit.name%=DriverInstall, USB\VID_2341&PID_006A +%usbserial.name%=DriverInstall, USB\VID_2341&PID_003B +%robotControl.bootloader.name%=DriverInstall, USB\VID_2341&PID_0038 +%robotControl.sketch.name%=DriverInstall, USB\VID_2341&PID_8038&MI_00 +%robotMotor.bootloader.name%=DriverInstall, USB\VID_2341&PID_0039 +%robotMotor.sketch.name%=DriverInstall, USB\VID_2341&PID_8039&MI_00 +%yun.bootloader.name%=DriverInstall, USB\VID_2341&PID_0041 +%yun.sketch.name%=DriverInstall, USB\VID_2341&PID_8041&MI_00 +%zero.edbg.name%=DriverInstall, USB\VID_03EB&PID_2157&MI_01 +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_804D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_004D +%sme_fox.sketch.name%=DriverInstall, USB\VID_2341&PID_E002&MI_00 +%sme_fox.bootloader.name%=DriverInstall, USB\VID_2341&PID_E001 + +[DeviceList.NTia64] +%bossa.name%=DriverInstall, USB\VID_03EB&PID_6124 +%due.programming_port.name%=DriverInstall, USB\VID_2341&PID_003D +%due.sketch.name%=DriverInstall, USB\VID_2341&PID_003E&MI_00 +%esplora.bootloader.name%=DriverInstall, USB\VID_2341&PID_003C +%esplora.sketch.name%=DriverInstall, USB\VID_2341&PID_803C&MI_00 +%leonardo.bootloader.name%=DriverInstall, USB\VID_2341&PID_0036 +%leonardo.sketch.name%=DriverInstall, USB\VID_2341&PID_8036&MI_00 +%lilypadUSB.bootloader.name%=DriverInstall, USB\VID_1B4F&PID_9207 +%lilypadUSB.sketch.name%=DriverInstall, USB\VID_1B4F&PID_9208&MI_00 +%mega2560rev3.name%=DriverInstall, USB\VID_2341&PID_0042 +%mega2560.name%=DriverInstall, USB\VID_2341&PID_0010 +%megaADK.name%=DriverInstall, USB\VID_2341&PID_003F +%megaADKrev3.name%=DriverInstall, USB\VID_2341&PID_0044 +%micro.bootloader.name%=DriverInstall, USB\VID_2341&PID_0037 +%micro.sketch.name%=DriverInstall, USB\VID_2341&PID_8037&MI_00 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_804E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_004E +%uno.name%=DriverInstall, USB\VID_2341&PID_0001 +%unoR3.name%=DriverInstall, USB\VID_2341&PID_0043 +%unomini.name%=DriverInstall, USB\VID_2341&PID_0062 +%makeyourunokit.name%=DriverInstall, USB\VID_2341&PID_006A +%usbserial.name%=DriverInstall, USB\VID_2341&PID_003B +%robotControl.bootloader.name%=DriverInstall, USB\VID_2341&PID_0038 +%robotControl.sketch.name%=DriverInstall, USB\VID_2341&PID_8038&MI_00 +%robotMotor.bootloader.name%=DriverInstall, USB\VID_2341&PID_0039 +%robotMotor.sketch.name%=DriverInstall, USB\VID_2341&PID_8039&MI_00 +%yun.bootloader.name%=DriverInstall, USB\VID_2341&PID_0041 +%yun.sketch.name%=DriverInstall, USB\VID_2341&PID_8041&MI_00 +%zero.edbg.name%=DriverInstall, USB\VID_03EB&PID_2157&MI_01 +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_804D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_004D +%sme_fox.sketch.name%=DriverInstall, USB\VID_2341&PID_E002&MI_00 +%sme_fox.bootloader.name%=DriverInstall, USB\VID_2341&PID_E001 + +[DriverInstall] +include=mdmcpq.inf,usb.inf +CopyFiles = FakeModemCopyFileSection +AddReg=DriverAddReg + +[DriverAddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,usbser.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.Services] +include=mdmcpq.inf +AddService=usbser, 0x00000002, DriverService + +[DriverService] +DisplayName=%ServiceName% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\usbser.sys +LoadOrderGroup=Base + diff --git a/drivers/dpinst-amd64.exe b/drivers/dpinst-amd64.exe new file mode 100644 index 000000000..0507e7388 Binary files /dev/null and b/drivers/dpinst-amd64.exe differ diff --git a/drivers/dpinst-x86.exe b/drivers/dpinst-x86.exe new file mode 100644 index 000000000..41a890d11 Binary files /dev/null and b/drivers/dpinst-x86.exe differ diff --git a/drivers/gemma/amd64/libusb0.dll b/drivers/gemma/amd64/libusb0.dll new file mode 100644 index 000000000..f916b0898 Binary files /dev/null and b/drivers/gemma/amd64/libusb0.dll differ diff --git a/drivers/gemma/amd64/libusb0.sys b/drivers/gemma/amd64/libusb0.sys new file mode 100644 index 000000000..0718dfb7c Binary files /dev/null and b/drivers/gemma/amd64/libusb0.sys differ diff --git a/drivers/gemma/arduino_gemma.cat b/drivers/gemma/arduino_gemma.cat new file mode 100644 index 000000000..0b327b633 Binary files /dev/null and b/drivers/gemma/arduino_gemma.cat differ diff --git a/drivers/gemma/arduino_gemma.inf b/drivers/gemma/arduino_gemma.inf new file mode 100644 index 000000000..91976882e Binary files /dev/null and b/drivers/gemma/arduino_gemma.inf differ diff --git a/drivers/gemma/ia64/libusb0.dll b/drivers/gemma/ia64/libusb0.dll new file mode 100644 index 000000000..292df2785 Binary files /dev/null and b/drivers/gemma/ia64/libusb0.dll differ diff --git a/drivers/gemma/ia64/libusb0.sys b/drivers/gemma/ia64/libusb0.sys new file mode 100644 index 000000000..f17914b8c Binary files /dev/null and b/drivers/gemma/ia64/libusb0.sys differ diff --git a/drivers/gemma/license/libusb0/installer_license.txt b/drivers/gemma/license/libusb0/installer_license.txt new file mode 100644 index 000000000..56bb2cda2 --- /dev/null +++ b/drivers/gemma/license/libusb0/installer_license.txt @@ -0,0 +1,851 @@ +Copyright (c) 2002-2004 Stephan Meyer, +Copyright (c) 2000-2004 Johannes Erdfelt, +Copyright (c) 2000-2004 Thomas Sailer, +Copyright (c) 2010 Travis Robinson, + +This software is distributed under the following licenses: +Driver: GNU General Public License (GPL) +Library, Test Files, Installer: GNU Lesser General Public License (LGPL) + +*********************************************************************** + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. + + GNU LESSER GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + + This version of the GNU Lesser General Public License incorporates +the terms and conditions of version 3 of the GNU General Public +License, supplemented by the additional permissions listed below. + + 0. Additional Definitions. + + As used herein, "this License" refers to version 3 of the GNU Lesser +General Public License, and the "GNU GPL" refers to version 3 of the GNU +General Public License. + + "The Library" refers to a covered work governed by this License, +other than an Application or a Combined Work as defined below. + + An "Application" is any work that makes use of an interface provided +by the Library, but which is not otherwise based on the Library. +Defining a subclass of a class defined by the Library is deemed a mode +of using an interface provided by the Library. + + A "Combined Work" is a work produced by combining or linking an +Application with the Library. The particular version of the Library +with which the Combined Work was made is also called the "Linked +Version". + + The "Minimal Corresponding Source" for a Combined Work means the +Corresponding Source for the Combined Work, excluding any source code +for portions of the Combined Work that, considered in isolation, are +based on the Application, and not on the Linked Version. + + The "Corresponding Application Code" for a Combined Work means the +object code and/or source code for the Application, including any data +and utility programs needed for reproducing the Combined Work from the +Application, but excluding the System Libraries of the Combined Work. + + 1. Exception to Section 3 of the GNU GPL. + + You may convey a covered work under sections 3 and 4 of this License +without being bound by section 3 of the GNU GPL. + + 2. Conveying Modified Versions. + + If you modify a copy of the Library, and, in your modifications, a +facility refers to a function or data to be supplied by an Application +that uses the facility (other than as an argument passed when the +facility is invoked), then you may convey a copy of the modified +version: + + a) under this License, provided that you make a good faith effort to + ensure that, in the event an Application does not supply the + function or data, the facility still operates, and performs + whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of + this License applicable to that copy. + + 3. Object Code Incorporating Material from Library Header Files. + + The object code form of an Application may incorporate material from +a header file that is part of the Library. You may convey such object +code under terms of your choice, provided that, if the incorporated +material is not limited to numerical parameters, data structure +layouts and accessors, or small macros, inline functions and templates +(ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the + Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license + document. + + 4. Combined Works. + + You may convey a Combined Work under terms of your choice that, +taken together, effectively do not restrict modification of the +portions of the Library contained in the Combined Work and reverse +engineering for debugging such modifications, if you also do each of +the following: + + a) Give prominent notice with each copy of the Combined Work that + the Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license + document. + + c) For a Combined Work that displays copyright notices during + execution, include the copyright notice for the Library among + these notices, as well as a reference directing the user to the + copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this + License, and the Corresponding Application Code in a form + suitable for, and under terms that permit, the user to + recombine or relink the Application with a modified version of + the Linked Version to produce a modified Combined Work, in the + manner specified by section 6 of the GNU GPL for conveying + Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (a) uses at run time + a copy of the Library already present on the user's computer + system, and (b) will operate properly with a modified version + of the Library that is interface-compatible with the Linked + Version. + + e) Provide Installation Information, but only if you would otherwise + be required to provide such information under section 6 of the + GNU GPL, and only to the extent that such information is + necessary to install and execute a modified version of the + Combined Work produced by recombining or relinking the + Application with a modified version of the Linked Version. (If + you use option 4d0, the Installation Information must accompany + the Minimal Corresponding Source and Corresponding Application + Code. If you use option 4d1, you must provide the Installation + Information in the manner specified by section 6 of the GNU GPL + for conveying Corresponding Source.) + + 5. Combined Libraries. + + You may place library facilities that are a work based on the +Library side by side in a single library together with other library +facilities that are not Applications and are not covered by this +License, and convey such a combined library under terms of your +choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based + on the Library, uncombined with any other library facilities, + conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it + is a work based on the Library, and explaining where to find the + accompanying uncombined form of the same work. + + 6. Revised Versions of the GNU Lesser General Public License. + + The Free Software Foundation may publish revised and/or new versions +of the GNU Lesser General Public License from time to time. Such new +versions will be similar in spirit to the present version, but may +differ in detail to address new problems or concerns. + + Each version is given a distinguishing version number. If the +Library as you received it specifies that a certain numbered version +of the GNU Lesser General Public License "or any later version" +applies to it, you have the option of following the terms and +conditions either of that published version or of any later version +published by the Free Software Foundation. If the Library as you +received it does not specify a version number of the GNU Lesser +General Public License, you may choose any version of the GNU Lesser +General Public License ever published by the Free Software Foundation. + + If the Library as you received it specifies that a proxy can decide +whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is +permanent authorization for you to choose that version for the +Library. + diff --git a/drivers/gemma/x86/libusb0.sys b/drivers/gemma/x86/libusb0.sys new file mode 100644 index 000000000..5322e5b97 Binary files /dev/null and b/drivers/gemma/x86/libusb0.sys differ diff --git a/drivers/gemma/x86/libusb0_x86.dll b/drivers/gemma/x86/libusb0_x86.dll new file mode 100644 index 000000000..6e475b90a Binary files /dev/null and b/drivers/gemma/x86/libusb0_x86.dll differ diff --git a/drivers/genuino.cat b/drivers/genuino.cat new file mode 100644 index 000000000..cd84ce298 Binary files /dev/null and b/drivers/genuino.cat differ diff --git a/drivers/genuino.inf b/drivers/genuino.inf new file mode 100644 index 000000000..bcf3184f2 --- /dev/null +++ b/drivers/genuino.inf @@ -0,0 +1,114 @@ +; +; Copyright 2016 Arduino LLC (http://www.arduino.cc/) +; +; Developed by Zach Eveland, Blacklabel Development, Inc. +; +; Arduino is free software; you can redistribute it and/or modify +; it under the terms of the GNU General Public License as published by +; the Free Software Foundation; either version 2 of the License, or +; (at your option) any later version. +; +; This program is distributed in the hope that it will be useful, +; but WITHOUT ANY WARRANTY; without even the implied warranty of +; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +; GNU General Public License for more details. +; +; You should have received a copy of the GNU General Public License +; along with this program; if not, write to the Free Software +; Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +; +; As a special exception, you may use this file as part of a free software +; library without restriction. Specifically, if other files instantiate +; templates or use macros or inline functions from this file, or you compile +; this file and link it with other files to produce an executable, this +; file does not by itself cause the resulting executable to be covered by +; the GNU General Public License. This exception does not however +; invalidate any other reasons why the executable file might be covered by +; the GNU General Public License. +; + +[Strings] +DriverPackageDisplayName="Genuino USB Driver" +ManufacturerName="Arduino LLC (www.arduino.cc)" +ServiceName="USB RS-232 Emulation Driver" +unoR3.name="Genuino Uno" +mega2560rev3.name="Genuino Mega 2560" +micro.bootloader.name="Genuino Micro bootloader" +micro.sketch.name="Genuino Micro" +mkr1000.sketch.name="Genuino MKR1000" +mkr1000.bootloader.name="Genuino MKR1000 bootloader" +zero.sketch.name="Genuino Zero" +zero.bootloader.name="Genuino Zero bootloader" + +[DefaultInstall] +CopyINF=genuino.inf + +[Version] +Class=Ports +ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} +Signature="$Windows NT$" +Provider=%ManufacturerName% +DriverPackageDisplayName=%DriverPackageDisplayName% +CatalogFile=genuino.cat +; DriverVer date is MM/DD/YYYY +DriverVer=01/07/2016,1.0.3.0 + +[Manufacturer] +%ManufacturerName%=DeviceList, NTamd64, NTia64 + +[DestinationDirs] +FakeModemCopyFileSection=12 +DefaultDestDir=12 + +[DeviceList] +%mega2560rev3.name%=DriverInstall, USB\VID_2341&PID_0242 +%micro.bootloader.name%=DriverInstall, USB\VID_2341&PID_0237 +%micro.sketch.name%=DriverInstall, USB\VID_2341&PID_8237&MI_00 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_824E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_024E +%unoR3.name%=DriverInstall, USB\VID_2341&PID_0243 +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_824D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_024D + +[DeviceList.NTamd64] +%mega2560rev3.name%=DriverInstall, USB\VID_2341&PID_0242 +%micro.bootloader.name%=DriverInstall, USB\VID_2341&PID_0237 +%micro.sketch.name%=DriverInstall, USB\VID_2341&PID_8237&MI_00 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_824E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_024E +%unoR3.name%=DriverInstall, USB\VID_2341&PID_0243 +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_824D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_024D + +[DeviceList.NTia64] +%mega2560rev3.name%=DriverInstall, USB\VID_2341&PID_0242 +%micro.bootloader.name%=DriverInstall, USB\VID_2341&PID_0237 +%micro.sketch.name%=DriverInstall, USB\VID_2341&PID_8237&MI_00 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_824E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_024E +%unoR3.name%=DriverInstall, USB\VID_2341&PID_0243 +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_824D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_024D + +[DriverInstall] +include=mdmcpq.inf,usb.inf +CopyFiles = FakeModemCopyFileSection +AddReg=DriverAddReg + +[DriverAddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,usbser.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.Services] +include=mdmcpq.inf +AddService=usbser, 0x00000002, DriverService + +[DriverService] +DisplayName=%ServiceName% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\usbser.sys +LoadOrderGroup=Base + diff --git a/drivers/linino-boards_amd64.cat b/drivers/linino-boards_amd64.cat new file mode 100644 index 000000000..08164c732 Binary files /dev/null and b/drivers/linino-boards_amd64.cat differ diff --git a/drivers/linino-boards_x86.cat b/drivers/linino-boards_x86.cat new file mode 100644 index 000000000..991ad60fa Binary files /dev/null and b/drivers/linino-boards_x86.cat differ diff --git a/drivers/linino.inf b/drivers/linino.inf new file mode 100644 index 000000000..dbb6f6883 --- /dev/null +++ b/drivers/linino.inf @@ -0,0 +1,110 @@ +;************************************************************ +; Windows USB CDC ACM Setup File +; Copyright (c) 2000 Microsoft Corporation + + +[Version] +Signature="$Windows NT$" +Class=Ports +ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} +Provider=%MFGNAME% +CatalogFile=%MFGFILENAME%.cat +CatalogFile.NTx86=%MFGFILENAME%_x86.cat +CatalogFile.NTIA64=%MFGFILENAME%_ia64.cat +CatalogFile.NTAMD64=%MFGFILENAME%_amd64.cat +DriverVer=01/13/2014,1.0.0.0 + +[Manufacturer] +%MFGNAME%=DeviceList, NTamd64 + +[DestinationDirs] +FakeModemCopyFileSection=12 +DefaultDestDir=12 + +;------------------------------------------------------------------------------ +; Windows 2000/XP/Vista-32bit Sections +;------------------------------------------------------------------------------ + +[DriverInstall.nt] +include=mdmcpq.inf +CopyFiles=FakeModemCopyFileSection +AddReg=DriverInstall.nt.AddReg + +;;[DriverCopyFiles.nt] +;;usbser.sys,,,0x20 + +[DriverInstall.nt.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,%DRIVERFILENAME%.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.nt.Services] +AddService=usbser, 0x00000002, DriverService.nt + +[DriverService.nt] +DisplayName=%SERVICE% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\%DRIVERFILENAME%.sys + +;------------------------------------------------------------------------------ +; Vista-64bit Sections +;------------------------------------------------------------------------------ + +[DriverInstall.NTamd64] +include=mdmcpq.inf +CopyFiles=FakeModemCopyFileSection +AddReg=DriverInstall.NTamd64.AddReg + +[DriverCopyFiles.NTamd64] +%DRIVERFILENAME%.sys,,,0x20 + +[DriverInstall.NTamd64.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,%DRIVERFILENAME%.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.NTamd64.Services] +AddService=usbser, 0x00000002, DriverService.NTamd64 + +[DriverService.NTamd64] +DisplayName=%SERVICE% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\%DRIVERFILENAME%.sys + + +;------------------------------------------------------------------------------ +; Vendor and Product ID Definitions +;------------------------------------------------------------------------------ +; When developing your USB device, the VID and PID used in the PC side +; application program and the firmware on the microcontroller must match. +; Modify the below line to use your VID and PID. Use the format as shown below. +; Note: One INF file can be used for multiple devices with different VID and PIDs. +; For each supported device, append ",USB\VID_xxxx&PID_yyyy" to the end of the line. +;------------------------------------------------------------------------------ +[SourceDisksFiles] +[SourceDisksNames] +[DeviceList] +%DESCRIPTION%=DriverInstall, USB\VID_2A03&PID_0001 +%DESCRIPTION%=DriverInstall, USB\VID_2A03&PID_8001&MI_00 + +[DeviceList.NTamd64] +%DESCRIPTION%=DriverInstall, USB\VID_2A03&PID_0001 +%DESCRIPTION%=DriverInstall, USB\VID_2A03&PID_0001&MI_00 + +;------------------------------------------------------------------------------ +; String Definitions +;------------------------------------------------------------------------------ +;Modify these strings to customize your device +;------------------------------------------------------------------------------ +[Strings] +MFGFILENAME="Linino-Boards" +DRIVERFILENAME ="usbser" +MFGNAME="Linino" +INSTDISK="Linino Driver Installer" +DESCRIPTION="Linino ONE" +SERVICE="USB RS-232 Emulation Driver" + diff --git a/firmwares/atmegaxxu2/arduino-usbdfu/makefile b/firmwares/atmegaxxu2/arduino-usbdfu/makefile index 1fb4ed346..96e50162c 100644 --- a/firmwares/atmegaxxu2/arduino-usbdfu/makefile +++ b/firmwares/atmegaxxu2/arduino-usbdfu/makefile @@ -171,7 +171,7 @@ DEBUG = dwarf-2 # List any extra directories to look for include files here. -# Each directory must be seperated by a space. +# Each directory must be separated by a space. # Use forward slashes for directory separators. # For a directory that has spaces, enclose it in quotes. EXTRAINCDIRS = $(LUFA_PATH)/ @@ -310,7 +310,7 @@ MATH_LIB = -lm # List any extra directories to look for libraries here. -# Each directory must be seperated by a space. +# Each directory must be separated by a space. # Use forward slashes for directory separators. # For a directory that has spaces, enclose it in quotes. EXTRALIBDIRS = diff --git a/firmwares/atmegaxxu2/arduino-usbserial/makefile b/firmwares/atmegaxxu2/arduino-usbserial/makefile index 79d6be231..6ce645ab4 100644 --- a/firmwares/atmegaxxu2/arduino-usbserial/makefile +++ b/firmwares/atmegaxxu2/arduino-usbserial/makefile @@ -188,7 +188,7 @@ DEBUG = dwarf-2 # List any extra directories to look for include files here. -# Each directory must be seperated by a space. +# Each directory must be separated by a space. # Use forward slashes for directory separators. # For a directory that has spaces, enclose it in quotes. EXTRAINCDIRS = $(LUFA_PATH)/ @@ -328,7 +328,7 @@ MATH_LIB = -lm # List any extra directories to look for libraries here. -# Each directory must be seperated by a space. +# Each directory must be separated by a space. # Use forward slashes for directory separators. # For a directory that has spaces, enclose it in quotes. EXTRALIBDIRS = diff --git a/libraries/EEPROM/README.md b/libraries/EEPROM/README.md index a62413613..9ca761d3a 100644 --- a/libraries/EEPROM/README.md +++ b/libraries/EEPROM/README.md @@ -53,7 +53,7 @@ This function does not return any value. This function will retrieve any object from the EEPROM. Two parameters are needed to call this function. The first is an `int` containing the address that is to be written, and the second is the object you would like to read. -This function returns a reference to the `object` passed in. It does not need to be used and is only returned for conveience. +This function returns a reference to the `object` passed in. It does not need to be used and is only returned for convenience. #### **`EEPROM.put( address, object )`** [[_example_]](examples/eeprom_put/eeprom_put.ino) @@ -62,7 +62,7 @@ Two parameters are needed to call this function. The first is an `int` containin This function uses the _update_ method to write its data, and therefore only rewrites changed cells. -This function returns a reference to the `object` passed in. It does not need to be used and is only returned for conveience. +This function returns a reference to the `object` passed in. It does not need to be used and is only returned for convenience. #### **Subscript operator: `EEPROM[address]`** [[_example_]](examples/eeprom_crc/eeprom_crc.ino) @@ -136,4 +136,4 @@ This is useful for STL objects, custom iteration and C++11 style ranged for loop This function returns an `EEPtr` pointing at the location after the last EEPROM cell. Used with `begin()` to provide custom iteration. -**Note:** The `EEPtr` returned is invalid as it is out of range. Infact the hardware causes wrapping of the address (overflow) and `EEPROM.end()` actually references the first EEPROM cell. +**Note:** The `EEPtr` returned is invalid as it is out of range. In fact the hardware causes wrapping of the address (overflow) and `EEPROM.end()` actually references the first EEPROM cell. diff --git a/libraries/EEPROM/examples/eeprom_clear/eeprom_clear.ino b/libraries/EEPROM/examples/eeprom_clear/eeprom_clear.ino index 8b5121c8c..3fed10fb8 100644 --- a/libraries/EEPROM/examples/eeprom_clear/eeprom_clear.ino +++ b/libraries/EEPROM/examples/eeprom_clear/eeprom_clear.ino @@ -18,9 +18,9 @@ void setup() { Iterate through each byte of the EEPROM storage. Larger AVR processors have larger EEPROM sizes, E.g: - - Arduno Duemilanove: 512b EEPROM storage. - - Arduino Uno: 1kb EEPROM storage. - - Arduino Mega: 4kb EEPROM storage. + - Arduino Duemilanove: 512 B EEPROM storage. + - Arduino Uno: 1 kB EEPROM storage. + - Arduino Mega: 4 kB EEPROM storage. Rather than hard-coding the length, you should use the pre-provided length function. This will make your code portable to all AVR processors. diff --git a/libraries/EEPROM/examples/eeprom_iteration/eeprom_iteration.ino b/libraries/EEPROM/examples/eeprom_iteration/eeprom_iteration.ino index 3673b472f..b5d68bee8 100644 --- a/libraries/EEPROM/examples/eeprom_iteration/eeprom_iteration.ino +++ b/libraries/EEPROM/examples/eeprom_iteration/eeprom_iteration.ino @@ -54,4 +54,4 @@ void setup() { } //End of setup function. -void loop() {} \ No newline at end of file +void loop() {} diff --git a/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino b/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino index a8a3510d8..d4650358d 100644 --- a/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino +++ b/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino @@ -33,9 +33,9 @@ void loop() { Advance to the next address, when at the end restart at the beginning. Larger AVR processors have larger EEPROM sizes, E.g: - - Arduno Duemilanove: 512b EEPROM storage. - - Arduino Uno: 1kb EEPROM storage. - - Arduino Mega: 4kb EEPROM storage. + - Arduino Duemilanove: 512 B EEPROM storage. + - Arduino Uno: 1 kB EEPROM storage. + - Arduino Mega: 4 kB EEPROM storage. Rather than hard-coding the length, you should use the pre-provided length function. This will make your code portable to all AVR processors. diff --git a/libraries/EEPROM/examples/eeprom_update/eeprom_update.ino b/libraries/EEPROM/examples/eeprom_update/eeprom_update.ino index 5e3db5b4f..f5b0c0c7b 100644 --- a/libraries/EEPROM/examples/eeprom_update/eeprom_update.ino +++ b/libraries/EEPROM/examples/eeprom_update/eeprom_update.ino @@ -17,7 +17,7 @@ int address = 0; void setup() { - /** EMpty setup **/ + /** Empty setup **/ } void loop() { @@ -48,9 +48,9 @@ void loop() { Advance to the next address, when at the end restart at the beginning. Larger AVR processors have larger EEPROM sizes, E.g: - - Arduno Duemilanove: 512b EEPROM storage. - - Arduino Uno: 1kb EEPROM storage. - - Arduino Mega: 4kb EEPROM storage. + - Arduino Duemilanove: 512 B EEPROM storage. + - Arduino Uno: 1 kB EEPROM storage. + - Arduino Mega: 4 kB EEPROM storage. Rather than hard-coding the length, you should use the pre-provided length function. This will make your code portable to all AVR processors. diff --git a/libraries/EEPROM/examples/eeprom_write/eeprom_write.ino b/libraries/EEPROM/examples/eeprom_write/eeprom_write.ino index f9bea641f..64e835cd6 100644 --- a/libraries/EEPROM/examples/eeprom_write/eeprom_write.ino +++ b/libraries/EEPROM/examples/eeprom_write/eeprom_write.ino @@ -36,9 +36,9 @@ void loop() { Advance to the next address, when at the end restart at the beginning. Larger AVR processors have larger EEPROM sizes, E.g: - - Arduno Duemilanove: 512b EEPROM storage. - - Arduino Uno: 1kb EEPROM storage. - - Arduino Mega: 4kb EEPROM storage. + - Arduino Duemilanove: 512 B EEPROM storage. + - Arduino Uno: 1 kB EEPROM storage. + - Arduino Mega: 4 kB EEPROM storage. Rather than hard-coding the length, you should use the pre-provided length function. This will make your code portable to all AVR processors. diff --git a/libraries/HID/keywords.txt b/libraries/HID/keywords.txt index 32a9ba5f2..9b0a525c8 100644 --- a/libraries/HID/keywords.txt +++ b/libraries/HID/keywords.txt @@ -1,5 +1,5 @@ ####################################### -# Syntax Coloring Map HID +# Syntax Coloring Map For HID ####################################### ####################################### diff --git a/libraries/HID/src/HID.cpp b/libraries/HID/src/HID.cpp index 21ede269e..3dd85fc10 100644 --- a/libraries/HID/src/HID.cpp +++ b/libraries/HID/src/HID.cpp @@ -43,7 +43,7 @@ int HID_::getDescriptor(USBSetup& setup) if (setup.bmRequestType != REQUEST_DEVICETOHOST_STANDARD_INTERFACE) { return 0; } if (setup.wValueH != HID_REPORT_DESCRIPTOR_TYPE) { return 0; } - // In a HID Class Descriptor wIndex cointains the interface number + // In a HID Class Descriptor wIndex contains the interface number if (setup.wIndex != pluggedInterface) { return 0; } int total = 0; diff --git a/libraries/SPI/examples/BarometricPressureSensor/BarometricPressureSensor.ino b/libraries/SPI/examples/BarometricPressureSensor/BarometricPressureSensor.ino index df73adeb2..1b8ad7011 100644 --- a/libraries/SPI/examples/BarometricPressureSensor/BarometricPressureSensor.ino +++ b/libraries/SPI/examples/BarometricPressureSensor/BarometricPressureSensor.ino @@ -43,7 +43,7 @@ void setup() { // start the SPI library: SPI.begin(); - // initalize the data ready and chip select pins: + // initialize the data ready and chip select pins: pinMode(dataReadyPin, INPUT); pinMode(chipSelectPin, OUTPUT); @@ -140,4 +140,3 @@ void writeRegister(byte thisRegister, byte thisValue) { // take the chip select high to de-select: digitalWrite(chipSelectPin, HIGH); } - diff --git a/libraries/SPI/examples/DigitalPotControl/DigitalPotControl.ino b/libraries/SPI/examples/DigitalPotControl/DigitalPotControl.ino index 8719058e7..39e5bf923 100644 --- a/libraries/SPI/examples/DigitalPotControl/DigitalPotControl.ino +++ b/libraries/SPI/examples/DigitalPotControl/DigitalPotControl.ino @@ -14,7 +14,7 @@ The circuit: * All A pins of AD5206 connected to +5V * All B pins of AD5206 connected to ground - * An LED and a 220-ohm resisor in series connected from each W pin to ground + * An LED and a 220-ohm resistor in series connected from each W pin to ground * CS - to digital pin 10 (SS pin) * SDI - to digital pin 11 (MOSI pin) * CLK - to digital pin 13 (SCK pin) @@ -27,7 +27,7 @@ */ -// inslude the SPI library: +// include the SPI library: #include @@ -64,7 +64,7 @@ void digitalPotWrite(int address, int value) { // take the SS pin low to select the chip: digitalWrite(slaveSelectPin, LOW); delay(100); - // send in the address and value via SPI: + // send in the address and value via SPI: SPI.transfer(address); SPI.transfer(value); delay(100); diff --git a/libraries/SPI/keywords.txt b/libraries/SPI/keywords.txt index fa7616581..55f4d4523 100644 --- a/libraries/SPI/keywords.txt +++ b/libraries/SPI/keywords.txt @@ -1,5 +1,5 @@ ####################################### -# Syntax Coloring Map SPI +# Syntax Coloring Map For SPI ####################################### ####################################### diff --git a/libraries/SPI/src/SPI.h b/libraries/SPI/src/SPI.h index 5206a0918..1e37079a9 100644 --- a/libraries/SPI/src/SPI.h +++ b/libraries/SPI/src/SPI.h @@ -106,7 +106,7 @@ class SPISettings { // slowest (128 == 2 ^^ 7, so clock_div = 6). uint8_t clockDiv; - // When the clock is known at compiletime, use this if-then-else + // When the clock is known at compile time, use this if-then-else // cascade, which the compiler knows how to completely optimize // away. When clock is not known, use a loop instead, which generates // shorter code. diff --git a/libraries/SoftwareSerial/examples/SoftwareSerialExample/SoftwareSerialExample.ino b/libraries/SoftwareSerial/examples/SoftwareSerialExample/SoftwareSerialExample.ino index 61ce88c62..061bb701f 100644 --- a/libraries/SoftwareSerial/examples/SoftwareSerialExample/SoftwareSerialExample.ino +++ b/libraries/SoftwareSerial/examples/SoftwareSerialExample/SoftwareSerialExample.ino @@ -1,5 +1,5 @@ /* - Software serial multple serial test + Software serial multiple serial test Receives from the hardware serial, sends to software serial. Receives from software serial, sends to hardware serial. @@ -52,4 +52,3 @@ void loop() { // run over and over mySerial.write(Serial.read()); } } - diff --git a/libraries/SoftwareSerial/examples/TwoPortReceive/TwoPortReceive.ino b/libraries/SoftwareSerial/examples/TwoPortReceive/TwoPortReceive.ino index 8d7f93e8f..d8c064b70 100644 --- a/libraries/SoftwareSerial/examples/TwoPortReceive/TwoPortReceive.ino +++ b/libraries/SoftwareSerial/examples/TwoPortReceive/TwoPortReceive.ino @@ -1,5 +1,5 @@ /* - Software serial multple serial test + Software serial multiple serial test Receives from the two software serial ports, sends to the hardware serial port. @@ -56,7 +56,7 @@ void setup() { } void loop() { - // By default, the last intialized port is listening. + // By default, the last initialized port is listening. // when you want to listen on a port, explicitly select it: portOne.listen(); Serial.println("Data from port one:"); @@ -83,9 +83,3 @@ void loop() { // blank line to separate data from the two ports: Serial.println(); } - - - - - - diff --git a/libraries/SoftwareSerial/src/SoftwareSerial.cpp b/libraries/SoftwareSerial/src/SoftwareSerial.cpp index 3163d7a31..5a387ab94 100644 --- a/libraries/SoftwareSerial/src/SoftwareSerial.cpp +++ b/libraries/SoftwareSerial/src/SoftwareSerial.cpp @@ -409,7 +409,7 @@ int SoftwareSerial::available() if (!isListening()) return 0; - return (_receive_buffer_tail + _SS_MAX_RX_BUFF - _receive_buffer_head) % _SS_MAX_RX_BUFF; + return ((unsigned int)(_receive_buffer_tail + _SS_MAX_RX_BUFF - _receive_buffer_head)) % _SS_MAX_RX_BUFF; } size_t SoftwareSerial::write(uint8_t b) diff --git a/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino b/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino index 4d0a68f8d..aeb1a9c5a 100644 --- a/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino +++ b/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino @@ -3,7 +3,7 @@ // and James Tichenor // Demonstrates use of the Wire library reading data from the -// Devantech Utrasonic Rangers SFR08 and SFR10 +// Devantech Ultrasonic Rangers SFR08 and SFR10 // Created 29 April 2006 @@ -13,8 +13,8 @@ #include void setup() { - Wire.begin(); // join i2c bus (address optional for master) - Serial.begin(9600); // start serial communication at 9600bps + Wire.begin(); // join I2C bus (address optional for master) + Serial.begin(9600); // start serial communication at 9600 bps } int reading = 0; @@ -23,7 +23,7 @@ void loop() { // step 1: instruct sensor to read echoes Wire.beginTransmission(112); // transmit to device #112 (0x70) // the address specified in the datasheet is 224 (0xE0) - // but i2c adressing uses the high 7 bits so it's 112 + // but I2C addressing uses the high 7 bits so it's 112 Wire.write(byte(0x00)); // sets register pointer to the command register (0x00) Wire.write(byte(0x50)); // command sensor to measure in "inches" (0x50) // use 0x51 for centimeters diff --git a/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino b/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino index dd40a2526..b5da366cb 100644 --- a/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino +++ b/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino @@ -13,7 +13,7 @@ #include void setup() { - Wire.begin(); // join i2c bus (address optional for master) + Wire.begin(); // join I2C bus (address optional for master) } byte val = 0; @@ -31,4 +31,3 @@ void loop() { } delay(500); } - diff --git a/libraries/Wire/examples/i2c_scanner/i2c_scanner.ino b/libraries/Wire/examples/i2c_scanner/i2c_scanner.ino index 3febbf441..508de805d 100644 --- a/libraries/Wire/examples/i2c_scanner/i2c_scanner.ino +++ b/libraries/Wire/examples/i2c_scanner/i2c_scanner.ino @@ -5,8 +5,8 @@ // This program (or code that looks like it) // can be found in many places. // For example on the Arduino.cc forum. -// The original author is not know. -// Version 2, Juni 2012, Using Arduino 1.0.1 +// The original author is not known. +// Version 2, June 2012, Using Arduino 1.0.1 // Adapted to be as simple as possible by Arduino.cc user Krodal // Version 3, Feb 26 2013 // V3 by louarnold @@ -33,7 +33,7 @@ void setup() { Wire.begin(); Serial.begin(9600); - while (!Serial); // Leonardo: wait for serial monitor + while (!Serial); // Leonardo: wait for Serial Monitor Serial.println("\nI2C Scanner"); } @@ -44,7 +44,7 @@ void loop() { for (byte address = 1; address < 127; ++address) { // The i2c_scanner uses the return value of - // the Write.endTransmisstion to see if + // the Wire.endTransmission to see if // a device did acknowledge to the address. Wire.beginTransmission(address); byte error = Wire.endTransmission(); diff --git a/libraries/Wire/examples/master_reader/master_reader.ino b/libraries/Wire/examples/master_reader/master_reader.ino index ecab72ab9..e27cac32b 100644 --- a/libraries/Wire/examples/master_reader/master_reader.ino +++ b/libraries/Wire/examples/master_reader/master_reader.ino @@ -13,7 +13,7 @@ #include void setup() { - Wire.begin(); // join i2c bus (address optional for master) + Wire.begin(); // join I2C bus (address optional for master) Serial.begin(9600); // start serial for output } diff --git a/libraries/Wire/examples/master_writer/master_writer.ino b/libraries/Wire/examples/master_writer/master_writer.ino index 5cbea1179..7a1766874 100644 --- a/libraries/Wire/examples/master_writer/master_writer.ino +++ b/libraries/Wire/examples/master_writer/master_writer.ino @@ -13,7 +13,7 @@ #include void setup() { - Wire.begin(); // join i2c bus (address optional for master) + Wire.begin(); // join I2C bus (address optional for master) } byte x = 0; diff --git a/libraries/Wire/examples/slave_receiver/slave_receiver.ino b/libraries/Wire/examples/slave_receiver/slave_receiver.ino index 8051d53ac..9b3f814f0 100644 --- a/libraries/Wire/examples/slave_receiver/slave_receiver.ino +++ b/libraries/Wire/examples/slave_receiver/slave_receiver.ino @@ -13,7 +13,7 @@ #include void setup() { - Wire.begin(8); // join i2c bus with address #8 + Wire.begin(8); // join I2C bus with address #8 Wire.onReceive(receiveEvent); // register event Serial.begin(9600); // start serial for output } diff --git a/libraries/Wire/examples/slave_sender/slave_sender.ino b/libraries/Wire/examples/slave_sender/slave_sender.ino index d2e72bbcf..6e2ed49d7 100644 --- a/libraries/Wire/examples/slave_sender/slave_sender.ino +++ b/libraries/Wire/examples/slave_sender/slave_sender.ino @@ -13,7 +13,7 @@ #include void setup() { - Wire.begin(8); // join i2c bus with address #8 + Wire.begin(8); // join I2C bus with address #8 Wire.onRequest(requestEvent); // register event } diff --git a/libraries/Wire/keywords.txt b/libraries/Wire/keywords.txt index 5e3d2b1ca..ee1d0acc5 100644 --- a/libraries/Wire/keywords.txt +++ b/libraries/Wire/keywords.txt @@ -6,6 +6,8 @@ # Datatypes (KEYWORD1) ####################################### +Wire KEYWORD1 + ####################################### # Methods and Functions (KEYWORD2) ####################################### @@ -18,12 +20,6 @@ requestFrom KEYWORD2 onReceive KEYWORD2 onRequest KEYWORD2 -####################################### -# Instances (KEYWORD2) -####################################### - -Wire KEYWORD2 - ####################################### # Constants (LITERAL1) ####################################### diff --git a/libraries/Wire/src/Wire.cpp b/libraries/Wire/src/Wire.cpp index 58916ce93..001d924df 100644 --- a/libraries/Wire/src/Wire.cpp +++ b/libraries/Wire/src/Wire.cpp @@ -18,6 +18,7 @@ Modified 2012 by Todd Krein (todd@krein.org) to implement repeated starts Modified 2017 by Chuck Todd (ctodd@cableone.net) to correct Unconfigured Slave Mode reboot + Modified 2020 by Greyson Christoforo (grey@christoforo.net) to implement timeouts */ extern "C" { @@ -86,6 +87,52 @@ void TwoWire::setClock(uint32_t clock) twi_setFrequency(clock); } +/*** + * Sets the TWI timeout. + * + * This limits the maximum time to wait for the TWI hardware. If more time passes, the bus is assumed + * to have locked up (e.g. due to noise-induced glitches or faulty slaves) and the transaction is aborted. + * Optionally, the TWI hardware is also reset, which can be required to allow subsequent transactions to + * succeed in some cases (in particular when noise has made the TWI hardware think there is a second + * master that has claimed the bus). + * + * When a timeout is triggered, a flag is set that can be queried with `getWireTimeoutFlag()` and is cleared + * when `clearWireTimeoutFlag()` or `setWireTimeoutUs()` is called. + * + * Note that this timeout can also trigger while waiting for clock stretching or waiting for a second master + * to complete its transaction. So make sure to adapt the timeout to accommodate for those cases if needed. + * A typical timeout would be 25ms (which is the maximum clock stretching allowed by the SMBus protocol), + * but (much) shorter values will usually also work. + * + * In the future, a timeout will be enabled by default, so if you require the timeout to be disabled, it is + * recommended you disable it by default using `setWireTimeoutUs(0)`, even though that is currently + * the default. + * + * @param timeout a timeout value in microseconds, if zero then timeout checking is disabled + * @param reset_with_timeout if true then TWI interface will be automatically reset on timeout + * if false then TWI interface will not be reset on timeout + + */ +void TwoWire::setWireTimeout(uint32_t timeout, bool reset_with_timeout){ + twi_setTimeoutInMicros(timeout, reset_with_timeout); +} + +/*** + * Returns the TWI timeout flag. + * + * @return true if timeout has occurred since the flag was last cleared. + */ +bool TwoWire::getWireTimeoutFlag(void){ + return(twi_manageTimeoutFlag(false)); +} + +/*** + * Clears the TWI timeout flag. + */ +void TwoWire::clearWireTimeoutFlag(void){ + twi_manageTimeoutFlag(true); +} + uint8_t TwoWire::requestFrom(uint8_t address, uint8_t quantity, uint32_t iaddress, uint8_t isize, uint8_t sendStop) { if (isize > 0) { diff --git a/libraries/Wire/src/Wire.h b/libraries/Wire/src/Wire.h index 702f37d64..e70d72edb 100644 --- a/libraries/Wire/src/Wire.h +++ b/libraries/Wire/src/Wire.h @@ -17,6 +17,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Modified 2012 by Todd Krein (todd@krein.org) to implement repeated starts + Modified 2020 by Greyson Christoforo (grey@christoforo.net) to implement timeouts */ #ifndef TwoWire_h @@ -54,13 +55,16 @@ class TwoWire : public Stream void begin(int); void end(); void setClock(uint32_t); + void setWireTimeout(uint32_t timeout = 25000, bool reset_with_timeout = false); + bool getWireTimeoutFlag(void); + void clearWireTimeoutFlag(void); void beginTransmission(uint8_t); void beginTransmission(int); uint8_t endTransmission(void); uint8_t endTransmission(uint8_t); uint8_t requestFrom(uint8_t, uint8_t); uint8_t requestFrom(uint8_t, uint8_t, uint8_t); - uint8_t requestFrom(uint8_t, uint8_t, uint32_t, uint8_t, uint8_t); + uint8_t requestFrom(uint8_t, uint8_t, uint32_t, uint8_t, uint8_t); uint8_t requestFrom(int, int); uint8_t requestFrom(int, int, int); virtual size_t write(uint8_t); diff --git a/libraries/Wire/src/utility/twi.c b/libraries/Wire/src/utility/twi.c index 1a3514630..e09a33caf 100644 --- a/libraries/Wire/src/utility/twi.c +++ b/libraries/Wire/src/utility/twi.c @@ -17,6 +17,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Modified 2012 by Todd Krein (todd@krein.org) to implement repeated starts + Modified 2020 by Greyson Christoforo (grey@christoforo.net) to implement timeouts */ #include @@ -24,8 +25,9 @@ #include #include #include +#include #include -#include "Arduino.h" // for digitalWrite +#include "Arduino.h" // for digitalWrite and micros #ifndef cbi #define cbi(sfr, bit) (_SFR_BYTE(sfr) &= ~_BV(bit)) @@ -43,6 +45,16 @@ static volatile uint8_t twi_slarw; static volatile uint8_t twi_sendStop; // should the transaction end with a stop static volatile uint8_t twi_inRepStart; // in the middle of a repeated start +// twi_timeout_us > 0 prevents the code from getting stuck in various while loops here +// if twi_timeout_us == 0 then timeout checking is disabled (the previous Wire lib behavior) +// at some point in the future, the default twi_timeout_us value could become 25000 +// and twi_do_reset_on_timeout could become true +// to conform to the SMBus standard +// http://smbus.org/specs/SMBus_3_1_20180319.pdf +static volatile uint32_t twi_timeout_us = 0ul; +static volatile bool twi_timed_out_flag = false; // a timeout has been seen +static volatile bool twi_do_reset_on_timeout = false; // reset the TWI registers on timeout + static void (*twi_onSlaveTransmit)(void); static void (*twi_onSlaveReceive)(uint8_t*, int); @@ -154,12 +166,16 @@ uint8_t twi_readFrom(uint8_t address, uint8_t* data, uint8_t length, uint8_t sen } // wait until twi is ready, become master receiver + uint32_t startMicros = micros(); while(TWI_READY != twi_state){ - continue; + if((twi_timeout_us > 0ul) && ((micros() - startMicros) > twi_timeout_us)) { + twi_handleTimeout(twi_do_reset_on_timeout); + return 0; + } } twi_state = TWI_MRX; twi_sendStop = sendStop; - // reset error state (0xFF.. no error occured) + // reset error state (0xFF.. no error occurred) twi_error = 0xFF; // initialize buffer iteration vars @@ -167,7 +183,7 @@ uint8_t twi_readFrom(uint8_t address, uint8_t* data, uint8_t length, uint8_t sen twi_masterBufferLength = length-1; // This is not intuitive, read on... // On receive, the previously configured ACK/NACK setting is transmitted in // response to the received byte before the interrupt is signalled. - // Therefor we must actually set NACK when the _next_ to last byte is + // Therefore we must actually set NACK when the _next_ to last byte is // received, causing that NACK to be sent in response to receiving the last // expected byte of data. @@ -183,28 +199,38 @@ uint8_t twi_readFrom(uint8_t address, uint8_t* data, uint8_t length, uint8_t sen // up. Also, don't enable the START interrupt. There may be one pending from the // repeated start that we sent ourselves, and that would really confuse things. twi_inRepStart = false; // remember, we're dealing with an ASYNC ISR + startMicros = micros(); do { TWDR = twi_slarw; + if((twi_timeout_us > 0ul) && ((micros() - startMicros) > twi_timeout_us)) { + twi_handleTimeout(twi_do_reset_on_timeout); + return 0; + } } while(TWCR & _BV(TWWC)); TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START - } - else + } else { // send start condition TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTA); + } // wait for read operation to complete + startMicros = micros(); while(TWI_MRX == twi_state){ - continue; + if((twi_timeout_us > 0ul) && ((micros() - startMicros) > twi_timeout_us)) { + twi_handleTimeout(twi_do_reset_on_timeout); + return 0; + } } - if (twi_masterBufferIndex < length) + if (twi_masterBufferIndex < length) { length = twi_masterBufferIndex; + } // copy twi buffer to data for(i = 0; i < length; ++i){ data[i] = twi_masterBuffer[i]; } - + return length; } @@ -222,6 +248,7 @@ uint8_t twi_readFrom(uint8_t address, uint8_t* data, uint8_t length, uint8_t sen * 2 .. address send, NACK received * 3 .. data send, NACK received * 4 .. other twi error (lost bus arbitration, bus error, ..) + * 5 .. timeout */ uint8_t twi_writeTo(uint8_t address, uint8_t* data, uint8_t length, uint8_t wait, uint8_t sendStop) { @@ -233,12 +260,16 @@ uint8_t twi_writeTo(uint8_t address, uint8_t* data, uint8_t length, uint8_t wait } // wait until twi is ready, become master transmitter + uint32_t startMicros = micros(); while(TWI_READY != twi_state){ - continue; + if((twi_timeout_us > 0ul) && ((micros() - startMicros) > twi_timeout_us)) { + twi_handleTimeout(twi_do_reset_on_timeout); + return (5); + } } twi_state = TWI_MTX; twi_sendStop = sendStop; - // reset error state (0xFF.. no error occured) + // reset error state (0xFF.. no error occurred) twi_error = 0xFF; // initialize buffer iteration vars @@ -263,20 +294,29 @@ uint8_t twi_writeTo(uint8_t address, uint8_t* data, uint8_t length, uint8_t wait // We need to remove ourselves from the repeated start state before we enable interrupts, // since the ISR is ASYNC, and we could get confused if we hit the ISR before cleaning // up. Also, don't enable the START interrupt. There may be one pending from the - // repeated start that we sent outselves, and that would really confuse things. + // repeated start that we sent ourselves, and that would really confuse things. twi_inRepStart = false; // remember, we're dealing with an ASYNC ISR + startMicros = micros(); do { - TWDR = twi_slarw; + TWDR = twi_slarw; + if((twi_timeout_us > 0ul) && ((micros() - startMicros) > twi_timeout_us)) { + twi_handleTimeout(twi_do_reset_on_timeout); + return (5); + } } while(TWCR & _BV(TWWC)); TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE); // enable INTs, but not START - } - else + } else { // send start condition TWCR = _BV(TWINT) | _BV(TWEA) | _BV(TWEN) | _BV(TWIE) | _BV(TWSTA); // enable INTs + } // wait for write operation to complete + startMicros = micros(); while(wait && (TWI_MTX == twi_state)){ - continue; + if((twi_timeout_us > 0ul) && ((micros() - startMicros) > twi_timeout_us)) { + twi_handleTimeout(twi_do_reset_on_timeout); + return (5); + } } if (twi_error == 0xFF) @@ -356,7 +396,7 @@ void twi_reply(uint8_t ack) if(ack){ TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT) | _BV(TWEA); }else{ - TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT); + TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWINT); } } @@ -371,10 +411,21 @@ void twi_stop(void) // send stop condition TWCR = _BV(TWEN) | _BV(TWIE) | _BV(TWEA) | _BV(TWINT) | _BV(TWSTO); - // wait for stop condition to be exectued on bus + // wait for stop condition to be executed on bus // TWINT is not set after a stop condition! + // We cannot use micros() from an ISR, so approximate the timeout with cycle-counted delays + const uint8_t us_per_loop = 8; + uint32_t counter = (twi_timeout_us + us_per_loop - 1)/us_per_loop; // Round up while(TWCR & _BV(TWSTO)){ - continue; + if(twi_timeout_us > 0ul){ + if (counter > 0ul){ + _delay_us(us_per_loop); + counter--; + } else { + twi_handleTimeout(twi_do_reset_on_timeout); + return; + } + } } // update twi state @@ -396,6 +447,59 @@ void twi_releaseBus(void) twi_state = TWI_READY; } +/* + * Function twi_setTimeoutInMicros + * Desc set a timeout for while loops that twi might get stuck in + * Input timeout value in microseconds (0 means never time out) + * Input reset_with_timeout: true causes timeout events to reset twi + * Output none + */ +void twi_setTimeoutInMicros(uint32_t timeout, bool reset_with_timeout){ + twi_timed_out_flag = false; + twi_timeout_us = timeout; + twi_do_reset_on_timeout = reset_with_timeout; +} + +/* + * Function twi_handleTimeout + * Desc this gets called whenever a while loop here has lasted longer than + * twi_timeout_us microseconds. always sets twi_timed_out_flag + * Input reset: true causes this function to reset the twi hardware interface + * Output none + */ +void twi_handleTimeout(bool reset){ + twi_timed_out_flag = true; + + if (reset) { + // remember bitrate and address settings + uint8_t previous_TWBR = TWBR; + uint8_t previous_TWAR = TWAR; + + // reset the interface + twi_disable(); + twi_init(); + + // reapply the previous register values + TWAR = previous_TWAR; + TWBR = previous_TWBR; + } +} + +/* + * Function twi_manageTimeoutFlag + * Desc returns true if twi has seen a timeout + * optionally clears the timeout flag + * Input clear_flag: true if we should reset the hardware + * Output the value of twi_timed_out_flag when the function was called + */ +bool twi_manageTimeoutFlag(bool clear_flag){ + bool flag = twi_timed_out_flag; + if (clear_flag){ + twi_timed_out_flag = false; + } + return(flag); +} + ISR(TWI_vect) { switch(TW_STATUS){ @@ -416,16 +520,16 @@ ISR(TWI_vect) TWDR = twi_masterBuffer[twi_masterBufferIndex++]; twi_reply(1); }else{ - if (twi_sendStop) + if (twi_sendStop){ twi_stop(); - else { - twi_inRepStart = true; // we're gonna send the START - // don't enable the interrupt. We'll generate the start, but we - // avoid handling the interrupt until we're in the next transaction, - // at the point where we would normally issue the start. - TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ; - twi_state = TWI_READY; - } + } else { + twi_inRepStart = true; // we're gonna send the START + // don't enable the interrupt. We'll generate the start, but we + // avoid handling the interrupt until we're in the next transaction, + // at the point where we would normally issue the start. + TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ; + twi_state = TWI_READY; + } } break; case TW_MT_SLA_NACK: // address sent, nack received @@ -457,17 +561,17 @@ ISR(TWI_vect) case TW_MR_DATA_NACK: // data received, nack sent // put final byte into buffer twi_masterBuffer[twi_masterBufferIndex++] = TWDR; - if (twi_sendStop) - twi_stop(); - else { - twi_inRepStart = true; // we're gonna send the START - // don't enable the interrupt. We'll generate the start, but we - // avoid handling the interrupt until we're in the next transaction, - // at the point where we would normally issue the start. - TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ; - twi_state = TWI_READY; - } - break; + if (twi_sendStop){ + twi_stop(); + } else { + twi_inRepStart = true; // we're gonna send the START + // don't enable the interrupt. We'll generate the start, but we + // avoid handling the interrupt until we're in the next transaction, + // at the point where we would normally issue the start. + TWCR = _BV(TWINT) | _BV(TWSTA)| _BV(TWEN) ; + twi_state = TWI_READY; + } + break; case TW_MR_SLA_NACK: // address sent, nack received twi_stop(); break; @@ -560,4 +664,3 @@ ISR(TWI_vect) break; } } - diff --git a/libraries/Wire/src/utility/twi.h b/libraries/Wire/src/utility/twi.h index d27325ea7..85b983794 100644 --- a/libraries/Wire/src/utility/twi.h +++ b/libraries/Wire/src/utility/twi.h @@ -15,6 +15,8 @@ You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + + Modified 2020 by Greyson Christoforo (grey@christoforo.net) to implement timeouts */ #ifndef twi_h @@ -50,6 +52,8 @@ void twi_reply(uint8_t); void twi_stop(void); void twi_releaseBus(void); + void twi_setTimeoutInMicros(uint32_t, bool); + void twi_handleTimeout(bool); + bool twi_manageTimeoutFlag(bool); #endif - diff --git a/platform.txt b/platform.txt index cb486985c..df5ddb712 100644 --- a/platform.txt +++ b/platform.txt @@ -3,10 +3,10 @@ # ------------------------------ # # For more info: -# https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5-3rd-party-Hardware-specification +# https://arduino.github.io/arduino-cli/latest/platform-specification/ name=Arduino AVR Boards -version=1.6.23 +version=1.8.6 # AVR compile variables # --------------------- @@ -33,6 +33,7 @@ compiler.objcopy.eep.flags=-O ihex -j .eeprom --set-section-flags=.eeprom=alloc, compiler.elf2hex.flags=-O ihex -R .eeprom compiler.elf2hex.cmd=avr-objcopy compiler.ldflags= +compiler.libraries.ldflags= compiler.size.cmd=avr-size # This can be overridden in boards.txt @@ -65,7 +66,7 @@ archive_file_path={build.path}/{archive_file} recipe.ar.pattern="{compiler.path}{compiler.ar.cmd}" {compiler.ar.flags} {compiler.ar.extra_flags} "{archive_file_path}" "{object_file}" ## Combine gc-sections, archives, and objects -recipe.c.combine.pattern="{compiler.path}{compiler.c.elf.cmd}" {compiler.c.elf.flags} -mmcu={build.mcu} {compiler.c.elf.extra_flags} -o "{build.path}/{build.project_name}.elf" {object_files} "{build.path}/{archive_file}" "-L{build.path}" -lm +recipe.c.combine.pattern="{compiler.path}{compiler.c.elf.cmd}" {compiler.c.elf.flags} -mmcu={build.mcu} {compiler.c.elf.extra_flags} {compiler.ldflags} -o "{build.path}/{build.project_name}.elf" {object_files} {compiler.libraries.ldflags} "{build.path}/{archive_file}" "-L{build.path}" -lm ## Create output files (.eep and .hex) recipe.objcopy.eep.pattern="{compiler.path}{compiler.objcopy.cmd}" {compiler.objcopy.eep.flags} {compiler.objcopy.eep.extra_flags} "{build.path}/{build.project_name}.elf" "{build.path}/{build.project_name}.eep" @@ -88,6 +89,12 @@ recipe.preproc.includes="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} preproc.macros.flags=-w -x c++ -E -CC recipe.preproc.macros="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} {preproc.macros.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.cpp.extra_flags} {build.extra_flags} {includes} "{source_file}" -o "{preprocessed_file_path}" +# Required discoveries and monitors +# --------------------------------- +pluggable_discovery.required.0=builtin:serial-discovery +pluggable_discovery.required.1=builtin:mdns-discovery +pluggable_monitor.required.serial=builtin:serial-monitor + # AVR Uploader/Programmers tools # ------------------------------ @@ -95,8 +102,6 @@ tools.avrdude.path={runtime.tools.avrdude.path} tools.avrdude.cmd.path={path}/bin/avrdude tools.avrdude.config.path={path}/etc/avrdude.conf -tools.avrdude.network_cmd={runtime.tools.arduinoOTA.path}/bin/arduinoOTA - tools.avrdude.upload.params.verbose=-v tools.avrdude.upload.params.quiet=-q -q # tools.avrdude.upload.verify is needed for backwards compatibility with IDE 1.6.8 or older, IDE 1.6.9 or newer overrides this value @@ -121,8 +126,15 @@ tools.avrdude.bootloader.pattern="{cmd.path}" "-C{config.path}" {bootloader.verb tools.avrdude_remote.upload.pattern=/usr/bin/run-avrdude /tmp/sketch.hex {upload.verbose} -p{build.mcu} +# The following rule is deprecated by pluggable discovery. +# We keep it to avoid breaking compatibility with the Arduino Java IDE. +tools.avrdude.network_cmd={runtime.tools.arduinoOTA.path}/bin/arduinoOTA tools.avrdude.upload.network_pattern="{network_cmd}" -address {serial.port} -port {upload.network.port} -sketch "{build.path}/{build.project_name}.hex" -upload {upload.network.endpoint_upload} -sync {upload.network.endpoint_sync} -reset {upload.network.endpoint_reset} -sync_exp {upload.network.sync_return} +# arduino ota +tools.arduino_ota.cmd={runtime.tools.arduinoOTA.path}/bin/arduinoOTA +tools.arduino_ota.upload.pattern="{cmd}" -address {upload.port.address} -port {upload.port.properties.port} -sketch "{build.path}/{build.project_name}.hex" -upload {upload.port.properties.endpoint_upload} -sync {upload.port.properties.endpoint_sync} -reset {upload.port.properties.endpoint_reset} -sync_exp {upload.port.properties.sync_return} + # USB Default Flags # Default blank usb manufacturer will be filled in at compile time # - from numeric vendor ID, set to Unknown otherwise diff --git a/post_install.bat b/post_install.bat new file mode 100644 index 000000000..fcc8d8c78 --- /dev/null +++ b/post_install.bat @@ -0,0 +1,20 @@ +@echo off +set ARGS=/LM /SW /SA +if "%PROCESSOR_ARCHITECTURE%" == "AMD64" ( + drivers\dpinst-amd64.exe %ARGS% +) ELSE IF "%PROCESSOR_ARCHITEW6432%" == "AMD64" ( + drivers\dpinst-amd64.exe %ARGS% +) ELSE ( + drivers\dpinst-x86.exe %ARGS% +) + +REM dpinst /PATH has problems with relative paths, so use absolute path. +if "%PROCESSOR_ARCHITECTURE%" == "AMD64" ( + drivers\dpinst-amd64.exe /PATH "%cd%\drivers\gemma" %ARGS% +) ELSE IF "%PROCESSOR_ARCHITEW6432%" == "AMD64" ( + drivers\dpinst-amd64.exe /PATH "%cd%\drivers\gemma" %ARGS% +) ELSE ( + drivers\dpinst-x86.exe /PATH "%cd%\drivers\gemma" %ARGS% +) + +exit /b 0 diff --git a/programmers.txt b/programmers.txt index 69ddf692c..40532f5b6 100644 --- a/programmers.txt +++ b/programmers.txt @@ -3,6 +3,7 @@ avrisp.communication=serial avrisp.protocol=stk500v1 avrisp.program.protocol=stk500v1 avrisp.program.tool=avrdude +avrisp.program.tool.default=avrdude avrisp.program.extra_params=-P{serial.port} avrispmkii.name=AVRISP mkII @@ -10,21 +11,25 @@ avrispmkii.communication=usb avrispmkii.protocol=stk500v2 avrispmkii.program.protocol=stk500v2 avrispmkii.program.tool=avrdude +avrispmkii.program.tool.default=avrdude avrispmkii.program.extra_params=-Pusb usbtinyisp.name=USBtinyISP usbtinyisp.protocol=usbtiny usbtinyisp.program.tool=avrdude +usbtinyisp.program.tool.default=avrdude usbtinyisp.program.extra_params= arduinoisp.name=ArduinoISP arduinoisp.protocol=arduinoisp arduinoisp.program.tool=avrdude +arduinoisp.program.tool.default=avrdude arduinoisp.program.extra_params= arduinoisporg.name=ArduinoISP.org arduinoisporg.protocol=arduinoisporg arduinoisporg.program.tool=avrdude +arduinoisporg.program.tool.default=avrdude arduinoisporg.program.extra_params= usbasp.name=USBasp @@ -32,6 +37,7 @@ usbasp.communication=usb usbasp.protocol=usbasp usbasp.program.protocol=usbasp usbasp.program.tool=avrdude +usbasp.program.tool.default=avrdude usbasp.program.extra_params=-Pusb parallel.name=Parallel Programmer @@ -39,6 +45,7 @@ parallel.protocol=dapa parallel.force=true # parallel.delay=200 parallel.program.tool=avrdude +parallel.program.tool.default=avrdude parallel.program.extra_params=-F arduinoasisp.name=Arduino as ISP @@ -48,6 +55,7 @@ arduinoasisp.speed=19200 arduinoasisp.program.protocol=stk500v1 arduinoasisp.program.speed=19200 arduinoasisp.program.tool=avrdude +arduinoasisp.program.tool.default=avrdude arduinoasisp.program.extra_params=-P{serial.port} -b{program.speed} arduinoasispatmega32u4.name=Arduino as ISP (ATmega32U4) @@ -57,11 +65,13 @@ arduinoasispatmega32u4.speed=19200 arduinoasispatmega32u4.program.protocol=arduino arduinoasispatmega32u4.program.speed=19200 arduinoasispatmega32u4.program.tool=avrdude +arduinoasispatmega32u4.program.tool.default=avrdude arduinoasispatmega32u4.program.extra_params=-P{serial.port} -b{program.speed} usbGemma.name=Arduino Gemma usbGemma.protocol=arduinogemma usbGemma.program.tool=avrdude +usbGemma.program.tool.default=avrdude usbGemma.program.extra_params= usbGemma.config.path={runtime.platform.path}/bootloaders/gemma/avrdude.conf @@ -76,18 +86,20 @@ buspirate.communication=serial buspirate.protocol=buspirate buspirate.program.protocol=buspirate buspirate.program.tool=avrdude +buspirate.program.tool.default=avrdude buspirate.program.extra_params=-P{serial.port} # STK500 firmware version v1 and v2 use different serial protocols. # Using the 'stk500' protocol tells avrdude to try and autodetect the # firmware version. If this leads to problems, we might need to add -# stk500v1 and stk500v2 entries to allow explicitely selecting the +# stk500v1 and stk500v2 entries to allow explicitly selecting the # firmware version. stk500.name=Atmel STK500 development board stk500.communication=serial stk500.protocol=stk500 stk500.program.protocol=stk500 stk500.program.tool=avrdude +stk500.program.tool.default=avrdude stk500.program.extra_params=-P{serial.port} jtag3isp.name=Atmel JTAGICE3 (ISP mode) @@ -95,6 +107,7 @@ jtag3isp.communication=usb jtag3isp.protocol=jtag3isp jtag3isp.program.protocol=jtag3isp jtag3isp.program.tool=avrdude +jtag3isp.program.tool.default=avrdude jtag3isp.program.extra_params= jtag3.name=Atmel JTAGICE3 (JTAG mode) @@ -102,6 +115,7 @@ jtag3.communication=usb jtag3.protocol=jtag3 jtag3.program.protocol=jtag3 jtag3.program.tool=avrdude +jtag3.program.tool.default=avrdude # Set a bitclock of 0.1us (the fastest supported value). This should # work regardless of the crystal used, since JTAG doesn't use the MCU # clock but dictates its own clock. @@ -112,4 +126,5 @@ atmel_ice.communication=usb atmel_ice.protocol=atmelice_isp atmel_ice.program.protocol=atmelice_isp atmel_ice.program.tool=avrdude +atmel_ice.program.tool.default=avrdude atmel_ice.program.extra_params=-Pusb